banner



How To Clear Ip Address Conflict

4 Answers 4

Use ip from iproute2. (You need to also specify the prefix length though.)

                ip addr del 10.22.30.44/16 dev eth0                              

To remove all addresses (in case you have multiple):

                ip addr flush dev eth0                              

answered Jun 17 '10 at 10:35

2

  • Works, but when I do want to a non-dev permanent change, I get an error saying "eth0 is garbage" (lol). i guess i need to manually edit that file, just can't remember the name right now

    Apr 11 '17 at 2:22

  • When setting up a kubernetes cluster I accidently ran a command that created an interface and used an IP address that was being used so I needed to delete that IP address but leave the interface around. This command fixed my problem. I used sudo ip addr del 192.168.0.1/24 dev weave. See unix.stackexchange.com/questions/646326/…

    Apr 23 at 2:45

As simple as ifconfig eth0 0.0.0.0. They should have put it in the manual.

Giacomo1968

47.3k 16 gold badges 152 silver badges 190 bronze badges

answered Jun 17 '10 at 7:53

0

To remove all adreses from all interfaces i used for loop:

              for i in $(ls /sys/class/net/) ; do     /usr/sbin/ip addr flush $i & done                          

answered Apr 3 '16 at 23:40

Perhaps you are just looking to get a new IP from the [DHCP-enabled] router? In this case call

dhclient eth0

answered Apr 25 '18 at 1:36

2

  • THAT worked, whereas assigning an IP didn't somehow get the network working. Thank you.

    Sep 25 '19 at 11:56

  • The only problem here is that now you coulld have two ips assigned as dhclient just asks for one more IP not checking if one is already there nor deleting the old ips. So delete the unused IP first before you call dhclient

    Jul 1 '20 at 8:08

Not the answer you're looking for? Browse other questions tagged linux networking or ask your own question.

How To Clear Ip Address Conflict

Source: https://superuser.com/questions/153559/how-can-i-clear-the-ip-address-of-ethernet-interface-without-cycling-the-interfa

Posted by: rodriguezuntentoody.blogspot.com

0 Response to "How To Clear Ip Address Conflict"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel