Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am creating a cloud for my university using Eucalyptus with Xen (PCs have Debian Squeeze 64 bit installed). I have a problem with the following guest configuration:

# Configuration file for the Xen instance evenmorefinalfoo, created
# by xen-tools 4.2 on Thu May 26 11:03:06 2011.

#  Kernel + memory size
kernel      = '/boot/vmlinuz-2.6.32-5-xen-amd64'
ramdisk     = '/boot/initrd.img-2.6.32-5-xen-amd64'

vcpus       = '1'
memory      = '128'

#  Disk device(s).
root        = '/dev/sda2 ro'
disk        = [

As you can see, the disk and swap images are meant to be mounted on sda1 and sda2. However, when I start the guest, these are mounted on xvda1 xvda2, provoking an error. Is there anything that I can do about that? It seems like it is a Xen error.

Thank you in advance,

share|improve this question

migrated from Jun 14 '11 at 13:24

This question came from our site for professional and enthusiast programmers.

Why not mount them as xvda's then so it all agrees? – Marcin May 26 '11 at 11:53

The boot device name is coded into the kernel. You can override this by passing the appropriate kernel-parameter (or by setting the bootdev in the kernel). My guess is that your "root"-parameter is not passed to the DomU-kernel - which might indeed be an error.

Apart from that it is better to use xvd becaude sd will use SCSI/SAS/SATA-drivers by default - and not the proper xenblk-driver.

Another tip: Use soft-links within the DomUs to point to the current kernel and initrd. That way you can use these soft-links in your DomU-configuration on the Dom0 and don`t have to change that config after a kernel-upgrade in your DomU.

share|improve this answer
I'm having the same problem, the above suggestion obviously fixes the immediate issue but isn't really a proper solution. If you are telling xen to use 'sda' device names why does it listen as far as the cfg file is concerned but then create disk devices under the xvdX names? Doesn't make sense – user87554 Jul 13 '11 at 18:24
@user87554 this naming mismatch seems to occur on newer kernels - the actual driver in the DomU seems to be more important than the "name" the Dom0 passes to the DomU. – Nils May 12 '13 at 21:18

Xen uses xvda names because it is providing optimized i/o access to those drives. If you are running Xen in PV mode, then all your drives will show up as xvd... If you are running in HVM mode, then you will get the standard (and slower, less reliable) sd... drives.

Hope this helps!

share|improve this answer
The name of the disk device does not say anything about the driver behind it - if you are in PV mode your DomU will use the xenblk-driver for that device - may it be named sda, hda or xvda. But: Normally linux does not associate sda/hda with xenblk. So xvda is easier. – Nils Aug 30 '11 at 20:24
Sorry I guess I was wrong Nils. In my personal experience, running OpenSuse 11.4, the drives always come up in xvd... when I'm in PV and sda if I'm in HVM. Thanks for the correction – portforwardpodcast Aug 31 '11 at 8:01
Give it a try - edit your DomU config file and change xvda to hda (dont forget /etc/fstab in your DomU if you dont use labels) - don`t forget to pass "root=hda..." to the kernel and try to reboot. Your PV DomU should come up with hda. Perhaps you can edit your answer after that accordingly... – Nils Sep 12 '11 at 20:02

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.