util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Weird behaviour with lsblk and freshly created loop device
@ 2014-09-01 15:39 Francis Moreau
  2014-09-01 15:40 ` Francis Moreau
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Francis Moreau @ 2014-09-01 15:39 UTC (permalink / raw)
  To: util-linux

Hello,

Right after associating a loop device with a disk image file, I'm using
lsblk to retrieve some info about the partitions.

If I'm doing this as root:

  $ losetup /dev/loop0 /tmp/installer-disks/disk0.img && lsblk -n --raw
--paths -o NAME,PARTTYPE /dev/loop0 && losetup -d /dev/loop0

then the output is missing the parttypes:

  /dev/loop0
  /dev/loop0p1
  /dev/loop0p2

However adding a sleep or 'udevadm settle' after setting the loop device
the parttypes are correctly showed:

   $ losetup /dev/loop0 /tmp/installer-disks/disk0.img && udevadm settle
&& lsblk -n --raw --paths -o NAME,PARTTYPE /dev/loop0 && losetup -d
/dev/loop0
  /dev/loop0
  /dev/loop0p1 0657fd6d-a4ab-43c4-84e5-0933c84b4f4f
  /dev/loop0p2 4f68bce3-e8cd-4db1-96e7-fbcaf984b709

Could anybody tell me if that's expected ?

Thanks.

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2014-09-05  8:13 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-01 15:39 Weird behaviour with lsblk and freshly created loop device Francis Moreau
2014-09-01 15:40 ` Francis Moreau
2014-09-01 17:56 ` Karel Zak
2014-09-02  7:03   ` Francis Moreau
2014-09-02  7:30     ` Karel Zak
2014-09-02 16:45       ` Francis Moreau
2014-09-05  7:45         ` Karel Zak
2014-09-05  8:13           ` Francis Moreau
2014-09-01 19:41 ` Dale R. Worley
2014-09-02  6:54   ` Francis Moreau

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).