I am partitioning eMMC using following commands in the script,
parted /dev/mmcblk0 --script mklabel gpt
parted /dev/mmcblk0 --script mkpart primary ext4 32MB 132MB
parted /dev/mmcblk0 --script mkpart primary ext4 233MB 433MB
parted /dev/mmcblk0 --script mkpart primary ext4 433MB 533MB
parted /dev/mmcblk0 --script mkpart primary ext4 533MB 593MB
parted /dev/mmcblk0 --script mkpart primary ext4 593MB 793MB
parted /dev/mmcblk0 --script mkpart primary ext4 793MB 3800MB
parted /dev/mmcblk0 --script align-check min 1
- Is it the correct way to create partition in the script ? Is there any better way ?
-
After creating first partition i am getting following warning
Warning: The resulting partition is not properly aligned for best performance.
Do i need to worry about it ?
I tried parted /dev/mmcblk0 --script align-check min 1
but not sure that's the solution. Any pointers for that?
I am going through this link meanwhile any other suggestions ?
Edit:
Just a quick reference for frostschutz reply,
MiB = Mebibyte = 1024 KiB
KiB = Kibibyte = 1024 Bytes
MB = Megabyte = 1,000 KB
KB = Kilobyte = 1,000 Bytes
Best Answer
It's correct in principle but you might consider reducing it to a single
parted
call.Your alignment issue is probably because you use
MB
instead ofMiB
. You should not need an actualalign-check
command when creating partitions onMiB
boundaries / on a known device.