Bug 1651594
| Summary: | define and document behaviour of connection with specified sriov | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 8 | Reporter: | Vladimir Benes <vbenes> |
| Component: | NetworkManager | Assignee: | Beniamino Galvani <bgalvani> |
| Status: | CLOSED ERRATA | QA Contact: | Desktop QE <desktop-qa-list> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 8.0 | CC: | atragler, bgalvani, fgiudici, lrintel, pasik, rkhan, sukulkar, thaller |
| Target Milestone: | rc | Flags: | pm-rhel:
mirror+
|
| Target Release: | 8.0 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | NetworkManager-1.25.1-1.el8 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2020-11-04 01:48:18 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Vladimir Benes
2018-11-20 12:11:41 UTC
we need to check whether /sys/class/net/p4p1/device/sriov_drivers_autoprobe was set to 1 too (In reply to Vladimir Benes from comment #0) > Description of problem: > I have no idea how should connection with sriov things work. Should > reconnect refresh settings and restart auto-connected profiles? Should > bringing connection down remove all VFs? > > I think we need to define this and document. > > I would suggest reconnecting as a VFs refresh and possibility to down master > connection w/o bringing VFs down. To remove VFs we need to make total-vfs > equal 0. But no strong opinion here. > > Version-Release number of selected component (if applicable): > 1.14.0-7 Hi, this https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/blob/b850066a96ad8cf9db45fa9f60da7e2839f1e8ec/libnm-core/nm-setting-sriov.c#L1268 (part of merge request https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/merge_requests/440 ) describes what happens to VF when activating and reactivating. The merge request also implements the `nmcli connection modify $con remove sriov` command to remove a setting from a connection. Example 13. Adding an Ethernet connection and configuring SR-IOV VFs
$ nmcli con add type ethernet con-name EthernetPF ifname em1
$ nmcli con modify EthernetPF sriov.total-vfs 3 sriov.autoprobe-drivers false
$ nmcli con modify EthernetPF sriov.vfs '0 mac=00:11:22:33:44:55 vlans=10, 1 trust=true spoof-check=false'
$ nmcli con modify EthernetPF +sriov.vfs '2 max-tx-rate=20'
This example demonstrates adding an Ethernet connection for physical function (PF) ens4 and configuring 3 SR-IOV virtual functions (VFs) on it. The first VF is configured with MAC address
00:11:22:33:44:55 and VLAN 10, the second one has the trust and spoof-check features respectively enabled and disabled. VF number 2 has a maximux transmission rate of 20Mbps. The kernel is instructed to not automatically instantiate a network interface for the VFs.
from man nmcli-examples
and
sriov setting
SR-IOV settings.
Properties:
autoprobe-drivers
Whether to autoprobe virtual functions by a compatible driver. If set to NM_TERNARY_TRUE (1), the kernel will try to bind VFs to a compatible driver and if this succeeds a new network interface
will be instantiated for each VF. If set to NM_TERNARY_FALSE (0), VFs will not be claimed and no network interfaces will be created for them. When set to NM_TERNARY_DEFAULT (-1), the global
default is used; in case the global default is unspecified it is assumed to be NM_TERNARY_TRUE (1).
Format: NMTernary (int32)
total-vfs
The total number of virtual functions to create. Note that when the sriov setting is present NetworkManager enforces the number of virtual functions on the interface (also when it is zero)
during activation and resets it upon deactivation. To prevent any changes to SR-IOV parameters don't add a sriov setting to the connection.
Format: uint32
vfs
Array of virtual function descriptors. Each VF descriptor is a dictionary mapping attribute names to GVariant values. The 'index' entry is mandatory for each VF. When represented as string a VF
is in the form: "INDEX [ATTR=VALUE[ ATTR=VALUE]...]". for example: "2 mac=00:11:22:33:44:55 spoof-check=true". Multiple VFs can be specified using a comma as separator. Currently the following
attributes are supported: mac, spoof-check, trust, min-tx-rate, max-tx-rate, vlans. The "vlans" attribute is represented as a semicolon-separated list of VLAN descriptors, where each descriptor
has the form "ID[.PRIORITY[.PROTO]]". PROTO can be either 'q' for 802.1Q (the default) or 'ad' for 802.1ad.
Format: array of vardict
from man nm-settings
I think this is good to go
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (NetworkManager bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2020:4499 |