[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: Re: [Xen-users] DomU networking help please
Yippee I finally worked it out. Here is what I had to do. Step 1. after booting up do xend stop and xend start. This sets up the basic bridging. (doesn't do it from boot) Step 2. run network start from /etc/xen/scripts This sets up as shown below in the dom0 ifconfig. Setp 3. Start domU. Step 4 run the following from /etc/xen/scripts ./vif-bridge up domain=RHL vif=vif1.0 bridge=xen-br0 mac="aa:bb:cc:dd:00:11" where vif1.0 equates to the virtual nic for domu as seen in dom0 and mac is the mac address given to the nic in domu from the domu config script. I can now ping everywhere from domu. > > From: Kent Watsen <kent@xxxxxxxxxx> > Date: 2005/10/06 Thu PM 05:59:05 GMT+13:00 > To: Andrew Olds <aolds@xxxxxxxxxx> > CC: xen-users@xxxxxxxxxxxxxxxxxxx > Subject: Re: [Xen-users] DomU networking help please > > > They appear to be on different subnets - are you using an external > router? - if so, make sure you have a default route to the gateway, > otherwise try setting the DomU's IP to something the in the Dom0's > network... > > Kent > > > Andrew Olds wrote: > > >Hi please forgive this if it seems a dumb question but I am new to xen and > >linux. I have Xen running in Centos and another Centos Partition DomU > >running. > >But I cannot seem to get networking running between 0 and U. > >All the doco appears to assume you know everything about networking bridging > >and the like. Does anyone have a simple how to step by step on how to get a > >single dom0 talking to a single DomU. > >Below is the output from ifconfig from dom0 > >eth0 Link encap:Ethernet HWaddr 00:11:11:BD:C0:23 > > inet addr:10.0.0.5 Bcast:10.0.0.255 Mask:255.255.255.0 > > UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 > > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > > TX packets:6 errors:0 dropped:0 overruns:0 carrier:0 > > collisions:0 txqueuelen:0 > > RX bytes:0 (0.0 b) TX bytes:672 (672.0 b) > > > >lo Link encap:Local Loopback > > inet addr:127.0.0.1 Mask:255.0.0.0 > > UP LOOPBACK RUNNING MTU:16436 Metric:1 > > RX packets:1383 errors:0 dropped:0 overruns:0 frame:0 > > TX packets:1383 errors:0 dropped:0 overruns:0 carrier:0 > > collisions:0 txqueuelen:0 > > RX bytes:1417720 (1.3 MiB) TX bytes:1417720 (1.3 MiB) > > > >peth0 Link encap:Ethernet HWaddr FE:FF:FF:FF:FF:FF > > UP BROADCAST RUNNING NOARP MULTICAST MTU:1500 Metric:1 > > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > > TX packets:4 errors:0 dropped:0 overruns:0 carrier:0 > > collisions:0 txqueuelen:1000 > > RX bytes:0 (0.0 b) TX bytes:640 (640.0 b) > > Interrupt:16 > > > >vif0.0 Link encap:Ethernet HWaddr FE:FF:FF:FF:FF:FF > > UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 > > RX packets:6 errors:0 dropped:0 overruns:0 frame:0 > > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > > collisions:0 txqueuelen:0 > > RX bytes:672 (672.0 b) TX bytes:0 (0.0 b) > > > >xen-br0 Link encap:Ethernet HWaddr FE:FF:FF:FF:FF:FF > > inet addr:10.0.0.5 Bcast:10.0.0.255 Mask:255.255.255.255 > > UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 > > RX packets:6 errors:0 dropped:0 overruns:0 frame:0 > > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > > collisions:0 txqueuelen:0 > > RX bytes:588 (588.0 b) TX bytes:0 (0.0 b) > > > >and domU > >eth0 Link encap:Ethernet HWaddr AA:BB:CC:DD:00:11 > > inet addr:10.1.0.5 Bcast:10.1.0.255 Mask:255.255.255.0 > > UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 > > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > > TX packets:65 errors:0 dropped:0 overruns:0 carrier:0 > > collisions:0 txqueuelen:1000 > > RX bytes:0 (0.0 b) TX bytes:2730 (2.6 KiB) > > > >lo Link encap:Local Loopback > > inet addr:127.0.0.1 Mask:255.0.0.0 > > UP LOOPBACK RUNNING MTU:16436 Metric:1 > > RX packets:117 errors:0 dropped:0 overruns:0 frame:0 > > TX packets:117 errors:0 dropped:0 overruns:0 carrier:0 > > collisions:0 txqueuelen:0 > > RX bytes:10220 (9.9 KiB) TX bytes:10220 (9.9 KiB) > > > >and my config file. > ># -*- mode: python; -*- > >#============================================================================ > ># Python configuration setup for 'xm create'. > ># This script sets the parameters used when a domain is created using 'xm > >create'. > ># You use a separate script for each domain you want to create, or > ># you can set the parameters for the domain on the xm command line. > >#============================================================================ > > > >#---------------------------------------------------------------------------- > ># Kernel image file. > >kernel = "/boot/vmlinuz-2.6.12-xenU" > > > ># Optional ramdisk. > >ramdisk = "/boot/initrd-2.6.12-xen0" > > > ># The domain build function. Default is 'linux'. > >#builder='linux' > > > ># Initial memory allocation (in megabytes) for the new domain. > >memory = 128 > > > ># A name for your domain. All domains must have different names. > >name = "RHL" > > > ># Which CPU to start domain on? > >#cpu = -1 # leave to Xen to pick > > > >#---------------------------------------------------------------------------- > ># Define network interfaces. > > > ># Number of network interfaces. Default is 1. > >nics = 1 > > > ># Optionally define mac and/or bridge for the network interfaces. > ># Random MACs are assigned if not given. > >vif = [ 'mac=aa:bb:cc:dd:00:11, bridge=xen-br0' ] > > > >#---------------------------------------------------------------------------- > ># Define the disk devices you want the domain to have access to, and > ># what you want them accessible as. > ># Each disk entry is of the form phy:UNAME,DEV,MODE > ># where UNAME is the device, DEV is the device name the domain will see, > ># and MODE is r for read-only, w for read-write. > > > >disk = [ 'phy:/dev/VolGroup00/LogVol00,sda1,w' ] > > > >#---------------------------------------------------------------------------- > ># Set the kernel command line for the new domain. > ># You only need to define the IP parameters and hostname if the domain's > ># IP config doesn't, e.g. in ifcfg-eth0 or via DHCP. > ># You can use 'extra' to set the runlevel and custom environment > ># variables used by custom rc scripts (e.g. VMID=, usr= ). > > > ># Set if you want dhcp to allocate the IP address. > >#dhcp="dhcp" > ># Set netmask. > >#ipaddr="192.168.0.3" > >#netmask="255.255.255.0" > ># Set default gateway. > >#gateway="192.168.0.1" > ># Set the hostname. > >#hostname= "vm%d" % vmid > >hostname = "RHL" > > > ># Set root device. > >root = "/dev/sda1 ro" > > > ># Root device for nfs. > >#root = "/dev/nfs" > ># The nfs server. > >#nfs_server = '169.254.1.0' > ># Root directory on the nfs server. > >#nfs_root = '/full/path/to/root/directory' > > > ># Sets runlevel 4. > >extra = "5" > > > >#---------------------------------------------------------------------------- > ># Set according to whether you want the domain restarted when it exits. > ># The default is 'onreboot', which restarts the domain when it shuts down > ># with exit code reboot. > ># Other values are 'always', and 'never'. > > > >#restart = 'onreboot' > > > >#============================================================================ > > > >All I am looking for is a really simple explanation of what all the > >interfaces do and how to get the doms talking to each other. > > > >Thanks very much > > > > > >_______________________________________________ > >Xen-users mailing list > >Xen-users@xxxxxxxxxxxxxxxxxxx > >http://lists.xensource.com/xen-users > > > > > > _______________________________________________ Xen-users mailing list Xen-users@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-users
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |