[PVE-User] by-id devices all changed to /dev devices

Lindsay Mathieson lindsay.mathieson at gmail.com
Thu Aug 20 14:20:11 CEST 2015


This is happening on every reboot, it is most concerning.

I asked over on the zfsonlinux list and got the following answer

*The details would vary depending on which system components they use, but
as I recall:*
*- if you create a pool with by-id, it will store the by-id devices in
zpool.cache*
*- during boot, zfs will try to use zpool.cache to import devices*
*- if for whatever reason zpool.cache is not available during import phase
(e.g. stale initrd) or by-id links changed (I've seen this on some versions
of ubuntu, forgot which, making the links as seen by initramfs is different
from ones seen by userland tools after boot completes), some version of
initramfs will try to use whatever is in /dev directly*
*- the problem above might happen if you load zfs module from initramfs
(i.e. using zfs root), but should not happen when you use it normally (i.e.
you do NOT have zfs-initramfs installed)*


Since I'm not using zfs for boot, can I safely uninstall zfs-initramfs?


I setup a 6 disk pool (3VDEV Mirrors) + SLOG and L2ARCHE on SSD using the
/dev/disk/by-id names.

zpool status
  pool: zfs_vm
state: ONLINE
  scan: none requested
config:

        NAME                                                STATE     READ
WRITE CKSUM
        zfs_vm                                              ONLINE
0     0     0
          mirror-0                                          ONLINE
0     0     0
            ata-WDC_WD6000HLHX-01JJPV0_WD-WX41E81ZU901      ONLINE
0     0     0
            ata-WDC_WD6000HLHX-01JJPV0_WD-WX81E81AFWJ4      ONLINE
0     0     0
          mirror-1                                          ONLINE
0     0     0
            ata-WDC_WD6000HLHX-01JJPV0_WD-WX41E81ZV240      ONLINE
0     0     0
            ata-WDC_WD6000HLHX-01JJPV0_WD-WX41E81ZV027      ONLINE
0     0     0
          mirror-2                                          ONLINE
0     0     0
            ata-WDC_WD6000HLHX-01JJPV0_WD-WX41E81ZU903      ONLINE
0     0     0
            ata-WDC_WD6000HLHX-01JJPV0_WD-WXB1E81EFFT2      ONLINE
0     0     0
        logs
          ata-INTEL_SSDSC2BW120H6_CVTR5146027K120AGN-part1  ONLINE
0     0     0
        cache
          ata-INTEL_SSDSC2BW120H6_CVTR5146027K120AGN-part2  ONLINE
0     0     0

After a couple fo reboots I see that all the devices have changed to the
/dev/sd* names!

zpool status
  pool: zfs_vm
state: ONLINE
  scan: none requested
config:

        NAME                                                STATE     READ
WRITE CKSUM
        zfs_vm                                              ONLINE
0     0     0
          mirror-0                                          ONLINE
0     0     0
            sda                                             ONLINE
0     0     0
            sdb                                             ONLINE
0     0     0
          mirror-1                                          ONLINE
0     0     0
            sdc                                             ONLINE
0     0     0
            sdd                                             ONLINE
0     0     0
          mirror-2                                          ONLINE
0     0     0
            sde                                             ONLINE
0     0     0
            sdf                                             ONLINE
0     0     0
        logs
          sdh1                                              ONLINE
0     0     0
        cache
          ata-INTEL_SSDSC2BW120H6_CVTR5146027K120AGN-part2  ONLINE
0     0     0


I changed them back by doing a:

  zpool export zfs_vm
  root at vna:~# zpool import -d /dev/disk/by-id/

But I have no idea how it happened in the first place.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.proxmox.com/pipermail/pve-user/attachments/20150820/cdc7b3d6/attachment.htm>


More information about the pve-user mailing list