On 06/20/2011 05:50 PM, Kevin Bowling wrote: > Debian Squeeze Dom0, up to date. > > Networking is handled by OS scripts, such that br0 and br1 are bridge > interfaces. > > Without warning, the DomU (Ubuntu 10.04 LTS) loses inbound connectivity. It > tends to happen after several hours. It doesn't seem to be affected by > throughput and is triggering on very small ammounts (5MB in and out over that > time). Having active traffic doesn't help, it still dies. > > Updated the DomU to kernel 2.6.35 with no change. I suspect the problem lies > on the Dom0 side. > > It's possible to "revive" the DomU for a short while by getting a console > with xm on Dom0 and then sending pings to the Dom0 and other hosts.
My guess is that what's happening isn't what you say. It might well be due to your switch forgetting about the MAC address of your domU, if there's no network activity on it (at least that's my guess, and it did happen as well with Lenny and Debian as domU). I had the issue in many data centers/switches, and I wrote a small python script to fix it in a cron job. I have attached the script to this email. As you can see, this script looks into /etc/xen/auto. So make sure that you have symlink to configuration files in that folder. Cheers, Thomas
#!/usr/bin/env python import glob import re import subprocess import os import sys pathspec = "/etc/xen/auto/*" regexp = re.compile(r"vif.*?=.*?ip=([0-9\. ]+)'") files = glob.glob(pathspec) contents = ( file(t).read(-1) for t in files ) def ips(contents): matches = regexp.findall("\n".join(list(contents))) for match in matches: mips = match.split(" ") for ip in mips: yield ip devnull = file("/dev/null","w") procs = ( subprocess.Popen(["ping",ip,"-c","1"],stdin=devnull,stdout=devnull,stderr=devnull) for ip in ips(contents) ) returncodes = ( proc.wait() for proc in list(procs) ) sys.exit(sum(returncodes))