Go to main content

Managing Network Virtualization and Network Resources in Oracle® Solaris 11.4

Exit Print View

Updated: November 2020
 
 

Creating VNICs With Dedicated Ring Groups

Assigning dedicated ring groups to VNICs helps in better resource isolation. Enforcing hardware SLAs on the VNICs enables hardware anti-spoofing for the VNICs.

For physical links, ring-group, which is a read-only property, indicates whether the driver supports the dedicated ring group feature. You cannot enable or disable this feature for physical datalinks.

For VNICs, the ring-group property can be specified only during the VNIC's creation, as described in the following procedure. You cannot set the property on already existing VNICs.

How to Create VNICs to Have Their Own Ring Groups

Before You Begin

Ensure that your role has the appropriate rights profile to perform this procedure. See Using Rights Profiles to Perform Network Configuration.

  1. Check if the physical link supports exclusive ring groups.
    $ dladm show-linkprop -p ring-group linkname
  2. Create a VNIC by specifying the ring-group property.
    $ dladm create-vnic -l linkname -p ring-group=value VNIC
    ring-group

    Specifies whether the VNIC can be assigned their own ring group. The valid values are:

    auto – Specifies whether exclusive or shared is used on a particular physical link is decided by the system. The default value is auto.

    exclusive – Specifies that the VNIC creation must fail if exclusive ring group is not available.

    shared – Specifies that the dedicated resources are not allocated.

  3. Check if the VNIC has exclusive ring groups.
    $ dladm show-linkprop -p ring-group VNIC
  4. Check the exclusive ring groups of the VNIC.
    $ dladm show-phys -H linkname
Example 73  Creating a VNIC With Ring Groups

This example shows how to create a VNIC that has exclusive ring group.

$ dladm show-linkprop -p ring-group net1
LINK     PROPERTY        PERM VALUE        EFFECTIVE    DEFAULT   POSSIBLE
net1     ring-group      r-   exclusive    exclusive    --        shared,
                                                                  exclusive
$ dladm create-vnic -l net1 -p ring-group=exclusive vnic5
$ dladm show-linkprop -p ring-group vnic5
LINK     PROPERTY        PERM VALUE        EFFECTIVE    DEFAULT   POSSIBLE
vnic5    ring-group      r-   exclusive    exclusive    auto      auto,shared,
                                                                  exclusive
$ dladm show-phys -H net3
LINK                RINGTYPE RINGS                CLIENTS
net1                RX       0-31                 <default,mcast>
net1                RX       33-36                vnic5
net1                TX       0-31                 <default>
net1                TX       33-36                vnic5
Example 74  Displaying the Rx Rings and Tx Rings for a VNIC With Exclusive Ring Group

This example displays the Rx and Tx rings in the EFFECTIVE field for a VNIC that has exclusive ring group.

$ dladm show-linkprop -p rx-rings,tx-rings vnic1
LINK     PROPERTY        PERM VALUE        EFFECTIVE    DEFAULT   POSSIBLE
vnic1    rx-rings        r-   --           4            --        --
vnic1    tx-rings        r-   --           4            --        --
Example 75  Creating a VNIC With the ring-group and bw-share Properties

This example shows the creation of a VNIC by specifying the ring group along with the share of bandwidth.

$ dladm show-linkprop -p ring-group net1
LINK     PROPERTY        PERM VALUE        EFFECTIVE    DEFAULT   POSSIBLE
net1     ring-group      r-   exclusive    exclusive    --        shared,
                                                                  exclusive
$ dladm create-vnic -l net2 -p ring-group=exclusive,bw-share=80 vnic1
$ dladm create-vnic -l net2 -p ring-group=exclusive,bw-share=20 vnic2
$ dladm show-linkprop -p ring-group,bw-share vnic1
LINK     PROPERTY        PERM VALUE        EFFECTIVE    DEFAULT   POSSIBLE
vnic1    ring-group      r-   exclusive    exclusive    auto      auto,shared,
                                                                  exclusive
vnic1    bw-share        rw    80           80%          --        1-100 

VNICs With Ring Group in SR-IOV Mode

SR-IOV mode supports VNICs with the ring-group property set to exclusive. You can create a VNIC in the SR-IOV mode only if the iov property of the VNIC is either auto or off. If the iov property is set to on, then the VNIC creation fails. For more information about SR-IOV VNICs, see Using Single Root I/O Virtualization With VNICs.

Zone's anet Resource With Ring Group

The anet resource of Oracle Solaris zones supports the ring-group property. The value that can be set for this property is the same as that of a VNIC. Similar to VNIC creation, you cannot create an anet resource if the iov property is set to on and ring-group is set to exclusive. For more information, see Oracle Solaris Zones Configuration Resources.


Note -  Any value other than auto takes precedence when the value of iov or ring-group is set a value other than auto.

Hardware Offload Support for the ring-group Property

When the ring-group property of a VNIC has the value exclusive, you can offload the SLA implementation in MAC to the NIC only if the NIC supports hardware SLAs. The offloading helps to save the CPU cycles. For more information, see Setting Hardware SLA Properties for VF VNICs.

Support of Hardware Flows

During VNIC creation, if the ring-group property is set to auto or exclusive, the VNIC tries to get a hardware flow from the underlying link. If the flow allocation is successful, the VNIC uses the existing ring group interface to initialize the Tx or Rx ring groups for this flow. Then, the ring groups are usable and exclusively owned by this VNIC.