4ffbc2fe25
SR-IOV interfaces are currently only configured on charm installation and not after seubsequent reboots. The VFs need to be configured before the Neutron SR-IOV agent is started. Charms should also really not be involved in boot time system configuration. Due to these factors this commit adds a init script and corrensponding systemd unit file and upstart job to handle the boot-time configuration. Keep configure_sriov function for runtime configuration. Add warning about runtime configuration disrupting network service. Add restart of Neutron SR-IOV agent after runtime configuration. Cap value of sriov-numvfs at each interfaces sriov_totalvfs value. Change-Id: I7bde7217bf027db09ded35a262c214ccb11d6d86 Closes-Bug: #1697572
20 lines
625 B
Desktop File
20 lines
625 B
Desktop File
[Unit]
|
|
Description=Configure SRIOV Virtual Functions
|
|
DefaultDependencies=no
|
|
Wants=network.target
|
|
After=local-fs.target network-pre.target apparmor.service systemd-sysctl.service systemd-modules-load.service
|
|
Before=network.target shutdown.target network-online.target
|
|
Conflicts=shutdown.target
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|
|
WantedBy=network-online.target
|
|
|
|
[Service]
|
|
Type=oneshot
|
|
EnvironmentFile=-/etc/default/networking-sriov
|
|
ExecStart=/etc/init.d/neutron-openvswitch-networking-sriov.sh systemd-start
|
|
ExecStop=/etc/init.d/neutron-openvswitch-networking-sriov.sh systemd-stop
|
|
RemainAfterExit=true
|
|
TimeoutStartSec=5min
|