fdisk shows 'Failed to add partition 1 to system: Invalid argument' message
Issue
-
fdisk command shows following messages while trying to partition the multipath device. Same messages are not displayed when partitioning the /dev/sdx device paths:
[root@testvm ~]# fdisk /dev/mapper/mpathb Welcome to fdisk (util-linux 2.32.1). Changes will remain in memory only, until you decide to write them. Be careful before using the write command. Device does not contain a recognized partition table. Created a new DOS disklabel with disk identifier 0xb5f4c837. Command (m for help): p Disk /dev/mapper/mpathb: 2 GiB, 2147483648 bytes, 4194304 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: dos Disk identifier: 0xb5f4c837 Command (m for help): n Partition type p primary (0 primary, 0 extended, 4 free) e extended (container for logical partitions) Select (default p): p Partition number (1-4, default 1): First sector (2048-4194303, default 2048): Last sector, +sectors or +size{K,M,G,T,P} (2048-4194303, default 4194303): Created a new partition 1 of type 'Linux' and of size 2 GiB. Command (m for help): t Selected partition 1 Hex code (type L to list all codes): 8e Changed type of partition 'Linux' to 'Linux LVM'. Command (m for help): p Disk /dev/mapper/mpathb: 2 GiB, 2147483648 bytes, 4194304 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: dos Disk identifier: 0xb5f4c837 Device Boot Start End Sectors Size Id Type /dev/mapper/mpathb-part1 2048 4194303 4192256 2G 8e Linux LVM Command (m for help): w The partition table has been altered. Failed to add partition 1 to system: Invalid argument <--- The kernel still uses the old partitions. The new table will be used at the next reboot. <--- Syncing disks.
-
Does this message indicate any issue with newly created partition or it is expected and could be ignored?
Environment
- Red Hat Enterprise Linux 7, 8, 9
- dm-multipath
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.