this is obsolete doc -- see http://doc.nethence.com/ instead
XEN network configuration
Dom0
Clean up the config file,
cd /etc/xen/
mv xend-config.sxp xend-config.sxp.dist
sed '/^#/d; /^$/d' xend-config.sxp.dist > xend-config.sxp
and choose some kind of xen network configuration:
http://pbraun.nethence.com/doc/sysutils_xen/network_bridge.html
http://pbraun.nethence.com/doc/sysutils_xen/network_hybrid.html
http://pbraun.nethence.com/doc/sysutils_xen/network_nat.html
http://pbraun.nethence.com/doc/sysutils_xen/network_route.html
DomU mac addresses
XEN mac addresses start with '00:16:3e'. You can either let XEN generate random mac addresses for each guest or force them within its configuration,
vif = [ 'vifname=vifname,mac=xx.xx.xx.xx.xx.xx' ]
It may be necessary on a bridged network configuration (depending on your local network area policies). Otherwise I recommend not to define any mac address in guest's configuration nor inside guest's system (remove ifcfg-eth0:HWADDR on redhat systems). It's just easyer and spares you some time.
TCP offloading
You might experience some troubles with networking in some guests. You'll have to disable TCP offloading within it. Disabling it on the dom0 side (on guest's vif) doesn't seem to help. But if you really want to, here you go,
for type in rx tx sg tso ufo gso gro lro; do
ethtool -K vguest.0 $type off 2>&1 | grep -v 'Operation not supported'
done
for tap vifs (HVM guests) also add,
for type in rx tx sg tso ufo gso gro lro; do
ethtool -K tap-vguest.0 $type off 2>&1 | grep -v 'Operation not supported'
done
References
http://wiki.xensource.com/xenwiki/XenFaq
http://www.gentoo.org/doc/en/xen-guide.xml
http://www.excentral.org/archives/2007/03/23/rhel5-xen-nating