Arm-Linux root file system network configuration summary
Source: Internet
Author: User
Arm-Linux root file system network configuration summary this article is divided into three points to record some network configuration tips for embedded Linux Root File: 1. configure static IP for the development board: autoeth0ifaceeth0inetdhcppre-u in the root file system/etc/network/interface file... arm-Linux root file system network configuration summary this article is divided into three points to record some network configuration tips for embedded Linux Root File: 1. configure static IP for the development board: set the auto eth0iface eth0 inet dhcp pre-up/bin/grep-v-e "ip = [0-9] \ + \ in the/etc/network/interface file of the root file system \. [0-9] \ + \. [0-9] \ + \. [0-9] \ + "/proc/cmdline>/dev/null modify the DHCP configuration of eth0 to static ip mode: auto eth0iface eth0 inet stati C address 192.168.1.100 netmask 255.255.255.0 network 192.168.1.0 gateway 192.168.1.1 can be started in static IP mode. 2. Solution to eth0 change in the NIC name of the file system: (also suitable for copying virtual machine files) each time the root file system is copied, the NIC name suffix must be added with 1, for example, if you copy the root file system eth0 twice, it will become eth2. The reason is that Linux uses an automatic detection mechanism to prevent the same MAC address in the network and changes it to the NIC name. Solution: modify/etc/udev/rules. d/70-persisten-net.rules file # PCI device 0x1022: 0x2000 (pcnet32) SUBSYSTEM = "net", ACTION = "add", DRIVERS = "? * ", ATTR {address} = "...... ",......, KERNEL = "eth *", NAME = "eth0" # PCI device 0x1022: 0x2000 (vmxnet) SUBSYSTEM = "net", ACTION = "add ", DRIVERS = "? * ", ATTR {address} = "...... ",......, KERNEL = "eth *", NAME = "eth1" # PCI device 0x1022: 0x2000 (vmxnet) SUBSYSTEM = "net", ACTION = "add ", DRIVERS = "? * ", ATTR {address} = "...... ",......, KERNEL = "eth *", NAME = "eth2": comment out all three lines starting with SUBSYSTEM. # PCI device 0x1022: 0x2000 (pcnet32) # SUBSYSTEM = "net", ACTION = "add", DRIVERS = "? * ", ATTR {address} = "...... ",......, KERNEL = "eth *", NAME = "eth0" # PCI device 0x1022: 0x2000 (vmxnet) # SUBSYSTEM = "net ", ACTION = "add", DRIVERS = "? * ", ATTR {address} = "...... ",......, KERNEL = "eth *", NAME = "eth1" # PCI device 0x1022: 0x2000 (vmxnet) # SUBSYSTEM = "net ", ACTION = "add", DRIVERS = "? * ", ATTR {address} = "...... ",......, KERNEL = "eth *", NAME = "eth2" restart the system Nic and change it to eth0 again. 3. set the DNS server for the root file system: you only need to go to/etc/resolv. add a line to the conf file (originally blank by default) nameserver DNS server address example: nameserver 202.106.196.115 start/restart/Stop network Command:/net/init. d/networking start | restart | stop restart the network to access the Internet through telnet or a browser on the development board.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.