Description of problem: # modprobe nbd max_part=16 # qemu-nbd -c /dev/nbd0 f23.qcow2 # lsblk --fs /dev/nbd0 NAME FSTYPE LABEL UUID MOUNTPOINT nbd0 ├─nbd0p1 ├─nbd0p2 └─nbd0p3 the problem is that udev db does not contain ID_FS_* data for the partitions, but blkid is able to detect filesytems on the device, for example: # blkid -p /dev/nbd0p1 -o udev ID_FS_UUID=06b7c95e-edd0-4bf8-9053-6c8c04a4ceb2 ID_FS_UUID_ENC=06b7c95e-edd0-4bf8-9053-6c8c04a4ceb2 ID_FS_VERSION=1.0 ID_FS_TYPE=ext2 ID_FS_USAGE=filesystem ID_PART_ENTRY_SCHEME=dos ID_PART_ENTRY_UUID=c6c18c62-01 ID_PART_ENTRY_TYPE=0x83 ID_PART_ENTRY_FLAGS=0x80 ID_PART_ENTRY_NUMBER=1 ID_PART_ENTRY_OFFSET=2048 ID_PART_ENTRY_SIZE=409600 ID_PART_ENTRY_DISK=43:0 How reproducible: udev during qemu-ndb --connect: # udevadm monitor monitor will print the received events for: UDEV - the event which udev sends out after rule processing KERNEL - the kernel uevent KERNEL[86215.879813] change /devices/virtual/block/nbd0 (block) KERNEL[86215.879858] add /devices/virtual/block/nbd0/nbd0p1 (block) KERNEL[86215.879902] add /devices/virtual/block/nbd0/nbd0p2 (block) KERNEL[86215.879937] add /devices/virtual/block/nbd0/nbd0p3 (block) UDEV [86215.881516] change /devices/virtual/block/nbd0 (block) UDEV [86215.882053] add /devices/virtual/block/nbd0/nbd0p1 (block) UDEV [86215.882375] add /devices/virtual/block/nbd0/nbd0p2 (block) UDEV [86215.882433] add /devices/virtual/block/nbd0/nbd0p3 (block) Additional info: I guess the problem is logic around nbd in /usr/lib/udev/rules.d/99-systemd.rules: # Ignore nbd devices in the "add" event, with "change" the nbd is ready ACTION=="add", SUBSYSTEM=="block", KERNEL=="nbd*", ENV{SYSTEMD_READY}="0" from the monitor it seems that the partitions are added by ADD event, maybe the rule should be more careful and don't ignore partition...
Does it work if copy the file to /etc/udev/rules.d/99-systemd.rules and change KERNEL=="nbd*" to KERNEL=="nbd*", KERNEL!="nbd*p*" ?
Maybe nbd just needs to be added to the new whitelisting in rules/60-persistent-storage.rules ? This used to be blacklisting, but we recently turned this around...
https://github.com/systemd/systemd/pull/174
Closing, see upstream ticket.