win7 virtualbox centos 网络设置

1\在主机virtualbox 安装目录C:\Program Files\Oracle\VirtualBox下执行:

VBoxManage setextradata "H1" "VBoxInternal/Devices/e1000/0/LUN#0/Config/guestssh/Protocol" TCP

VBoxManage setextradata "H1" "VBoxInternal/Devices/e1000/0/LUN#0/Config/guestssh/GuestPort" 22

VBoxManage setextradata "H1" "VBoxInternal/Devices/e1000/0/LUN#0/Config/guestssh/HostPort" 2222

注:H1为虚拟机名称.

2\遇到eth0 unknown interface no such device centos问题

 只需删除/etc/udev/rules.d/70-persistent-net.rules里的内容,reboot即可.

你可能感兴趣的:(win7 virtualbox centos 网络设置)