Misaligned partition (3TB seagate advanced format drive)

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
GeirH

Misaligned partition (3TB seagate advanced format drive)

Post by GeirH »

My first post in here, but i've used Linux Mint for a few years now.

I'm running Linux Mint 9 as a server, and i'm trying to add two 3TB seagate sata disks in addition to the ones i've already got installed in my system. These disks are going to be used as storage for large files (movies, tv shows etc.).

What i've done is this:

- Installed the disks in the machine
- Created GPT partition table with GParted
- Created a new ext4 partition with GParted

But when i open Disk Utility (palimpsest) i get a (yellow/orange) warning message on the new drive:

"WARNING: The partition is misaligned by 3072 bytes. This may result in very poor performance. Repartitioning is suggested."

I've also tried to use gdisk to create the partition on one of the disks, and mkfs.ext4 to format it, but no difference from the warning above.

I find the partition as /dev/sde1, and i'm able to mount it from fstab and write to it without any problems. I can't say if the performance is low or anythig (taking 10-12 secs to copy a 650 MB file from another disk).

Is this something i should worry about? I'm not going to use any of the disks as system disks, just data storage for sharing over samba to my htpc.

Thanks in advance.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
jazz.h
Level 4
Level 4
Posts: 363
Joined: Sat Jun 18, 2011 7:13 am

Re: Misaligned partition (3TB seagate advanced format drive)

Post by jazz.h »

Welcome GeirH,
I had the same problem on an extended partition, http://forums.linuxmint.com/viewtopic.php?f=46&t=92678, I tried to solve it with no success, I gave up on this with my conclusion - it's a bug in disk utility.
No problems since (6 months more or less)...
GeirH

Re: Misaligned partition (3TB seagate advanced format drive)

Post by GeirH »

Thanks for clearing that up for me, and for the quick response too. So you're sure the problem is with Disk Utility?

Starting to fill it up now :-)
srs5694
Level 6
Level 6
Posts: 1386
Joined: Mon Feb 27, 2012 1:42 pm

Re: Misaligned partition (3TB seagate advanced format drive)

Post by srs5694 »

There's no way to know if your partitions are misaligned without more information. They're probably OK, but I can't make any promises about that. To be sure, you need to find the start points of the partitions with sector precision. You can do that with gdisk or GNU Parted:

Code: Select all

sudo gdisk -l /dev/sda
sudo parted /dev/sda unit s print
Examine the partition start points. If the numbers are evenly divisible by 8, then you're fine. If the start points are not all evenly divisible by 8, then you've got a problem.

(Note: I'm the author of gdisk, and I've written an article on this topic for IBM developerWorks, including benchmark tests that demonstrate the extent of the problems that can occur from misalignment.)
GeirH

Re: Misaligned partition (3TB seagate advanced format drive)

Post by GeirH »

I've created just one partition on both my 3TB disks, and both parted and gdisk reports a start sector of 34 (on borth disks), which of course isn't diviseable by 8.

But as far as i can see from the article you linked to, the performance on ext4fs isn't suffering too bad, and especially not on large files (no penalty on reading large files, and not much on writing them).

GParted gives an error message when i try to create an ext4fs partition with the "Round to cylinders" box unchecked:
"libparted messages -> Unable to satisfy all constraints on the partition."

As long as there's not any risk of data loss, i think i won't bother too much with this. I probably won't notice the performace drop for my use anyway.

Thanks a bunch for the help so far.
srs5694
Level 6
Level 6
Posts: 1386
Joined: Mon Feb 27, 2012 1:42 pm

Re: Misaligned partition (3TB seagate advanced format drive)

Post by srs5694 »

Ext4fs produces a 25% increase on small-file read times, a 96% increase on file deletion times, an 8% increase on large-file write times, and a 4% increase on small-file write times. Large-file reads were unaffected in my tests. Although this is better than most filesystems in my test, it's not what I'd call good -- the bar charts are a bit deceptive because some other filesystems (mostly ReiserFS) were dramatically worse. The choice of whether to fix the problem is of course yours. Personally, I would, even on an AV server, but perhaps I'm a bit compulsive that way. Unless there's another problem with your setup, you're likely to have read times that are fast enough to not degrade video playback, although deletions and file-copy times might suffer to a noticeable extent. AFAIK, disk wear issues are negligible, but I might be unaware of a longevity issue related to misaligned partitions.

Mint 9 is relatively old (it was released in May of 2010, according to Wikipedia), and clearly the partitioning software it includes is old enough to not include proper alignment code. That would also account for the "unable to satisfy all constraints" error message you received; we've only recently emerged from a transitional period in which a lot of bugs related to the changing partition alignment policies existed in all the major partitioning tools. This is one of the drawbacks of a long-term support distribution like Mint 9 -- unless the developers update packages, you can be left significantly behind the times on some important features. This has clearly happened in this case. Moving forward, if you need to partition new disks with your Mint 9 installation, you should use more recent software and/or manually partition for proper alignment using sector-precise sector values.
AlbertP
Level 16
Level 16
Posts: 6701
Joined: Sun Jan 30, 2011 12:38 pm
Location: Utrecht, The Netherlands

Re: Misaligned partition (3TB seagate advanced format drive)

Post by AlbertP »

You could also use a Mint 12 CD to do the partitioning, and then install Mint 9 on those partitions. Using the partitions should be fine in 9, it's just creating, moving, resizing etc. that won't align properly with old software.
Registered Linux User #528502
Image
Feel free to correct me if I'm trying to write in Spanish, French or German.
GeirH

Re: Misaligned partition (3TB seagate advanced format drive)

Post by GeirH »

I tried to download and install the latest version of GParted (0.12.0) to upgrade from version 0.5.1 which is installed (and apt-get reporting as the latest version), but got into a few problems there. For now the problem is that i need version 1.7.1 or newer of libparted, and getting other error messages compiling this, and also here apt-get reports that the latest version is installed.

But i see there's a live version of GParted on their homepage on sourceforge which i might try. Just need to get a cd/dvd drive installed, since my server doesn't seem to want to boot from a usb stick at the moment.

Thanks for the input so far. I'll figure this out somehow, but the live version seems like the easiest way right now...
srs5694
Level 6
Level 6
Posts: 1386
Joined: Mon Feb 27, 2012 1:42 pm

Re: Misaligned partition (3TB seagate advanced format drive)

Post by srs5694 »

For partitioning, a live CD or USB flash drive should work fine; it's not exactly a task you have to deal with every day. Alternatively, you can do it manually or use GPT fdisk (gdisk, sgdisk, or cgdisk). GPT fdisk isn't based on libparted, so you should be able to install the latest version. I'm not sure if the Debian or Ubuntu version will install on Mint, though, so you might need to build it from source code if you go that route.
600 Series

Re: Misaligned partition (3TB seagate advanced format drive)

Post by 600 Series »

Thank you: srs5694
I had the same issue and reading your article was of great assistance.
I now have properly aligned partitions, and a stronger understanding.
Locked

Return to “Storage”