修改配置文件/etc/netplan/50-cloud-init.yaml
network:
version: 2
ethernets:
ens33:
dhcp4: no
dhcp6: no
addresses: [192.168.12.6/24]
optional: true
gateway4: 192.168.12.2
nameservers:
addresses: [223.5.5.5,223.6.6.6,8.8.8.8]
netplan apply
修改配置文件/etc/netplan/50-cloud-init.yaml
network:
version: 2
ethernets:
ens33:
dhcp4: no
dhcp6: no
addresses: [192.168.12.6/24]
optional: true
gateway4: 192.168.12.2
nameservers:
addresses: [223.5.5.5,223.6.6.6,8.8.8.8]
netplan apply
本文标题:ubuntu18设置静态ip
本文链接:https://www.haomeiwen.com/subject/elhmvftx.html
网友评论