Objective - This use case shows how to configure two kernel zones with VF VNICs and offload the SLAs of the VF VNICs to the underlying physical NIC.
Typically, you cannot set SLA properties such as max-bw and priority on the VF VNIC because the VF VNIC bypasses the global zone. However, you can offload the SLA implementation to the NIC if it is supported by the NIC. The Intel XL710 10/40 Gigabit Ethernet controller NIC supports the offloading of SLAs and supports bandwidth shares in addition to the max-bw property. For information about bandwidth shares, see Bandwidth Share for VNICs.
The following figure shows the Oracle Solaris system setup used in this use case.
Figure 7 Use Case: Kernel Zones With SR-IOV VF VNICs
The setup is as follows:
An Oracle Solaris system with a global zone.
The datalink net4, which is configured over the Intel XL710 10/40 Gigabit Ethernet controller NIC with 10 Gbps bandwidth.
Two kernel zones: gold-zone and bronze-zone.
gold-zone is assigned a bandwidth share of 80% (bw-share=80). The kernel zone bronze-zone is assigned a bandwidth share of 20% (bw-share=20) and maximum bandwidth of 4 Gbps (maxbw=4G).
You need to perform the following steps to offload the SLA properties to the NIC:
Before You Begin
Ensure that your role has the appropriate rights profile to perform this procedure. See Using Rights Profiles to Perform Network Configuration.
$ dladm set-linkprop -p iov=on net4
$ dladm show-linkprop -H -p bw-share net4 LINK PROPERTY MODE HWPOSSIBLE HWFLAGS SWPOSSIBLE SWFLAGS net4 bw-share none 1-100 -- -- --
The output shows that the physical datalink net4 supports the bw-share property because the value 1-100 is displayed under the column HWPOSSIBLE.
$ zonecfg -z gold-zone zonecfg:gold-zone> add anet zonecfg:gold-zone:anet> set lower-link=net4 zonecfg:gold-zone:anet> set iov=on zonecfg:gold-zone:anet> set bw-share=80 zonecfg:gold-zone:anet> end zonecfg:gold-zone> verify zonecfg:gold-zone> commit zonecfg:gold-zone> exit
$ zonecfg -z bronze-zone zonecfg:bronze-zone> add anet zonecfg:bronze-zone:anet> set lower-link=net4 zonecfg:bronze-zone:anet> set iov=on zonecfg:bronze-zone:anet> set bw-share=20 zonecfg:bronze-zone:anet> set maxbw=4G zonecfg:bronze-zone:anet> end zonecfg:bronze-zone> verify zonecfg:bronze-zone> commit zonecfg:bronze-zone> exit
$ zoneadm -z gold-zone boot $ zoneadm -z bronze-zone boot
$ dladm show-linkprop -p bw-share LINK PROPERTY PERM VALUE EFFECTIVE DEFAULT POSSIBLE gold-zone/net1 bw-share rw 80 80% -- 1-100 bronze-zone/net1 bw-share rw 20 20% -- 1-100
$ dladm show-linkprop -p max-bw LINK PROPERTY PERM VALUE EFFECTIVE DEFAULT POSSIBLE gold-zone/net1 max-bw rw -- -- -- -- bronze-zone/net1 max-bw rw 4000 4000 -- --