Thanks. It looks like race condition + bug in detection of dmraid disks. Quoting interesting lines from your log.
Sep 10 22:08:48 linux-scdz systemd[1]: systemd 228 running in system mode. (+PAM -AUDIT +SELINUX -IMA +APPARMOR -SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT -GNUTLS +ACL +XZ -LZ4 +SECCOMP +BLKID -ELFUTILS +KMOD -IDN)
Sep 10 22:08:48 linux-scdz dracut-cmdline[100]: Using kernel command line parameters: rd.dm.uuid=nvidia_cbidcbcg resume=/dev/mapper/nvidia_cbidcbcg_part5 root=/dev/mapper/nvidia_cbidcbcg_part3 rootfstype=btrfs rootflags=rw,relatime,space_cache,subvolid=259,subvol=/@/.snapshots/1/snapshot,subvol=@/.snapshots/1/snapshot BOOT_IMAGE=/vmlinuz-4.4.79-18.26-default root=UUID=44aa9465-f432-40e4-81a1-1ab9b9ac2c27 resume=/dev/mapper/nvidia_cbidcbcg-part5 splash=silent quiet showopts
initrd starts. It wants to use /dev/mapper/nvidia_cbidcbcg_part3 as root device.
Sep 10 22:08:50 linux-scdz kernel: BTRFS: device fsid 44aa9465-f432-40e4-81a1-1ab9b9ac2c27 devid 1 transid 1109 /dev/sdb3
Still kernel gets /dev/sdb3 as btrfs device, most likely from udev scanning sdb3.
Sep 10 22:08:51 linux-scdz dracut-initqueue[260]: Scanning for dmraid devices nvidia_cbidcbcg
Sep 10 22:08:51 linux-scdz dracut-initqueue[260]: Found dmraid sets:
Sep 10 22:08:51 linux-scdz dracut-initqueue[260]: /dev/sdb: "pdc" and "nvidia" formats discovered (using nvidia)! nvidia_cbidcbcg
Sep 10 22:08:51 linux-scdz dracut-initqueue[260]: Activating nvidia_cbidcbcg
Sep 10 22:08:51 linux-scdz dracut-initqueue[260]: /dev/sdb: "pdc" and "nvidia" formats discovered (using nvidia)!
Sep 10 22:08:51 linux-scdz dracut-initqueue[260]: RAID set "nvidia_cbidcbcg" was activated
Sep 10 22:08:51 linux-scdz dracut-initqueue[260]: RAID set "nvidia_cbidcbcg" was not activated
dmraid itself works as intended and activates array.
Sep 10 22:08:52 linux-scdz systemd[1]: Found device /dev/mapper/nvidia_cbidcbcg-part5.
Sep 10 22:08:52 linux-scdz systemd[1]: Starting Resume from hibernation using device /dev/mapper/nvidia_cbidcbcg-part5...
We see that systemd correctly tries resume from swap on dmraid device (“correctly” meaning - it does what was configured on kernel command line).
Sep 10 22:08:52 linux-scdz systemd[1]: Starting File System Check on /dev/disk/by-uuid/44aa9465-f432-40e4-81a1-1ab9b9ac2c27...
Sep 10 22:08:52 linux-scdz systemd[1]: Started File System Check on /dev/disk/by-uuid/44aa9465-f432-40e4-81a1-1ab9b9ac2c27.
Sep 10 22:08:52 linux-scdz systemd[1]: Mounting /sysroot...
Sep 10 22:08:52 linux-scdz kernel: BTRFS info (device dm-3): disk space caching is enabled
Sep 10 22:08:52 linux-scdz kernel: BTRFS info (device dm-3): has skinny extents
Sep 10 22:08:52 linux-scdz systemd[1]: Mounted /sysroot.
Here unfortunately we do not have enough information, but I think that systemd mounts dmraid device because it says dm-3 and not sdb3.
Sep 10 22:08:56 linux-scdz kernel: systemd: 18 output lines suppressed due to ratelimiting
Not directly related but as general comment - it makes sense to always run with printk.devkmsg=on kernel parameter to restore previous kernel behavior. Otherwise some early log messages tend to get lost.
ep 10 22:08:54 linux-scdz systemd[1]: systemd 228 running in system mode. (+PAM -AUDIT +SELINUX -IMA +APPARMOR -SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT -GNUTLS +ACL +XZ -LZ4 +SECCOMP +BLKID -ELFUTILS +KMOD -IDN)
Main system is started from initrd.
Sep 10 22:08:59 linux-scdz systemd[1]: Mounting /var/spool...
Sep 10 22:08:59 linux-scdz systemd[1]: Mounting /var/lib/mariadb...
Sep 10 22:08:59 linux-scdz systemd[1]: Mounting /var/lib/mysql...
Sep 10 22:08:59 linux-scdz systemd[1]: Mounting /usr/local...
Sep 10 22:08:59 linux-scdz mount[1016]: mount: /dev/sdb3 is already mounted or /var/spool busy
Oops. Although we have seen before that root was probably mounted via dmraid device, systemd now attempts to mount subvolumes via individual disk which fails as it should. And it will end up in emergency mode
Sep 10 22:09:00 linux-scdz systemd[1]: Started Emergency Shell.
So my educated guess is following:
- During scanning of pysical disk it (incorrecly in this case) identifies it as containing btrfs filesystem so links /dev/disk/by-uuid (and others) point to physical disk.
- initrd is using configured device name (/dev/mapper/nvidia_cbidcbcg_part3) so effectively ignores these links.
- /etc/fstab is configured with UUID=xxx device for subvolumes, so when systemd tries to mount them it resolves UUID to /dev/disk/by-uuid links which points to physical device.
To get more information at least device links (or simply “ls -lR /dev”) when it fails, and /etc/fstab is needed. If my guess is right, you can workaround it by replacing UUID entries with /dev/mapper/nvidia_cbidcbcg_part3 in /etc/fstab.