I got a SSD new harddrive and successfully moved my root partition to it. I am using LVM. It is booting fast, and all the performance is much better than with classic hdd. But I am not sure about the partition alignment.

There is another thread here on askubuntu helping to determine, if the partitions are aligned properly using parted. Issuing the commands I get following results:

sudo parted /dev/sda (my ssd hdd)
Number  Start   End     Size    Type     File system  Flags
 1      32,3kB  502MB   502MB   primary  ext4         boot
 2      502MB   54,5GB  54,0GB  primary               lvm

align-check opt
partition 1 not aligned
partition 2 not aligned

however when issuing commands

sudo parted /dev/ssd/root_ssd (my root logical volume)
partition 1 aligned

The "ssd" volume group is the one I created for my SSD harddrive only, so it exists directly above /dev/sda.

I am confused about the "not aligned" output from /dev/sda, because I guess it "should" be aligned in order to work properly, because it is a physical drive where the LVM is on. But on the other hand, the logical volume itself reports "aligned".

Which of those two informations is more correct? If /dev/sda is "not aligned", can I somehow get it aligned without reinstall? Am I missing something? Thanks alot!


Ok I solved it. Using ubuntu installation usb-stick and gparted I moved/resized the boot and root partition until I got them properly aligned. I checked afterwards with the align-check opt command mentioned in my question. Now everything on the SSD drive seems to be alright.

Note: Moving boot partition requires grub reinstall.

Just to mention. The bad alignment probably came from partitioning using Ubuntu's "disk utility". It could be that I've messed something up, but still possible that compared to gparted the disk utility doesn't care much about proper alignment. So my suggestion is to use parted/gparted.

I am not sure if it was needed, but "aligned" is much nicer than "not aligned" :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.