[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] mount DomU root fs via. NFS



On 31/07/14 08:02, Gordan Bobic wrote:
If you want to run your dom0 on NFS root, there is nothing stopping you from making a custom initrd that will initialize your bridge device appropriately. The kernel and initrd get fetched by PXE via TFTP before the kernel even boots, so you just need to make sure your initrd brings with it everything you need to set up the bridge and initialize it before switchroot.

Extract the initrd you are using and look at the /init file. It should be just a simple shell script. You can edit it to do what you want, repack the initrd, upload it back to the tftp server, and you should be good to go.

Gordan


Just to confirm that this is possible, I'm running debian squeeze in this exact way, dom0 is NFS root, and domU are all also NFS root. In fact, the dom0 doesn't even have any HDD at all, just boot via PXE.

The main issue was to disable xen from messing with the network at bootup, the easiest way to do this was to create the xenbr0 bridge in the initrd. I thought there was a lot of work done to make this easier in more recent versions of xen (ie, xen doesn't mess with the bridge/interface config, the OS deals with that), but I haven't upgraded to current debian stable yet. One option might be to use one ethernet device for PXE/NFS, and a second ethernet device for your xenbr and the domU's, this is a nice solution to keep "user" traffic separate from your "management/storage" LAN.

Ultimately, I'd suggest having at least three ethernet interfaces, one for storage, one for management, and one for the "user" traffic, though this will depend on your traffic load and requirements, and infrastructure options.

If you need additional assistance, let me know, and I can send you some of my scripts/etc that I used to create the initrd.

Regards,
Adam

On 07/30/2014 06:03 PM, Jeenu Viswambharan wrote:

Hi,

I've Dom0 running on Vexpress with the file system mounted via. NFS. I'm
also trying to get the DomU file system mounted via. NFS.

Because the Dom0 file system is already mounted via. NFS, I believe I
can't use bridging because that'd involve taking the eth0 interface
down. A quick search suggested that bringing eth0 down will freeze the
system. I therefore instead chose to go with NAT instead.

 From [1], all that's to be done in Dom0 is to

   echo 1 > /proc/sys/net/ipv4/ip_forward

And I've in my guest configuration:

   ...
   vif = [ "script=vif-nat,ip=192.168.1.1" ]
   extra = "... root=/dev/nfs nfsroot=my.ip.add.ress:/path/to/root ..."
   ...

What I see is the guest waits to mount root file system, and later times
out and crashes. I do see messages like

   [  687.170573] IPv6: ADDRCONF(NETDEV_UP): vif3.0: link becomes ready

from Dom0. But, presumably, requests from guest aren't reaching the NFS
server.

Could you suggest if and what's wrong with my setup? Is NAT the right
mechanism for this purpose?

Thanks.

--
Jeenu

[1] http://wiki.xen.org/wiki/Host_Configuration/Networking#Network_Address_Translation_.28NAT.29


-- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.

ARM Limited, Registered office 110 Fulbourn Road, Cambridge CB1 9NJ, Registered in England & Wales, Company No: 2557590 ARM Holdings plc, Registered office 110 Fulbourn Road, Cambridge CB1 9NJ, Registered in England & Wales, Company No: 2548782


_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users



_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users


--
Adam Goryachev Website Managers www.websitemanagers.com.au

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.