Set the IP address. You can directly edit the/etc/Network/interfaces file, and write the fixed IP address as follows:
Auto lo eth0
Iface lo Inet loopback
Iface eth0 Inet static
Address 192.168.2.2
Netmask 255.255.255.0
Broadcast 192.168.2.255
Gateway 192.168.2.1
Set the address and gateway. The last section in DHCP is as follows:
Auto eth0
Iface eth0 Inet DHCP
After this file is changed, restart the network:
/Etc/init. d/networking restart
Generally, the ifconfig and route commands can be used to temporarily set IP addresses and gateways:
Ifconfig-A displays network settings
Ifconfig eth0 Inet down first disable eth0
Ifconfig eth0 Inet up 192.168.1.2/
Netmask 255.255.255.0 broadcast 192.168.1.255 is a row. Set IP addresses
Route add default GW 192.168.1.1 eth0 set Gateway
If the route del default GW 192.168.1.1 gateway is incorrect, you can delete it. After setting it, you can use route to check
Set the DNS and directly write/etc/resolv. conf. It is okay to write a few more files, but I don't know if it will be used. The following two are opendns, which is good, especially for users of China Telecom and China Telecom.
Domain
Nameserver 208.67.222.222
Nameserver 208.67.220.220
There are also host names:
Hostname display Host Name
Set Host Name
I don't know whether this setting will write data to the file. You can directly edit/etc/hostname, which contains only this name.
The new vro can set the port so that it is better to use the plug-in.