The network configuration of the Debian system is the same as that of some other systems, including configuring IP, gateway, DNS, etc. This article will briefly introduce the process of configuring the network under the Debian system.
1, set the IP address, gateway
cp /etc /network /interfaces /etc/network/interfaces.bak # backup the original configuration file
vi /etc/network/interfaces # Edit Network Adapter Profile
# The loopback network interface
auto lo
iface lo inet loopback
# The primary Network interface
auto eth0 # Boot automatically connect to the network
allow-hotplug eth0
iface eth0 inet static # static means to use fixed ip, dhcp representation using dynamic ip
address 192.168.21.166 # Set ip address
netmask 255.255.255.0 # Set subnet mask
gateway 192.168.21.2 #Set gateway
Press ESC, Then type: eq to save and exit.
The following version is easy to copy, because it is best not to have Chinese in the configuration file:
# The loopback network interface
auto lo
iface lo inet Loopback
# The primary network interface
auto eth0
allow-hotplug eth0
iface eth0 inet static
address 192.168.21.166
netmask 255.255.255.0
gateway 192.168.21.1
2, set dns
cp /etc/resolv.conf /etc/resolv.conf. Bak # back up the original dns configuration file
vi /etc/resolv.conf #edit configuration file
nameserver 127.0.0.1
nameserver 8.8.8.8 # set preferred dns< Br>
nameserver 8.8.4.4 # Set up alternate dns
Press ESC, then type: eq to save and exit.
The following version is easy to copy, because it is best not to have Chinese in the configuration file:
nameserver 127.0.0.1
nameserver 8.8.8.8
nameserver 8.8 .4.4
3. Restart the network
service networking restart # Restart the network
At this point, the IP address, gateway, and DNS configuration are complete, and the system is now available online.
The above is the method of network configuration under Debian system, IP address, gateway and DNS settings, each step can not be omitted.
A rootkit is a type of malware that is often used in conjunction with other malicio
If the Linux system forgets the root password, you can modify the password in singl
Many users have used Docker to reflect the time when the Docker container is out of sync with the ho
When there is still a lot of space on the Linux system hard disk, we can use the fd
How to change the position of the close/maximize/minimize button in the Ubuntu program window
Linux network management command list
CentOS uses Java method via Chrome
Ubuntu prompts missing fonts after installing WPS. What should I do?
How to find the reset user name and password in the Uuntu system
Linux system hard disk failure repair method
How Linux optimizes performance by modifying parameters
How to configure Kickstart script
How to identify Linux soft links and hard links
Linux installation and configuration of rsync and sersync methods
How to solve the shell script stop execution when the Linux system is scheduled?
How to perfectly install the five rules of windows7
Where is the Windows 10 Control Panel?
U disk prompts to solve the formatting steps
Vista version of the set of a single activation code to determine the installation version
Live account login win8 system does not need to lose the password method
Let 2003 log in to the system without displaying the last login user name
How to use the basic conditions rollback feature Win10 system