0

I ran this command on /dev/sda1 when I meant to do something similar to /dev/sda2. /dev/sda1 was mounted at this time.

sudo parted -a opt /dev/sda mkpart primary ext4 0% 100% Warning: You requested a partition from 0.00B to 1000GB (sectors 0..1953525167). The closest location we can manage is 17.4kB to 1048kB (sectors 34..2047). Is this still acceptable to you? Yes/No? yes Warning: The resulting partition is not properly aligned for best performance: 34s % 2048s != 0s Ignore/Cancel? Ignore Information: You may need to update /etc/fstab. 

The output of print is:

(parted) print Model: ATA ST1000LM035-1RK1 (scsi) Disk /dev/sda: 1000GB Sector size (logical/physical): 512B/4096B Partition Table: gpt Disk Flags: Number Start End Size File system Name Flags 6 17.4kB 1049kB 1031kB primary 1 1049kB 300MB 299MB fat32 boot, esp 2 300MB 4347MB 4048MB linux-swap(v1) swap 4 4347MB 124GB 120GB ext4 3 124GB 724GB 600GB ext4 5 724GB 1000GB 276GB ext4 

The output of fdisk -l /dev/sda is:

Disk model: ST1000LM035-1RK1 Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes Disklabel type: gpt Disk identifier: 86AB55F1-52A1-4F8C-ACE9-1A7B4C4E9082 Device Start End Sectors Size Type /dev/sda1 2048 585727 583680 285M EFI System /dev/sda2 585728 8491007 7905280 3.8G Linux swap /dev/sda3 242864128 1414739967 1171875840 558.8G Linux filesystem /dev/sda4 8491008 242864127 234373120 111.8G Linux filesystem /dev/sda5 1414739968 1953523711 538783744 256.9G Linux filesystem /dev/sda6 34 2047 2014 1007K Linux filesystem Partition 6 does not start on physical sector boundary. Partition table entries are not in disk order. 

This is the drive that contains my OS and everything. What do I do so that my reboot doesn't fail. Too afraid to turn off the machine right now.

5
  • Why do you think your reboot might fail? Commented Aug 7, 2024 at 14:29
  • 1
    Before rebooting make sure you backups are current. It looks like you created sda6 which is normally not allocated. Commented Aug 7, 2024 at 14:50
  • 1
    This partition shouldn't cause any harm, as long as existing partitions were untouched. What's the purpose of this partition? Are you trying to squeeze in a bios_grub partition? Something else? Consider giving your partitions proper names (or, no name at all if you don't need any). primary is a msdos partition concept not meaningful for GPT partition. If you didn't want this partition you can just delete it... just don't delete the wrong one Commented Aug 7, 2024 at 14:57
  • @ChrisDavies I have my sda6 partition infront of the boot partition according to fdisk output. Commented Aug 7, 2024 at 17:01
  • @frostschutz the partition was created by mistake. After I complete the backup, I will delete this as you suggested and try to reboot. Commented Aug 7, 2024 at 17:04

1 Answer 1

0

I wouldn't expect the boot to fail even though you've squeezed this last position in before the boot partition.

The boot partition, numbered one in your list and flagged boot, is the one that should be chosen at boot time:

Number Start End Size File system Name Flags 6 17.4kB 1049kB 1031kB primary 1 1049kB 300MB 299MB fat32 boot, esp 

If in doubt, just delete it (carefully!).

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.