mkpart is giving me a warning message

February 20, 2019 2k views
Linux Basics CentOS

Hi,

I’m trying to partition my disk but I keep getting a warning message. When I use fdisk and create a new partition, it just hangs:

(parted) mkpart
Partition type?  primary/extended? primary
File system type?  [ext2]?
Start? 0%
End? 10GB
Warning: You requested a partition from 0.00B to 10.0GB (sectors 0..19531250).
The closest location we can manage is 512B to 1048kB (sectors 1..2047).
Is this still acceptable to you?
Yes/No? No
(parted) print list
Model: Virtio Block Device (virtblk)
Disk /dev/vda: 85.9GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags:

Number  Start   End     Size    Type     File system  Flags
 1      1049kB  85.9GB  85.9GB  primary  xfs          boot


Error: /dev/vdb: unrecognised disk label
Model: Virtio Block Device (virtblk)
Disk /dev/vdb: 451kB
Sector size (logical/physical): 512B/512B
Partition Table: unknown
Disk Flags:

(parted)

Can you help, please?

2 Answers

Hey friend!

It looks like you’re trying to add a new partition on the existing virtual disk. Given that the full size of the disk should already be allocated to the existing partition, could you describe the situation that surrounds this? There may be a better solution to the problem that this is attempting to solve.

Jarland

Hi, thanks for responding. This is a fresh droplet i created for educational reasons. So the tutorial I’m trying to follow is asking to create a partition using fdisk or parted. I understand that the full size of the disk has been allocated, but can I still partition that?

Thanks.

Have another answer? Share your knowledge.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!