3.2.19 Creating or Destroying the SR-IOV Virtual Function
3.2.19 Creating or Destroying the SR-IOV Virtual Function
Use the following commands to create or destroy the SR-IOV virtual function.
Command | Functional Outline |
---|---|
ldm create-vf | Creates a virtual function (VF). |
ldm destroy-vf | Destroys a virtual function (VF). |
Note that I/O devices can be reconfigured dynamically depending on the version of Oracle VM Server for SPARC. For details, see Table 1-2, the Product Notes of the server used, the Oracle VM Server for SPARC Release Notes of the version used, and the Oracle VM Server for SPARC Administration Guide.
Creating the SR-IOV virtual function
Use the ldm create-vf command to create a virtual function (VF).
ldm create-vf command
Creating multiple virtual functions (VFs) together # ldm create-vf -n number | max pf-name |
Creating one virtual function (VF) at a time # ldm create-vf pf-name |
- -n
Specify the number of virtual functions (VFs). - pf-name
The PCIe device name that supports the SR-IOV function
The following example shows the procedure for creating the SR-IOV virtual function (VF) and adding a virtual device to the I/O domain.
- Check the PCIe device that supports the SR-IOV function.
In the following execution example, the PCIe device names "/BB0/PCI0/IOVNET.PF0" and "/BB0/PCI0/IOVNET.PF1" out of the mounted PCIe cards are applicable and assigned to the control domain.
# ldm list-io NAME TYPE BUS DOMAIN STATUS ---- ---- --- ------ ------ PCIE0 BUS PCIE0 primary IOV PCIE1 BUS PCIE1 primary IOV PCIE2 BUS PCIE2 primary IOV PCIE3 BUS PCIE3 primary IOV PCIE4 BUS PCIE4 primary IOV PCIE5 BUS PCIE5 primary IOV PCIE6 BUS PCIE6 primary IOV PCIE7 BUS PCIE7 primary IOV (Omitted) /BB0/PCI6 PCIE PCIE6 primary EMP /BB0/PCI9 PCIE PCIE7 primary EMP /BB0/PCI10 PCIE PCIE7 primary EMP /BB0/PCI0/IOVNET.PF0 PF PCIE1 primary /BB0/PCI0/IOVNET.PF1 PF PCIE1 primary /BB0/CMUL/NET0/IOVNET.PF0 PF PCIE0 primary /BB0/CMUL/NET0/IOVNET.PF1 PF PCIE0 primary /BB0/CMUL/NET2/IOVNET.PF1 PF PCIE4 primary /BB0/CMUL/NET2/IOVNET.PF0 PF PCIE4 primary |
- Set the control domain to delayed reconfiguration state.
If the I/O device is reconfigured dynamically, this is not necessary. Go to step 3.
# ldm start-reconf primary |
- Create a virtual function (VF).
# ldm create-vf /BB0/PCI0/IOVNET.PF0 # ldm create-vf /BB0/PCI0/IOVNET.PF1 |
- Restart the control domain.
If the I/O device is reconfigured dynamically, this is not necessary. Go to step 6.
# shutdown -y -g0 -i6 |
- Stop any running Oracle Solaris in the assignment destination I/O domains (iodom00 and iodom01).
If the I/O device is reconfigured dynamically, this is not necessary. Go to step 6.
# ldm stop-domain ldom00 # ldm stop-domain ldom01 |
- Add the virtual functions (/BB0/PCI0/IOVNET.PF0.VF0 and /BB0/PCI0/IOVNET.PF1.VF1) to the I/O domain.
# ldm add-io /BB0/PCI0/IOVNET.PF0.VF0 ldom00 # ldm add-io /BB0/PCI0/IOVNET.PF1.VF0 ldom01 |
- Start Oracle Solaris of the I/O domain.
If the I/O device is reconfigured dynamically, this is not necessary.
# ldm start-domain ldom00 # ldm start-domain ldom01 |
Destroying the SR-IOV virtual function
Use the ldm destroy-vf command to destroy a virtual function (VF).
ldm destroy-vf command
- Destroying multiple virtual functions (VFs) at a time
# ldm destroy-vf -n number | max pf-name |
- Destroying a specified virtual function (VF)
# ldm destroy-vf vf-name |
- -n
Specify the number of virtual functions (VFs). - pf-name
The PCIe device name that supports the SR-IOV function - vf-name
Name of a virtual function (VF)
The following example shows the procedure for disconnecting a virtual device from the I/O domain and destroying the SR-IOV virtual function (VF).
- Check the usage status of I/O devices in logical domains.
In the following execution example, the virtual devices "/BB0/PCI0/IOVNET.PF0.VF0" and "/BB0/PCI0/IOVNET.PF0.VF1" are assigned to the I/O domains (iodom00 and iodom01).
# ldm list-io NAME TYPE BUS DOMAIN STATUS ---- ---- --- ------ ------ PCIE0 BUS PCIE0 primary IOV PCIE1 BUS PCIE1 primary IOV PCIE2 BUS PCIE2 primary IOV PCIE3 BUS PCIE3 primary IOV PCIE4 BUS PCIE4 primary IOV PCIE5 BUS PCIE5 primary IOV PCIE6 BUS PCIE6 primary IOV PCIE7 BUS PCIE7 primary IOV (Omitted) /BB0/PCI6 PCIE PCIE6 primary EMP /BB0/PCI9 PCIE PCIE7 primary EMP /BB0/PCI10 PCIE PCIE7 primary EMP /BB0/PCI0/IOVNET.PF0 PF PCIE1 primary /BB0/PCI0/IOVNET.PF1 PF PCIE1 primary /BB0/CMUL/NET0/IOVNET.PF0 PF PCIE0 primary /BB0/CMUL/NET0/IOVNET.PF1 PF PCIE0 primary /BB0/CMUL/NET2/IOVNET.PF1 PF PCIE4 primary /BB0/CMUL/NET2/IOVNET.PF0 PF PCIE4 primary /BB0/PCI0/IOVNET.PF0.VF0 VF PCIE1 iodom00 /BB0/PCI0/IOVNET.PF0.VF1 VF PCIE1 iodom01 |
- Stop any started Oracle Solaris in the I/O domain to which the virtual function is assigned.
If the I/O device is reconfigured dynamically, this is not necessary. Go to step 3.
# ldm stop-domain iodom00 # ldm stop-domain iodom01 |
- From the I/O domain, release the assignment of the virtual functions (/BB0/PCI0/IOVNET.PF0.VF0 and /BB0/PCI0/IOVNET.PF0.VF1).
# ldm remove-io /BB0/PCI0/IOVNET.PF0.VF0 iodom00 # ldm remove-io /BB0/PCI0/IOVNET.PF0.VF1 iodom01 |
- Start Oracle Solaris of the I/O domain.
If the I/O device is reconfigured dynamically, this is not necessary. Go to step 6.
# ldm start-domain ldom00 # ldm start-domain ldom01 |
- Set the control domain to delayed reconfiguration state.
If the I/O device is reconfigured dynamically, this is not necessary. Go to step 6.
# ldm start-reconf primary |
- Destroy a virtual function (VF).
# ldm destroy-vf /BB0/PCI0/IOVNET.PF0 # ldm destroy-vf /BB0/PCI0/IOVNET.PF1 |
- Restart the control domain.
If the I/O device is reconfigured dynamically, this is not necessary.
# shutdown -y -g0 -i6 |
< Previous Page | Next Page >