跳过导航链接 | |
退出打印视图 | |
Oracle VM Server for SPARC 3.0 管理指南 Oracle VM Server for SPARC (简体中文) |
第 1 部分Oracle VM Server for SPARC 3.0 软件
1. Oracle VM Server for SPARC 软件概述
3. Oracle VM Server for SPARC 安全
第 2 部分可选的 Oracle VM Server for SPARC 软件
13. Oracle VM Server for SPARC 物理机到虚拟机转换工具
14. Oracle VM Server for SPARC Configuration Assistant (Oracle Solaris 10)
16. 使用 Oracle VM Server for SPARC 管理信息库软件
17. Logical Domains Manager 发现
18. 将 XML 接口与 Logical Domains Manager 结合使用
下面是 Logical Domains Manager 资源以及可以为每个资源定义的属性。这些资源和属性在 XML 示例中以粗体显示。下列示例显示了未绑定输出的资源。约束输出可用于为 Logical Domains Manager 操作创建输入。但域迁移输出除外。请参见域迁移。每个资源都定义在 <Section> OVF 段中并由 <rasd:OtherResourceType> 标记指定。
示例 18-6 ldom_info XML 输出示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="primary"> <Section xsi:type="ovf:ResourceAllocationSection_type"> <Item> <rasd:OtherResourceType>ldom_info</rasd:OtherResourceType> <uuid>c2c3d93b-a3f9-60f6-a45e-f35d55c05fb6</uuid> <rasd:Address>00:03:ba:d8:ba:f6</rasd:Address> <gprop:GenericPropertykey="hostid">83d8baf6</gprop:GenericProperty> <gprop:GenericProperty key="master">plum</gprop:GenericProperty> <gprop:GenericProperty key="failure-policy">reset</gprop:GenericProperty> <gprop:GenericProperty key="extended-mapin-space">on</gprop:GenericProperty> <gprop:GenericProperty key="progress">45%</gprop:GenericProperty> <gprop:GenericProperty key="status">ongoing</gprop:GenericProperty> <gprop:GenericProperty key="source">dt90-319</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
ldom_info 资源始终包含在 <Content> 段中。ldom_info 资源中的下列属性是可选属性:
<uuid> 标记(指定域的 UUID)。
<rasd:Address> 标记,指定要分配给域的 MAC 地址。
<gprop:GenericPropertykey="extended-mapin-space"> 标记,指定针对域启用 (on) 还是禁用 (off) 扩展的 mapin 空间。默认值为 off。
<gprop:GenericPropertykey="failure-policy"> 标记,指定从属域在主域失败时应表现出的行为。默认值为 ignore。下面是有效的属性值:
ignore 忽略主域故障(从属域不受影响)。
panic 在主域失败时使所有从属域都发生紧急情况。
reset 在主域失败时重置所有从属域。
stop 在主域失败时停止所有从属域。
<gprop:GenericPropertykey="hostid"> 标记,指定要分配给域的主机 ID。
<gprop:GenericPropertykey="master"> 标记,指定最多四个用逗号分隔的主域名称。
<gprop:GenericPropertykey="progress"> 标记,指定命令执行的进度百分比。
<gprop:GenericPropertykey="source"> 标记,指定报告命令进度的计算机。
<gprop:GenericPropertykey="status"> 标记,指定命令的状态(done、failed 或 ongoing)。
add-vcpu、set-vcpu 和 remove-vcpu XML 请求操作的等效操作是按照如下方式设置 <gpropGenericProperty key="wcore"> 标记的值:
如果使用 -c 选项,请将 wcore 属性设置为指定的全体核心数。
如果未使用 -c 选项,请将 wcore 属性设置为 0。
请注意,cpu 资源的分配单位属性 <rasd:AllocationUnits> 始终指定虚拟 CPU 数,而非核心数。
cpu 资源始终包含在 <Content> 段中。
示例 18-7 cpu XML 示例
以下示例显示 ldm add-vcpu -c 1 ldg1 命令的等效 XML 请求:
<?xml version="1.0"?> <LDM_interface version="1.3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="./schemas/combined-v3.xsd" xmlns:ovf="./schemas/envelope" xmlns:rasd="./schemas/CIM_ResourceAllocationSettingData" xmlns:vssd="./schemas/CIM_VirtualSystemSettingData" xmlns:gprop="./schemas/GenericProperty" xmlns:bind="./schemas/Binding"> <cmd> <action>add-vcpu</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>cpu</rasd:OtherResourceType> <rasd:AllocationUnits>8</rasd:AllocationUnits> <gprop:GenericProperty key="wcore">1</gprop:GenericProperty> </Item> </Section> </Content> </Envelope> </data> </cmd> </LDM_interface>
示例 18-8 ldm list-bindings 命令的 cpu XML 部分输出
以下示例通过使用 list-bindings 子命令展示 <cpu> 部分的 XML 输出:
<?xml version="1.0"?> <LDM_interface xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ovf="./schemas/envelope" xmlns:rasd="./schemas/CIM_ResourceAllocationSettingData" xmlns:vssd="./schemas/CIM_VirtualSystemSettingData" xmlns:gprop="./schemas/GenericProperty" xmlns:bind="./schemas/Binding" version="1.3" xsi:noNamespaceSchemaLocation="./schemas/combined-v3.xsd"> <cmd> <action>list-bindings</action> <data version="3.0"> <Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" ovf:id="primary"> <Section xsi:type="ovf:ResourceAllocationSection_Type"> <Item> <rasd:OtherResourceType>ldom_info</rasd:OtherResourceType> <uuid>1e04cdbd-472a-e8b9-ba4c-d3eee86e7725</uuid> <rasd:Address>00:21:28:f5:11:6a</rasd:Address> <gprop:GenericProperty key="hostid">0x8486632a</gprop:GenericProperty> <failure-policy>fff</failure-policy> <wcore>0</wcore> <extended-mapin-space>0</extended-mapin-space> <threading>8</threading> <cpu-arch>native</cpu-arch> <rc-add-policy/> <gprop:GenericProperty key="state">active</gprop:GenericProperty> </Item> </Section> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>cpu</rasd:OtherResourceType> <rasd:AllocationUnits>8</rasd:AllocationUnits> <bind:Binding> <Item> <rasd:OtherResourceType>cpu</rasd:OtherResourceType> <gprop:GenericProperty key="vid">0</gprop:GenericProperty> <gprop:GenericProperty key="pid">0</gprop:GenericProperty> <gprop:GenericProperty key="cid">0</gprop:GenericProperty> <gprop:GenericProperty key="strand_percent">100</gprop:GenericProperty> <gprop:GenericProperty key="util_percent">1.1%</gprop:GenericProperty> <gprop:GenericProperty key="normalized_utilization">0.1%</gprop:GenericProperty> </Item> </Section> </Content> </Envelope> </data> </cmd> </LDM_interface>
示例 18-9 ldm list-domain 命令的 cpu XML 部分输出
以下示例通过使用 list-domain 子命令展示 <cpu> 部分的 XML 输出:
<?xml version="1.0"?> <LDM_interface xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ovf="./schemas/envelope" xmlns:rasd="./schemas/CIM_ResourceAllocationSettingData" xmlns:vssd="./schemas/CIM_VirtualSystemSettingData" xmlns:gprop="./schemas/GenericProperty" xmlns:bind="./schemas/Binding" version="1.3" xsi:noNamespaceSchemaLocation="./schemas/combined-v3.xsd"> <cmd> <action>list-domain</action> <data version="3.0"> <Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" ovf:id="primary"> <Section xsi:type="ovf:ResourceAllocationSection_Type"> <Item> <rasd:OtherResourceType>ldom_info</rasd:OtherResourceType> <gprop:GenericProperty key="state">active</gprop:GenericProperty> <gprop:GenericProperty key="flags">-n-cv-</gprop:GenericProperty> <gprop:GenericProperty key="utilization">0.7%</gprop:GenericProperty> <gprop:GenericProperty key="uptime">3h</gprop:GenericProperty> <gprop:GenericProperty key="normalized_utilization">0.1%</gprop:GenericProperty> </Item> </Section> </Content> </Envelope> </data> </cmd> </LDM_interface>
注 - mau 资源是受支持服务器上的任意受支持的加密单元。当前,存在两个受支持的加密单元:模运算单元 (Modular Arithmetic Unit, MAU) 和控制字队列 (Control Word Queue, CWQ)。
示例 18-10 mau XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>mau</rasd:OtherResourceType> <rasd:AllocationUnits>1</rasd:AllocationUnits> </Item> </Section> </Content> </Envelope>
mau 资源始终包含在 <Content> 段中。唯一属性为 <rasd:AllocationUnits> 标记,用于指出 MAU 数或其他加密单元数。
示例 18-11 memory XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>memory</rasd:OtherResourceType> <rasd:AllocationUnits>4G</rasd:AllocationUnits> </Item> </Section> </Content> </Envelope>
内存资源始终包含在 <Content> 段中。唯一属性为 <rasd:AllocationUnits> 标记,用于指出内存大小。
示例 18-12 vds XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>vds</rasd:OtherResourceType> <gprop:GenericProperty key="service_name">vdstmp</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
虚拟磁盘服务器 (vds) 资源可以在 <Content> 段中作为域描述的一部分,也可以独自出现于 <Envelope> 段中。唯一属性为 <gprop:GenericProperty> 标记,其中含有 service_name 项,该项包含所描述的 vds 资源的名称。
示例 18-13 vds_volume XML 示例
<Envelope> <References/> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>vds_volume</rasd:OtherResourceType> <gprop:GenericProperty key="vol_name">vdsdev0</gprop:GenericProperty> <gprop:GenericProperty key="service_name">primary-vds0</gprop:GenericProperty> <gprop:GenericProperty key="block_dev"> opt/SUNWldm/domain_disks/testdisk1</gprop:GenericProperty> <gprop:GenericProperty key="vol_opts">ro</gprop:GenericProperty> <gprop:GenericProperty key="mpgroup">mpgroup-name</gprop:GenericProperty> </Item> </Section> </Envelope>
vds_volume 资源可以在 <Content> 段中作为域描述的一部分,也可以独自出现于 <Envelope> 段中。它必须含有带有以下项的 <gprop:GenericProperty> 标记:
vol_name-卷名
service_name-此卷要绑定到的虚拟磁盘服务器的名称
block_dev-要与此卷关联的文件或设备名称
可选地,vds_volume 资源还可以具有以下属性:
vol_opts-下列一项或多项,用逗号分隔,在一个字符串内:{ro,slice,excl}
mpgroup-多路径(故障转移)组的名称
示例 18-14 disk XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>disk</rasd:OtherResourceType> <gprop:GenericProperty key="vdisk_name">vdisk0</gprop:GenericProperty> <gprop:GenericProperty key="service_name">primary-vds0</gprop:GenericProperty> <gprop:GenericProperty key="vol_name">vdsdev0</gprop:GenericProperty> <gprop:GenericProperty key="timeout">60</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
disk 资源始终包含在 <Content> 段中。它必须含有带有以下项的 <gprop:GenericProperty> 标记:
vdisk_name-虚拟磁盘的名称
service_name-此虚拟磁盘要绑定到的虚拟磁盘服务器的名称
vol_name-此虚拟磁盘要关联到的虚拟磁盘服务设备
可选地,disk 资源还可以具有 timeout 属性,它是在虚拟磁盘客户机 (vdc) 与虚拟磁盘服务器 (vds) 之间建立连接时的超时值(以秒计)。如果存在多个虚拟磁盘 (vdisk) 路径,则 vdc 可以尝试连接到不同的 vds,该超时可确保在指定的时间内建立到任意 vds 的连接。
示例 18-15 vsw XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg2"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>vsw</rasd:OtherResourceType> <rasd:Address>00:14:4f:fb:ec:00</rasd:Address> <gprop:GenericProperty key="service_name">test-vsw1</gprop:GenericProperty> <gprop:GenericProperty key="inter_vnet_link">on</gprop:GenericProperty> <gprop:GenericProperty key="default-vlan-id">1</gprop:GenericProperty> <gprop:GenericProperty key="pvid">1</gprop:GenericProperty> <gprop:GenericProperty key="mtu">1500</gprop:GenericProperty> <gprop:GenericProperty key="dev_path">switch@0</gprop:GenericProperty> <gprop:GenericProperty key="id">0</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
vsw 资源既可以在 <Content> 段中作为域描述的一部分,也可以独自出现于 <Envelope> 段中。它必须具有带 service_name 键的 <gprop:GenericProperty> 标记,该键是要分配给虚拟交换机的名称。
可选地,vsw 资源还可以具有以下属性:
<rasd:Address>-向虚拟交换机分配 MAC 地址
default-vlan-id-指定在标记模式下,需要包含虚拟网络设备或虚拟交换机的默认虚拟局域网 (virtual local area network, VLAN)。第一个 VLAN ID (vid1) 是为 default-vlan-id 预留的。
dev_path-要与此虚拟交换机关联的网络设备的路径
id-指定新虚拟交换机设备的 ID。默认情况下将自动生成 ID 值,如果需要匹配 OS 中的现有设备名称,则设置此属性。
inter_vnet_link-指定是否为 Inter-Vnet 通信分配 LDC 通道。默认值为 on。
linkprop-指定虚拟设备是否应获取物理链路状态更新。当值为 phys-state 时,虚拟设备可获取物理链路状态更新。当值为空时,虚拟设备不会获取物理链路状态更新。默认情况下,虚拟设备不会获取物理链路状态更新。
mode-Oracle Solaris Cluster 心跳支持的 sc。
pvid-端口的虚拟局域网 (virtual local area network, VLAN) 标识符 (identifier, ID),表示虚拟网络需要以无标记模式成为其成员的 VLAN。
mtu-指定虚拟交换机或/和绑定到虚拟交换机的虚拟网络设备的最大传输单元 (maximum transmission unit, MTU)。有效值是 1500 到 16000。如果指定了无效值,ldm 命令会发出错误。
vid-虚拟局域网 (Virtual local area network, VLAN) 标识符 (identifier, ID),表示虚拟网络和虚拟交换机需要以标记模式成为其成员的 VLAN。
示例 18-16 network XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>network</rasd:OtherResourceType> <gprop:GenericProperty key="linkprop">phys-state</gprop:GenericProperty> <gprop:GenericProperty key="vnet_name">ldg1-vnet0</gprop:GenericProperty> <gprop:GenericProperty key="service_name">primary-vsw0</gprop:GenericProperty> <rasd:Address>00:14:4f:fc:00:01</rasd:Address> </Item> </Section> </Content> </Envelope>
network 资源始终包含在 <Content> 段中。它必须含有带有以下项的 <gprop:GenericProperty> 标记:
linkprop-指定虚拟设备是否应获取物理链路状态更新。当值为 phys-state 时,虚拟设备可获取物理链路状态更新。当值为空时,虚拟设备不会获取物理链路状态更新。默认情况下,虚拟设备不会获取物理链路状态更新。
vnet_name-虚拟网络 (vnet) 的名称
service_name-此虚拟网络要绑定到的虚拟交换机 (vswitch) 的名称
可选地,network 资源还可以具有以下属性:
<rasd:Address>-向虚拟交换机分配 MAC 地址
pvid-端口的虚拟局域网 (virtual local area network, VLAN) 标识符 (identifier, ID),表示虚拟网络需要以无标记模式成为其成员的 VLAN。
vid-虚拟局域网 (Virtual local area network, VLAN) 标识符 (identifier, ID),表示虚拟网络和虚拟交换机需要以标记模式成为其成员的 VLAN。
mode-用于为该虚拟网络启用混合 I/O 的 hybrid。
注 - 已弃用 NIU 混合 I/O 功能,取而代之的是 SR-IOV。
示例 18-17 示例 vcc XML
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>vcc</rasd:OtherResourceType> <gprop:GenericProperty key="service_name">vcc1</gprop:GenericProperty> <gprop:GenericProperty key="min_port">6000</gprop:GenericProperty> <gprop:GenericProperty key="max_port">6100</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
vcc 资源既可以在 <Content> 段中作为域描述的一部分,也可以独自出现于 <Envelope> 段中。它可以含有带有以下项的 <gprop:GenericProperty> 标记:
service_name-要分配给虚拟控制台集中器服务的名称
min_port-要与此 vcc 关联的最小端口号
max_port-要与此 vcc 关联的最大端口号
示例 18-18 var XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>var</rasd:OtherResourceType> <gprop:GenericProperty key="name">test_var</gprop:GenericProperty> <gprop:GenericProperty key="value">test1</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
var 资源始终包含在 <Content> 段中。它可以含有带有以下项的 <gprop:GenericProperty> 标记:
name-变量的名称
value-变量的值
示例 18-19 physio_device XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>physio_device</rasd:OtherResourceType> <gprop:GenericProperty key="name">pci@780</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
physio_device 资源始终包含在 <Content> 段中。唯一属性为 <gprop:GenericProperty> 标记,其中含有 name 属性值项,该项为所描述的 I/O 设备的名称。
示例 18-20 spconfig XML 示例
<Envelope> <Section xsi:type="ovf:ResourceAllocationSection_type"> <Item> <rasd:OtherResourceType>spconfig</rasd:OtherResourceType> <gprop:GenericProperty key="spconfig_name">primary</gprop:GenericProperty> <gprop:GenericProperty key="spconfig_status">current</gprop:GenericProperty> </Item> </Section> </Envelope>
服务处理器 (service processor, SP) 配置 (spconfig) 资源始终独自出现于 <Envelope> 段中。它可以含有带有以下项的 <gprop:GenericProperty> 标记:
spconfig_name-要在 SP 上存储的配置的名称
spconfig_status-特定 SP 配置的当前状态在 ldm list-spconfig 命令的输出中会使用此属性。
示例 18-21 示例 policy XML
<Envelope> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>policy</rasd:OtherResourceType> <gprop:GenericProperty key="policy_name">test-policy</gprop:GenericProperty> <gprop:GenericProperty key="policy_enable">on</gprop:GenericProperty> <gprop:GenericProperty key="policy_priority">1</gprop:GenericProperty> <gprop:GenericProperty key="policy_vcpu_min">12</gprop:GenericProperty> <gprop:GenericProperty key="policy_vcpu_max">13</gprop:GenericProperty> <gprop:GenericProperty key="policy_util_lower">8</gprop:GenericProperty> <gprop:GenericProperty key="policy_util_upper">9</gprop:GenericProperty> <gprop:GenericProperty key="policy_tod_begin">07:08:09</gprop:GenericProperty> <gprop:GenericProperty key="policy_tod_end">09:08:07</gprop:GenericProperty> <gprop:GenericProperty key="policy_sample_rate">1</gprop:GenericProperty> <gprop:GenericProperty key="policy_elastic_margin">8</gprop:GenericProperty> <gprop:GenericProperty key="policy_attack">8</gprop:GenericProperty> <gprop:GenericProperty key="policy_decay">9</gprop:GenericProperty> </Item> </Section> </Envelope>
DRM 策略 (policy) 资源显示在 <Envelope> 段,可以包含带以下键的 <gprop:GenericProperty> 标记:
policy_name-DRM 策略的名称
policy_enable-指定 DRM 策略启用还是禁用
policy_priority-DRM 策略的优先级
policy_vcpu_min-域的虚拟 CPU 资源的最小数量
policy_vcpu_max-域的虚拟 CPU 资源的最大数量
policy_util_lower-触发策略分析的最低利用率级别
policy_util_upper-触发策略分析的最高利用率级别
policy_tod_begin-DRM 策略的有效启动时间
policy_tod_end-DRM 策略的有效停止时间
policy_sample_rate-抽样率,这是以秒为单位的周期时间
policy_elastic_margin-介于 CPU 利用率上下限之间的缓冲量
policy_attack-在任一资源控制周期内可添加的最大资源量
policy_decay-在任一资源控制周期内可删除的最大资源量
示例 18-22 示例 vdpcs XML
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>vdpcs</rasd:OtherResourceType> <gprop:GenericProperty key="service_name">dg1-vdpcs</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
仅 Netra DPS 环境中会涉及此资源。vdpcs 资源既可以在 <Content> 段中作为域描述的一部分,也可以独自出现于 <Envelope> 段中。唯一属性为 <gprop:GenericProperty> 标记,其中含有 service_name 属性值项,该项为所描述的虚拟数据平面通道服务 (vdpcs) 资源的名称。
示例 18-23 vdpcc XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>vdpcc</rasd:OtherResourceType> <gprop:GenericProperty key="vdpcc_name">vdpcc</gprop:GenericProperty> <gprop:GenericProperty key="service_name">ldg1-vdpcs</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
仅 Netra DPS 环境中会涉及此资源。虚拟数据平面通道客户机资源始终包含在 <Content> 段中。它可以含有带有以下项的 <gprop:GenericProperty> 标记:
vdpcc_name-虚拟数据平面通道客户机 (vdpcc) 的名称
service_name-此 vdpcc 要绑定到的虚拟数据平面通道服务 vdpcs 的名称
示例 18-24 console XML 示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" id="ldg1"> <Section xsi:type="ovf:VirtualHardwareSection_Type"> <Item> <rasd:OtherResourceType>console</rasd:OtherResourceType> <gprop:GenericProperty key="port">6000</gprop:GenericProperty> <gprop:GenericProperty key="service_name">vcc2</gprop:GenericProperty> <gprop:GenericProperty key="group">group-name</gprop:GenericProperty> </Item> </Section> </Content> </Envelope>
console 资源始终包含在 <Content> 段中。它可以含有带有以下项的 <gprop:GenericProperty> 标记:
port-此虚拟控制台 (console) 要更改为的端口
service_name-此 console 要绑定到的虚拟控制台集中器 (vcc) 服务
group-此 console 要绑定到的组的名称
以下示例将介绍 migrate-domain 子命令的 <data> 段中包含的内容。
示例 18-25 migrate-domain <data> 段示例
<Envelope> <References/> <Content xsi:type="ovf:VirtualSystem_Type" ovf:id="ldg1"/> <Content xsi:type="ovf:VirtualSystem_Type" ovf:id="ldg1"/> <Section xsi:type="ovf:ResourceAllocationSection_Type"> <Item> <rasd:OtherResourceType>ldom_info</rasd:OtherResourceType> <gprop:GenericProperty key="target">target-host</gprop:GenericProperty> <gprop:GenericProperty key="username">user-name</gprop:GenericProperty> <gprop:GenericProperty key="password">password</gprop:GenericProperty> <Item> </Section> </Content> </Envelope>
其中:
第一个 <Content> 节点(不含 <ldom_info> 段)是要迁移的源域。
第二个 <Content> 节点(含有 <ldom_info> 段)是要迁移到的目标域。源域和目标域的名称可以相同。
目标域的 <ldom_info> 段描述要迁移到的计算机以及迁移到该计算机所需的详细信息:
target-host 是要迁移到的目标计算机。
user-name 是目标计算机的登录用户名。必须采用 SASL 64 位编码。
password 是登录到目标计算机时使用的密码。必须采用 SASL 64 位编码。
注 - Logical Domains Manager 使用 sasl_decode64() 对目标用户名和密码进行解码,使用 sasl_encode64() 对这些值进行编码。SASL 64 编码等同于 base64 编码。