[Nottingham] SSD upgrade
Martin
martin at ml1.co.uk
Mon Feb 10 20:44:49 UTC 2014
On 10/02/14 20:01, Jason Irwin wrote:
> On 04/02/14 17:44, Jason Irwin wrote:
>> I went with a Samsung 840 Pro in the end.
> Now I have this puppy, how the heck do I go about partitioning it?
>
> Scanning around the web there seems to be a lot of conflicting guides on
> what to do, and I can't see how to ensure that GParted aligns everything
> to the erase blocks. Heck, I don't even know what size of erase block
> this thing has and Samsung are rather silent on the matter.
See:
http://nottingham.lug.org.uk/2011/09/howto-hdd-and-ssd-alignment/608
:-P
Actually... NNNNooooooooo! That is far too long a read and out of date
for present day usage...
Better is to look up:
man gdisk
Simply use for example:
gdisk /dev/sdX
The default is for "GPT fdisk attempts to align partitions on
2048-sector (1MiB) boundaries"
I suspect recent SSDs are using 2MiB and 4MiB erase blocks. Hence
instead set for 8MiB or 16MiB alignment "just to be sure" in case you
have something even more recent...
Hence, select "l Change the sector alignment value" in the "x
experts menu" and set for alignment to 32768 sectors.
Having the alignment set too pessimistic can't hurt for the sake of
16MiB out of many GBytes.
Aside: Note your drive will be sized by the manufacturer in non-GiB
plain old decimal GBytes just for Marketing to confuse you...
If you prefer, there is also:
cgdisk - Curses-based GUID partition table (GPT) manipulator
cgdisk /dev/sdX
That also will align to 1MiB boundaries.
In my usual style... I set absolute GiB sector start locations to
guarantee alignment. cgdisk is a bit stupid about partition sizes, so
you'll need to do the maths yourself or deliberately set too small a
partition size each time, set all your partition starts, and then
maximise the size for each partition.
If that description is a little confused, just try it and you'll see
what I mean. Must get round to putting in a bug report!
And... To UEFI-proof and to keep grub happy, include a BIOS partition.
So for example for one of my test systems with a 8192 sectors (4MiB)
alignment on an old SSD:
Number Start (sector) End (sector) Size Code Name
1 8192 16383 4.0 MiB EF02 BIOS boot
2 16384 262143 120.0 MiB 8300 Linux
3 262144 16777215 7.9 GiB 8200 Linux swap
4 16777216 134217727 56.0 GiB 8300 Linux
5 134217728 259491839 59.7 GiB 8300 Linux
6 259491840 293046734 16.0 GiB 8300 Linux
One or two beers and being undisturbed helps also! ;-)
Cheers,
Martin
--
- ------------------ - ----------------------------------------
- Martin Lomas - OpenPGP (GPG/PGP) Public Key: 0xCEE1D3B7
- martin @ ml1 co uk - Import from hkp://subkeys.pgp.net or
- ------------------ - http:// ml1 .co .uk/martin_ml1_co_uk.gpg
More information about the Nottingham
mailing list