Hacker News new | ask | show | jobs
by peller 3253 days ago
Here's how I set mine up:

512MB to 1GB: /boot (ext4)

25GB to 50GB: / (root1, whatever filesystem you want)

25GB to 50GB: / (root2, whatever filesystem you want)

The rest, minus 20GBs: /home (whatever filesystem you want)

Having a separate /boot allows for running experimental file systems on your / partitions without needing to worry about GRUB not being able to boot them.

The two / partitions makes upgrading way easier. I've never had good experiences with distro's built-in upgrade mechanisms, so I always do clean installs, alternating between which root partition I install to. This means you've always got a working system as backup if the install fails for whatever reason. It also also makes it much easier to try out new distros (or BSDs, whatever), if you're into that.

Finally, a note about why I always leave 20-ish GBs free (as in unpartitioned; not just free space within a partition). This has to do with how SSDs do wear leveling. Consumer SSDs typically come about 7% overprovisioned, usually, this is the difference in size between measuring GBs as 1024MBs vs 1000MBs (the actual flash capacity on the drive is with the 1024MB measurement, but the marketed size you're buying is with the 1000MB measure, to remain in-line with how HDDs are sold). In short, the SSD controller uses this "scratch space" to perform its wear leveling, as well as keep performance up. The bigger the scratch space, the better the controller will perform (this is why enterprise SSDs typically are closer to 15% or 20% overprovisioned).

So, by leaving that extra 20GBs or so unpartitioned, you're simultaneously increasing the life and "steady-state" performance of your drive. The lost space is a small price to pay for peace of mind IMO. If it interests you, for the nitty-gritty details of why this is so, Anandtech has a great (albeit long) write up: http://www.anandtech.com/show/2738

EDIT: It used to be that you also needed to worry about partition alignment for optimal performance, but as long as you're using a modern distro's tools to do your partitioning, they now take care of getting the alignment right for you.

1 comments

Hi Peller,

Thanks for such detailed explanation much appreciated.

Cheers