This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


RE: [Xen-users] Bootable LiveDVD w/ Xen that boots Windows Image?

Hmm, I didn't think of it that way.

The way I read up on UnionFS and aufs' functionality, was they could 
essentially merge two files virtually, i.e., the kernel module would be able to 
look at the operation coming in and route it to the proper descriptor (i.e., 
read() --> /livecd/windows/winxp.img OR write() --> /tmp/winxp.img, with /tmp 
being in tmpfs).  I guess it's not as granular as that it seems.  Would be a 
neat trick, but I imagine it'd be complex as anything for a kernel module to 
have to keep track of which files have variants loaded in the writeable union 

I have yet to try and do a squashfs on the filesystem...Right now, I have the 
Windows domU sitting right at 3.5GB, and I've used the sysinternals 'sdelete' 
tool to fill all remaining free space with zero data, so that should allow 
squashfs to compress it down really far.  But I know that squashfs is 
read-only, too, and inflated, only a loaded x64 server would be able to hold a 
3.5GB image in memory.  Kinda scratches that idea off of the table.  Maybe I'll 
have to go the OpenSolaris way after all?

As for the application, it's a complex network security scanner, made by eEye 
Digital Security, called "Retina".  We just don't want to setup and baby sit 
Windows installations on our Unix networks strictly for this one app, so I 
figured if I can get it to run off of a CD, we can just park some diskless 
hardware in a closet and pull it out whenever we need to do network testing and 
such.  I've already tried BartPE and ReatogoxPE, and while the latter lets me 
generate a plugin from the installed application, that version doesn't work 
because of the age-old nemesis, the Windows Registry.  I'm not too keen on 
trying to track down every little key this program will modify just to record 
it into the BartPE stuff, as it all has to be encoded into INI files for the 
plugins that pebuilder uses.

So I figured trying to virtualize the whole mess would be easier.  Tried Wine 
first, but the program's installer makes some advanced use of MSI functions, 
and one particular call, WixSchedFirewallUpdate or something, isn't implemented 
in Wine, so it fails (Wix appears to be an OSS project, too, but their 
documentation didn't help any).  Next, I looked at VMWare Server (free), but 
the license gets in the way, then VirtualBox, and that license is in the way as 
well.  Checked Wikipedia's list of other Virtualization solutions, and none of 
them seem "free enough", save Xen and KVM, and Xen sounded like the better one 
to tackle.

That of course leads into the problem of Window's habit of scribbling 
everywhere when it boots.  No idea how BartPE works around that...It does 
appear they offload a bit of stuff into ram for read/write, so it's possible 
that they offload the registry hives somehow, but I haven't dug deep enough to 
find out how, and implementing that inside of a VM might be difficult, as I 
imagine I'd have to create images in tmpfs from Linux, then get Xen to share 
them to the Windows image as another physical drive for it to use, and then 
direct Windows to write all changes to that drive instead of C:.

If I get this entire concept to work, I'll probably go on to prove that black 
is white....  :)



From: Fajar A. Nugraha [fajar@xxxxxxxxx]
Sent: Thursday, August 13, 2009 1:49 AM
To: Joshua Kinard
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-users] Bootable LiveDVD w/ Xen that boots Windows Image?

On Wed, Aug 12, 2009 at 8:41 PM, Joshua
Kinard<joshua.kinard@xxxxxxxxxxxxx> wrote:
> Hi Fajar,
> Yup, read more about the qcow stuff after digging around on Google some.  
> Even came across some of your messages on a thread or two about it.  I'll 
> probably give this a shot and see what happens, though I think I'm going to 
> try combining this with the UnionFS (aufs specifically) stuff.  I've read 
> that might work better, since I'll be able to keep the squashfs'ed WinXP 
> qcow2 image on the DVD itself and not have to offload it into RAM, but 
> somehow create a r/w qcow2 image in tmpfs, probably ntfs format it, and allow 
> aufs to overlay that somehow.  Although, I'm not sure in what order to do 
> that just yet.  Once I figure it out, scripting will be the easy part.

Am I right in assuming you want to use aufs on Windows? AFAIK it
doesn't run on Windows.

The other approach with aufs probaly won't work either. You CAN use
aufs to merge the squashfs content with ramdisk to create a "writable"
root fs for the dom0 (not for Windows), but the way aufs works when
there's a change in a file (e.g. the WInXP image file) it will copy
the WHOLE file to r/w location, and change it there. That would be
unusable as the image would be several GB in size.

So my best suggestion is you probably can use aufs for the live CD
part, but you can't use it for the domU image. You'd have to split it
into a base image which can be read only on DVD, and a qcow
incremental image (is this the right term?) which can be on RAM.

> As far as VirtualBox goes, I've played around with the OSE edition (that's 
> all Debian distributes in Lenny), and the problems with it are that A) It's a 
> bit aged (~1.6-something in Lenny), and B) I believe I need the Guest 
> Additions in order for WinXP to properly utilize the network driver presented 
> to it by the Vbox virtual layer, and that's not free.

Yeah, I forgot about the guest addition :)

BTW, what kind of WIndows application are you going to use? Some
applications (like Firefox, vnc, etc.) CAN be made to run on windows
"live" CD using BARTPE. If it works you'd save the overhead of dom0
and Xen. See http://www.nu2.nu/pebuilder/

Xen-users mailing list

<Prev in Thread] Current Thread [Next in Thread>