[kwlug-disc] Converting a running Linux box to a Virtual Machine
    Chris Frey 
    cdfrey at foursquare.net
       
    Sat May 15 02:01:10 EDT 2010
    
    
  
On Sat, May 15, 2010 at 12:45:41AM -0400, unsolicited wrote:
> And rather than make you scroll all the way to the end for one last 
> thing - what do you use for a vm? I know you say QEMU, but, what, you 
> call qemu, pointing it at your disk file (image), and voila?
Something like this... I drop this into a script:
	qemu \
		-boot d -m 384 \
		-hda finaldisk.img \
		-cdrom iso/ubuntu-10.04/ubuntu-10.04-alternate-i386.iso \
		-net nic,vlan=0 -net user,vlan=0 \
		-vnc :1 \
		-usbdevice tablet
Then just connect to it with:
	vncviewer localhost:1
Yeah, it's slow, but I can leave it in the background while it's thinking.
The kernel accelerator, kqemu, used to work for me, but it doesn't
compile anymore for kernel 2.6.32.7, and I haven't looked into it yet.
> 	[And no doubt you'll have to do some fiddling for the change in 
> hardware, e.g. video now based on whatever the vm sw is pseudo-supplying.]
Well, booting into a rescue disk, such as the ubuntu disk above, will
let me boot command line, which will let me chroot into my old system.
Then I can do my apt-get dist-upgrade or aptitude dist-upgrade, while
inside a 'script' session, and save all my work.
You generally don't want to do your distro upgrade while running X.
I think it is *possible*, but it's just another chance at a headache,
so I don't.  Plus, without X, I can save on VM memory usage for the
trial run.
- Chris
    
    
More information about the kwlug-disc
mailing list