Ubuntu 16.04 LTS
1.修改 /etc/network/interfaces網絡
auto enp4s0 iface enp4s0 inet static address 192.168.1.10 netmask 255.255.255.0 gateway 192.168.1.1 auto enp5s0 iface enp5s0 inet static address 192.168.2.20 netmask 255.255.255.0 # 內網指定訪問不須要設置網關
2.修改/etc/NetworkManage/NetworkManage.confide
[ifupdown] managed=true
3.修改/etc/resolvconf/resolv.conf.d/baserest
nameserver 1.1.1.1
4.在桌面右上角刪除,以前系統自動配置的鏈接code
除了ifupdown相關的鏈接都刪除
5.重啓網絡管理服務,重啓網卡server
/etc/init.d/network-manage restart /etc/init.d/networking restart