[lug] kvm drive i/o - nfs vs direct mount

Michael J. Hammel mjhammel at graphics-muse.org
Tue Apr 5 20:18:33 MDT 2011


On Tue, 2011-04-05 at 19:49 -0600, Lee Woodworth wrote:
> I don't use libvirt or such to configure or launch the VM, so here are some
> things to compare with your setup (this an AMD64):

(snip)

Lots of interesting stuff to check.  I'll dig into it later.  'Course by
the time I get through weeding through all the kernel and network config
stuff I could probably have just bought another box (which I may just
do). :-)
 
> > <disk type='block' device='disk'>
> >   <source dev='/dev/sdb1'/>
> >   <target dev='vdb' bus='scsi'/>
>                            ^^^^
> Seems like you are asking for an emulated scsi host/disk setup. Is that
> what you really want?

I was just hoping there was some way to have physical hardware mounted
directly into the guest.  It was a wild-ass guess on my part.  

> On Gentoo, I switch some LVM volumes between the host & guest. Only one OS
> can have the volume mounted at any time. The VIRTIO_BLK helps here, no
> emulated controller used. Below, change the /dev/mapper/xxxx to /dev/sdb1
> for your case. (Caveat - the guest & host kernel versions must both support
> the same VIRTIO_BLK implementation as the kernel config notes say it is not
> a stable interface. Make both kernels the same if possible).

That will require rebuilding the kernel for Ubuntu, which is the guest,
and which is the one I'm having problems with I/O on.  So that may not
help in my case.  Although I could build a .dev on Fedora and copy it
over, I suppose.

> I don't know how the Ubuntu tools set things up, so you will have to experiment.
> On the guest: ls /dev/vd* to see if VIRTIO_BLK devices are already setup. Another
> check is to use lsmod and see if virtio_blk is loaded.

Yup.  VIRTIO_BLK is loaded on the guest.  The main qcow image is mounted
on vba1 and vba2.  That was what led me (along with some libvirt
documentation) to think I might be able to configure the <disk> section
to get access to a physical disk partition.  

Ah, the heck with it.  Throw more iron at the problem.  It's easier.
All this file system stuff makes my head spin.  :-)  Since I have an
extra mobo sitting in my office with CPU and memory, all I need is to
dig up an old case and get a power supply and I can just run it
natively.  What's a few more 000's of watts heating my office?  I may be
single handedly responsible for keeping winter mild in Colorado Springs
this year....

-- 
Michael J. Hammel                               
mjhammel at graphics-muse.org / http://www.graphics-muse.org
------------------------------------------------------------------------------
He would be out of his depth in a parking lot puddle. -- From a real employee
performance evaluation.




More information about the LUG mailing list