IP: either "local" is duplicate, or "/16" is garbage error Solution

Source: Internet
Author: User

I am playing debian5in Power PC today. I don't know what's going on, but I can't modify the IP address of eth0 by modifying the interface file under/etc/network. The entire operation is as follows:

[root@KAV network]# lsif-down.d/      if-post-down.d/ if-pre-up.d/    if-up.d/        interfaces      interfaces.bak[root@KAV network]# cat interfaces# Configure Loopbackauto loiface lo inet loopbackauto eth0iface eth0 inet staticaddress 172.20.51.115 netmask 255.255.0.0auto eth1iface eth1 inet staticaddress 192.168.2.100netmask 255.255.255.0auto eth2iface eth2 inet staticaddress 192.168.3.100netmask 255.255.255.0auto eth3iface eth3 inet staticaddress 192.168.4.100netmask 255.255.255.0[root@KAV network]# ifdown eth0[root@KAV network]# ifup eth0ip: either "local" is duplicate, or "/16" is garbage[root@KAV network]# 

Solution:

1. Delete the configuration item eth0 at the beginning of the interface file.
2. Add the eth0 configuration at the end of the interface file. The format is as follows:

[root@KAV network]# cat interfaces# Configure Loopbackauto loiface lo inet loopbackauto eth1iface eth1 inet staticaddress 192.168.2.100netmask 255.255.255.0auto eth2iface eth2 inet staticaddress 192.168.3.100netmask 255.255.255.0auto eth3iface eth3 inet staticaddress 192.168.4.100netmask 255.255.255.0auto eth0iface eth0 inet staticaddress 172.20.51.115 netmask 255.255.0.0

3. Run the following command:

[root@KAV network]# ifdown eth0[root@KAV network]# ifup eth0[root@KAV network]#

Although I do not know why, the IP address is successfully modified. Remember this first!

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.