HP-UX - Add a VLAN to a VSwitch

HP-UX、Linux、Tru64 UNIX、NonStop、OpenVMS、Windows Server等,数据中心、虚拟化方案等

版主: xyevolve

版面规则
1. 本版是定位于惠普软件系统及解决方案的技术讨论区。
2. 本版鼓励发帖共同讨论技术问题,不鼓励站内信件私下交流,独知知不如众知知。
3. 本版允许转贴或引用他人的作品,但必须声明原作者信息。
4. 本版禁止发表出售、求购、或其他非技术讨论等帖子。
5. 本版禁止灌水,包括但不限于任何与所讨论主题无关的回复,无意义字符,直接复制其他回复等。
6. 本站附件禁止用于商业目的,请在下载后24小时内删除,本站不对其造成的结果负任何责任。
回复
SYSTEM
网站编辑
帖子: 265
注册时间: 2012年 2月 20日 15:45 星期一

HP-UX - Add a VLAN to a VSwitch

帖子 SYSTEM » 2014年 11月 17日 09:36 星期一

NOTE: Only tag-unaware guests are supported. This simply means that tagged frames destined for a guest are always stripped of the tag information in the frame before being forwarded. Frames arriving at the vswitch from a guest can be “tagged” by the vswitch. For more information on configuring VLANs for HPVM’s go to the HP-UX vPars and Integrity VM V6.x Administrator Guide.

1. If there is no vswitch, create and start the vswitch.

NOTE: In the examples below I will use “vmlan4” as the vswitch name.

# hpvmnet -c -S vmlan4 -n 3

# hpvmnet -b -S vmlan4

NOTE: Please refer to the hpvmnet manpage for details.

2. Use hpvmnet to create the port and assign it a VLAN ID.

# hpvmnet -S vmlan4 -u portid:1:vlanid:100

NOTE: This creates port 1 with a VLAN ID 100.

3. Confirm the port and VLAN ID.

# hpvmnet -S vmlan4
Name Number State Mode NamePPA MAC Address IPv4 Address
======== ====== ======= ========= ======== ============== ===============
vmlan4 4 Up Shared lan3 0x002264362091

[Port Configuration Details]
Port Port Port Untagged Number of Active VM
Number State Adaptor VLANID Reserved VMs
======= ============ ======== ======== ============ ============
1 Available unknown 100 0

4. Add the vswitch port to the guest configuration using the hpvmmodify command.

# hpvmmodify -P vm1 -a network:lan::vswitch:vmlan4:portid:1

NOTE: If the guest is up and running you will have to restart the guest to see the newly added port.

5. Verify the port (1) on the vswitch (vmlan4) has been added to the guest configuration.

# hpvmstatus -P vm1
[Virtual Machine Details]
Virtual Machine Name VM # OS Type State
==================== ===== ======= ========
vm1 1 HPUX On (OS)

[Authorized Administrators]
Oper Groups:
Admin Groups:
Oper Users:
Admin Users:

[Virtual CPU Details]
#vCPUs Entitlement Maximum
====== =========== =======
4 25.0% 100.0%

[Memory Details]
Total Reserved
Memory Memory
======= ========
4 GB 64 MB

[Storage Interface Details]
Guest Physical
Device Adaptor Bus Dev Ftn Tgt Lun Storage Device
======= ========== === === === === === ========= =========================
disk avio_stor 0 1 0 0 0 disk /dev/rdisk/disk23
disk avio_stor 0 1 0 1 0 disk /dev/rdisk/disk24
dvd avio_stor 0 1 0 2 0 file /var/tmp/SEPT_08_BOE_DVD1.iso
disk avio_stor 0 1 0 3 0 disk /dev/rdisk/disk20

[Network Interface Details]
Interface Adaptor Name/Num PortNum Bus Dev Ftn Mac Address
========= ========== ========== ======= === === === =================
vswitch avio_lan MGMT 1 0 0 0 7e-f0-46-ee-a2-76
vswitch avio_lan MGMT 2 0 2 0 f6-d8-8e-87-4f-2c
vswitch avio_lan vmlan4 1 0 4 0 e6-e0-bd-b0-73-b1

[Misc Interface Details]
Guest Physical
Device Adaptor Bus Dev Ftn Tgt Lun Storage Device
======= ========== === === === === === ========= =========================
serial com1 tty console

NOTE: As can be seen in the output above, port 1 on vswitch vmlan4 has been added to the guest (vm1) configuration.

回复