parted /dev/sda
Number Start End Size Type File system Flags
1 1049kB 50.1GB 50.1GB primary ntfs boot
2 50.1GB 100GB 50.0GB primary ext4
3 150GB 200GB 50.1GB primary ext4
4 200GB 230GB 30.0GB extended
5 200GB 205GB 4999MB logical linux-swap(v1)
6 205GB 225GB 20.0GB logical fat32
7 225GB 230GB 4999MB logical ntfs
There are some spaces from 100gb till 150gb unused,located between partition number 2 and number3, it's wasted.
It is more clear to see the unused space with gparted in graphical format.
I want to create a new partition on it.
(parted) mkpart primary ext4 100g 150g
parted: invalid token: primary
Partition type? [logical]?
(parted) mkpart logical fat32 100g 150g
Error: Unable to satisfy all constraints on the partition.
sudo fdisk -l
Disk /dev/sda: 232.9 GiB, 250059350016 bytes, 488397168 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: 0x3b2662b1
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 97851391 97849344 46.7G 7 HPFS/NTFS/exFAT
/dev/sda2 97851392 195508223 97656832 46.6G 83 Linux
/dev/sda3 292970496 390819839 97849344 46.7G 83 Linux
/dev/sda4 390821886 449411071 58589186 28G 5 Extended
/dev/sda5 390821888 400584703 9762816 4.7G 82 Linux swap / Solaris
/dev/sda6 400586752 439646207 39059456 18.6G b W95 FAT32
/dev/sda7 439648256 449411071 9762816 4.7G 7 HPFS/NTFS/exFAT
How to write the partition command on the disk space?
The debian os is installed sda3,it can't be delete and then to create new one.