I created a mapper device with dmsetup and created a partition table with parted:
$ fdisk -l /dev/mapper/vdisk Disk /dev/mapper/vdisk: 511.57 GiB, 549295737344 bytes, 1072843237 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disklabel type: gpt Disk identifier: OMITTED Device Start End Sectors Size Type /dev/mapper/vdisk-part1 2048 204799 202752 99M EFI System /dev/mapper/vdisk-part2 204800 1072841188 1072636389 511.5G Microsoft basic data Now how do I manipulate the partitions, say format the first partition to FAT? /dev/mapper/vdisk-part1 or /dev/mapper/vdisk1 don't seem to exist.
PS: I do remember /dev/mapper/vdisk1 or something similar appeared after creating the partition table with parted, but disappeared after a reboot.
dmsetupcommand you used ? May you share the result ofls -lhiar /dev/mapper/? thanks