標籤:
host-only模式
1、主機設定網際網路共用
2、虛擬機器網路設定
[[email protected] ~]# cd /etc/sysconfig/network-scripts/[[email protected] network-scripts]# lsifcfg-enp0s3 ifdown-ppp ifup-ib ifup-Teamifcfg-lo ifdown-routes ifup-ippp ifup-TeamPortifdown ifdown-sit ifup-ipv6 ifup-tunnelifdown-bnep ifdown-Team ifup-isdn ifup-wirelessifdown-eth ifdown-TeamPort ifup-plip init.ipv6-globalifdown-ib ifdown-tunnel ifup-plusb network-functionsifdown-ippp ifup ifup-post network-functions-ipv6ifdown-ipv6 ifup-aliases ifup-pppifdown-isdn ifup-bnep ifup-routesifdown-post ifup-eth ifup-sit[[email protected] network-scripts]# cat ifcfg-enp0s3 TYPE=EthernetBOOTPROTO=noneDEFROUTE=yesIPV4_FAILURE_FATAL=noIPV6INIT=yesIPV6_AUTOCONF=yesIPV6_DEFROUTE=yesIPV6_FAILURE_FATAL=noNAME=enp0s3UUID=e5148472-bd96-4da0-97ca-3040fb54a102DEVICE=enp0s3ONBOOT=yesIPADDR=192.168.137.105PREFIX=32GATEWAY=192.168.137.1DNS1=192.168.9.19IPV6_PEERDNS=yesIPV6_PEERROUTES=yesIPV6_PRIVACY=no
虛擬機器上網