RTNETLINK answers: File exists

Ritratto di jdaemon

When the virtual terminal displays the following message:

RTNETLINK answers: File exists

It should not be interpreted literally.

It's a misuse of (rt)netlink interface for communication with the kernel. Generally the message is caused by the Dynamic Host Configuration Protocol (DHCP) system which assigns an "X" IP address to the computer on which it was previously set same "X" IP address.

If the network does this message can be ignored, otherwise you have to ask if the network parameters are correct.

I wrote this article because exploring the web I found several inaccurate explanations of this problem. Some argue that it is caused by the dhcp tries to insert a default gateway route existing. I made ​​several tests with the "ifconfig" "route" and "dhclient" commands and I think that the default gateway is not involved, unless to do so one does not use the commands in the iproute suite...

Also you can get the message manually using more than once "ip" command of "iproute" suite.
For Example:
# ip address add 127.0.0.2/8 dev lo
# ip address add 127.0.0.2/8 dev lo

test it !