From 7a018415862677c165494decc5d8ad9e06c65fb7 Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Thu, 16 Dec 2021 09:00:10 +0000 Subject: Changed lsblk to blkid where possible (#802) * Swapped lsblk for blkid * Added a hefty sleep on partprobe() And added a TODO for the future --- archinstall/lib/disk/blockdevice.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'archinstall/lib/disk/blockdevice.py') diff --git a/archinstall/lib/disk/blockdevice.py b/archinstall/lib/disk/blockdevice.py index f8575de4..2be31375 100644 --- a/archinstall/lib/disk/blockdevice.py +++ b/archinstall/lib/disk/blockdevice.py @@ -150,8 +150,7 @@ class BlockDevice: This is more reliable than relying on /dev/disk/by-partuuid as it doesn't seam to be able to detect md raid partitions. """ - for partition in json.loads(SysCommand(f'lsblk -J -o+UUID {self.path}').decode('UTF-8'))['blockdevices']: - return partition.get('uuid', None) + return SysCommand(f'blkid -s PTUUID -o value {self.path}').decode('UTF-8') @property def size(self): -- cgit v1.2.3-70-g09d2