/dev/disk/by-id does not exist for virtio devices

Bug #635096 reported by Scott Moser on 2010-09-10
24
This bug affects 5 people
Affects Status Importance Assigned to Milestone
udev (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: udev

Inside an UEC instance with the root filesystem on /dev/vda1 (USE_VIRTIO_ROOT="1" in node controllers /etc/eucalyptus/eucalyptus.conf), there is no /dev/disk/by-id.

I really doubt that this is at all related to uec, but more generally a udev/virtio disk issue.

possibly useful information from dmesg:

[ 0.471820] virtio-pci 0000:00:03.0: irq 40 for MSI/MSI-X
[ 0.471822] alloc irq_desc for 41 on node -1
[ 0.471824] alloc kstat_irqs on node -1
[ 0.471846] virtio-pci 0000:00:03.0: irq 41 for MSI/MSI-X
[ 0.582796] vda: vda1 vda2 vda3

$ find /dev/disk/
/dev/disk/
/dev/disk/by-label
/dev/disk/by-label/uec-rootfs
/dev/disk/by-uuid
/dev/disk/by-uuid/c6e208f8-40e8-46b1-8e7d-cebb8e21c2ef
/dev/disk/by-uuid/dbf87ebc-9925-4077-9bf4-456dec7225e6
/dev/disk/by-uuid/ce7e5e11-06eb-4848-8b78-0d2def5e270e
/dev/disk/by-path
/dev/disk/by-path/virtio-pci-virtio0-part2
/dev/disk/by-path/virtio-pci-virtio0-part3
/dev/disk/by-path/virtio-pci-virtio0-part1
/dev/disk/by-path/virtio-pci-virtio0

ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: udev 161+git20100825-1
ProcVersionSignature: User Name 2.6.35-19.28-virtual 2.6.35.3
Uname: Linux 2.6.35-19-virtual i686
Architecture: i386
CurrentDmesg:

Date: Fri Sep 10 16:21:20 2010
Lsusb: Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
MachineType: Bochs Bochs
ProcCmdLine: root=/dev/vda1 console=ttyS0
ProcEnviron:
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: udev
dmi.bios.date: 01/01/2007
dmi.bios.vendor: Bochs
dmi.bios.version: Bochs
dmi.chassis.type: 1
dmi.chassis.vendor: Bochs
dmi.modalias: dmi:bvnBochs:bvrBochs:bd01/01/2007:svnBochs:pnBochs:pvr:cvnBochs:ct1:cvr:
dmi.product.name: Bochs
dmi.sys.vendor: Bochs

Scott Moser (smoser) wrote :
Colin Watson (cjwatson) wrote :

I've looked at this, and I think that this is because there's no rule that adds any program to IMPORT that's capable of getting an ID_SERIAL from virtio devices. Some virtio devices apparently chain through to SCSI ioctls, but I don't know how widespread that is, and in any case scsi_id doesn't seem to do anything useful on smoser's device.

You can do something like this on a virtio device:

  char id_str[20];
  ioctl(fd, 0x56424944 /* 'VBID' */, id_str);

The returned data seems to be a pile of binary data and probably needs to be encoded in some way (I don't know whether that's intentional or a bug somewhere). Perhaps we should have a new virtio_id program for this?

Dave Gilbert (ubuntu-treblig) wrote :

I can confirm the same problem affects maverick running as a kvm guest on maverick.

(I do actually have a /dev/disk/by-id but the only thing in it are lvm partitions, not the underlying /dev/vda)

Dave

Scott Moser (smoser) on 2010-09-11
Changed in udev (Ubuntu):
status: New → Confirmed
Alfredo Scotto (alfredo-asc8) wrote :

The issue is created by bundling the new AMI, the process is not copying the /dev. Booting the new instance Grub has the definition of root using LABEL=....
To fix:
 1) edit /etc/fstab updating the LABEL=... with /dev/sda1
 2) edit /boot/grub/menu.lst doing the same
 3) run update-grub to rebuild the grub config

After that the new AMI bundled will boot correctly

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers