歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
您现在的位置: Linux教程網 >> UnixLinux >  >> Linux基礎 >> 關於Linux

ubuntu設置靜態IP

設置IP

/etc/network/interfaces

? 1 2 3 4 5 6 7 8 9 10 11 12 auto lo iface lo inet loopback   auto eth0                                                         iface eth0 inet static     address 192.168.1.100     network 192.168.1.0     netmask 255.255.255.0     broadcast 192.168.1.255     gateway 192.168.1.1     up route add default gw 192.168.1.1     down route del default gw 192.168.1.1

設置DNS

/etc/resolv.conf

? 1 2 nameserver 202.96.128.86 nameserver 114.114.114.114
Copyright © Linux教程網 All Rights Reserved