怎样设置虚拟机virtualbox 网关和linux ip

2025-05-15 09:37:32
推荐回答(3个)
回答(1):

具体虚拟机下的网络是什么模式的,nat模式的话,这样都不用设置,通过 DHCP自动获取的。
桥接模式,物理网络中有路由器设备开启dhcp也不用设置。
需要设置的话,使用linux下的命令设置
ifconfig eth0 192.168.1.xx 255.255.255.0
配置eth0网卡的ip和掩码
route add default gw 192.168.1.1
配置默认路由和网关地址
或者配置/etc/sysconfig/network-scripts/ifcfg-eth0文件

回答(2):

在本机的更改适配器设置中 有xbox的网络连接 和配置本地连接一样修改IP 网关

回答(3):

参考:
http://jingyan.baidu.com/article/11c17a2c6ca279f446e39dac.html