WARNING - OLD ARCHIVES

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/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: xvd Xen virtual block device (Was: Re: [Xen-users] Pardon me for pos

To: xen-users@xxxxxxxxxxxxxxxxxxx, deshantm@xxxxxxxxx
Subject: Re: xvd Xen virtual block device (Was: Re: [Xen-users] Pardon me for possibly dumb question but....)
From: Mark Williamson <mark.williamson@xxxxxxxxxxxx>
Date: Mon, 28 Jan 2008 15:14:33 +0000
Cc: Lionel Kernux <lionel.kernux@xxxxxxxxx>
Delivery-date: Mon, 28 Jan 2008 07:15:15 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <1e16a9ed0801271655k8c1a59ck57f16db227545e1b@xxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <1e16a9ed0801271655k8c1a59ck57f16db227545e1b@xxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.9.6 (enterprise 0.20070907.709405)
> xvd is the Xen virtual block device. The xvd interface does not truly
> emulate IDE or SCSI, but you can think of it as similar to hd (for IDE) and
> sd (for SCSI).
>
> So in practice, instead of using hda or sda for your guest block devices
> you can use xvda. This allows the guest to realize that it is Xen block
> device and it is able to take advantage of performance optimizations. This
> works well with paravirtual guests, but for HVM guests the PV driver would
> need to be added.

Actually, if you're using a paravirt guest then it shouldn't matter to the 
performance whether you're using hd*, sd* or xvd* to name the devices you're 
exporting to the guest.  In any of those cases, it's still really going 
through the PV block driver and able to take advantage of paravirt 
optimisations.

The Xen PV block drivers were originally written to sneakily steal device 
numbers allocated to IDE and SCSI devices so that the guest could look more 
like the native case and avoid the need to configure guests explicitly to use 
Xen block devices.

That sneaky approach is now rather deprecated: the kernel.org Linux people 
didn't like it, and if you're running PV-on-HVM you don't want the names of 
PV block devices to clash with those of emulated block devices.  Also, with 
PCI passthrough you might have *real* SCSI or IDE drives passed through to a 
guest too, which would also clash.

The xvd* naming scheme is what distros generally use now to identify Xen PV 
block devices.  I think there's still some support for exporting PV block 
devices as hd* or sd* but most distro-provided tools don't do this by 
default.

In practice, many distros now identify block devices by either the ID of their 
filesystem (UUID= syntax; Ubuntu uses this) or by the filesystem label 
(LABEL= syntax; Fedora uses this).  This means that the name of the device 
doesn't matter so much in practice anymore - good :-)

Cheers,
Mark

> Note that you can also use xvda1, xvdb, xvdc, xvdb2, etc. etc.
>
> Regards,
> Todd
>
> > _______________________________________________
> > Xen-users mailing list
> > Xen-users@xxxxxxxxxxxxxxxxxxx
> > http://lists.xensource.com/xen-users



-- 
Push Me Pull You - Distributed SCM tool (http://www.cl.cam.ac.uk/~maw48/pmpu/)

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

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