1.查看网卡名称
ifconfig -a
2.设置静态IP
vim /etc/network/interfaces
# enp3s0 为网卡名称
auto enp3s0
iface enp3s0 inet static
address 192.168.0.9
netmask 255.255.255.0
gateway 192.168.0.1
dns-nameserver 192.168.0.1
3.重启网卡
sudo /etc/init.d/networking restart
标签:0.1,静态,IP,192.168,网卡,enp3s0,linux
From: https://www.cnblogs.com/xuhu/p/17311910.html