广告
本站里的文章大部分经过自行整理与测试
2017年1月28日星期六
Ubuntu - Network Settings - 静态 IP 设置
$ su
$ gedit '/etc/NetworkManager/system-connections/Wired connection 1'
[connection]
id=Wired connection 1
uuid=2fe3ee09-2af6-3f0f-95a7-b2bfce16b0f7
type=ethernet
autoconnect-priority=-999
permissions=
secondaries=
timestamp=1485596065
[ethernet]
duplex=full
mac-address=00:0C:29:2E:CB:3C
mac-address-blacklist=
[ipv4]
address1=192.168.0.100/24,192.168.0.1
dns=192.168.0.1;
dns-search=
method=manual
[ipv6]
addr-gen-mode=stable-privacy
dns-search=
ip6-privacy=0
method=auto
$ systemctl restart network-manager
或
$ sudo gedit /etc/network/interfaces
auto lo
iface lo inet loopback
auto ens33
iface ens33 inet static
address 192.168.0.100
netmask 255.255.255.0
gateway 192.168.0.1
dns-nameservers 192.168.0.1
$ systemctl restart networking
订阅:
博文评论 (Atom)
没有评论:
发表评论