physio_device 资源始终包含在 <Content> 段中。可以使用 add-io、set-io、remove-io、create-vf、destroy-vf 和 set-domain 子命令来修改此资源。
示例 22-19 physio_device XML 示例以下示例说明如何对虚拟功能、物理功能和根联合体执行操作。
以下 XML 示例片段说明如何使用 ldm add-io 命令将 /SYS/MB/NET0/IOVNET.PF0.VF0 虚拟功能添加到 ldg1 域。
<LDM_interface version="1.3">
<cmd>
<action>add-io</action>
<data version="3.0">
<Envelope>
<References/>
<Content xsi:type="ovf:VirtualSystem_Type" ovf:id="ldg1">
<Section xsi:type="ovf:VirtualHardwareSection_Type">
<Item>
<rasd:OtherResourceType>physio_device</rasd:OtherResourceType>
<gprop:GenericProperty key="name">
/SYS/MB/NET0/IOVNET.PF0.VF0</gprop:GenericProperty>
</Item>
</Section>
</Content>
</Envelope>
</data>
</cmd>
</LDM_interface>以下 XML 示例片段说明如何使用 ldm set-io 命令将 pci_1 根联合体的 iov_bus_enable_iov 属性值设置为 on。
<LDM_interface version="1.3">
<cmd>
<action>set-io</action>
<data version="3.0">
<Envelope>
<References/>
<Section xsi:type="ovf:VirtualHardwareSection_Type">
<Item>
<rasd:OtherResourceType>physio_device</rasd:OtherResourceType>
<gprop:GenericProperty key="name">pci_1</gprop:GenericProperty>
<gprop:GenericProperty key="iov_bus_enable_iov">
on</gprop:GenericProperty>
</Item>
</Section>
</Envelope>
</data>
</cmd>
</LDM_interface>以下 XML 示例片段说明如何使用 ldm set-io 命令将 /SYS/MB/NET0/IOVNET.PF1 物理功能的 unicast-slots 属性值设置为 6。
<LDM_interface version="1.3">
<cmd>
<action>set-io</action>
<data version="3.0">
<Envelope>
<References/>
<Section xsi:type="ovf:VirtualHardwareSection_Type">
<Item>
<rasd:OtherResourceType>physio_device</rasd:OtherResourceType>
<gprop:GenericProperty key="name">
/SYS/MB/NET0/IOVNET.PF1</gprop:GenericProperty>
<gprop:GenericProperty key="unicast-slots">6</gprop:GenericProperty>
</Item>
</Section>
</Envelope>
</data>
</cmd>
</LDM_interface>以下 XML 示例片段说明如何使用 ldm create-vf 命令创建具有以下属性值的 /SYS/MB/NET0/IOVNET.PF1.VF0 虚拟功能。
unicast-slots=6
pvid=3
mtu=1600
<LDM_interface version="1.3">
<cmd>
<action>create-vf</action>
<data version="3.0">
<Envelope>
<References/>
<Section xsi:type="ovf:VirtualHardwareSection_Type">
<Item>
<rasd:OtherResourceType>vf_device</rasd:OtherResourceType>
<gprop:GenericProperty key="iov_pf_name">
/SYS/MB/NET0/IOVNET.PF1</gprop:GenericProperty>
<gprop:GenericProperty key="unicast-slots">6</gprop:GenericProperty>
<gprop:GenericProperty key="pvid">3</gprop:GenericProperty>
<gprop:GenericProperty key="mtu">1600</gprop:GenericProperty>
</Item>
</Section>
</Envelope>
</data>
</cmd>
</LDM_interface>以下 XML 示例片段说明如何使用 ldm create-vf 命令创建 iov_pf_repeat_count_str 值 (3) 指定的虚拟功能数以及 /SYS/MB/NET0/IOVNET.PF1 物理功能。使用 iov_pf_repeat_count_str 属性创建多个虚拟功能时,不能指定其他属性值。
<LDM_interface version="1.3">
<cmd>
<action>create-vf</action>
<data version="3.0">
<Envelope>
<References/>
<Section xsi:type="ovf:VirtualHardwareSection_Type">
<Item>
<rasd:OtherResourceType>vf_device</rasd:OtherResourceType>
<gprop:GenericProperty key="iov_pf_name">
/SYS/MB/NET0/IOVNET.PF1</gprop:GenericProperty>
<gprop:GenericProperty key="iov_pf_repeat_count_str">
3</gprop:GenericProperty>
</Item>
</Section>
</Envelope>
</data>
</cmd>
</LDM_interface>