Disappearing routes in HN
Sometimes people complain about VE-related routes disappering in HN.
These routes usually look like this:
# ip r l <skip> 192.168.225.195 dev venet0 scope link
and tell the kernel that IP address 192.168.225.195 belongs to venet0 device. Thus packets with destination IP equal to 192.168.225.195 are forwarded to venet0 and then to appropriate VE.
The problem is usually one of these:
- DHCP client. If your host system uses DHCP for acquiring IP address, then DHCP is for sure to blame. DHCP client tries to be smart and resets all the routes to those got from the server. Check your logs for DHCP re-lease events or other messages correlating with routes disappearing.
- Hotplug events. Modern Linux distros come with hotplug subsytem which tries to handle events like "new device found", "device was unplugged", etc. It also tries to be smart when LINK is DOWN/UP event from network device is received and can remove manually set routes. Check that your dmesg have anything related to this events. (AFAIK SUSE is the worst distro in this regard).
If you still can't find what happens with your network settings try to replace /sbin/ip and /sbin/route with scripts logging the commands and programs which executed them and calling original binaries after that. This will help to find the victim if it's some script. More robust but similar debug can be added to kernel if first approach doesn't help.