Friday, April 26, 2024
2
rated 0 times [  2] [ 0]  / answers: 1 / hits: 840  / 2 Years ago, thu, july 7, 2022, 4:23:04

I have done a few Linux installation previously. So far, I think this disk partition scheme works the best for me.




  • / – 10GB

  • swap – 2 x RAM size

  • /home – rest



This is great for me while distro hopping. I can wipe the / partition easily and re-use the /home partition.



So what is your favourite disk partition scheme? Anyone using LVM (Logicial Volume Manager) in Ubuntu? Just want to collect more ideas for reference in future.


More From » partitioning

 Answers
6

There is no "best" partitioning scheme. It really depends on your usage. E.g. if you're running a MySQL database, you might want to create a dedicated /var/lib/mysql partition for it.



10GB swap seems excessive and only useful if you need hibernation. 1xRAM + 2GB = 7G looks enough to me. The 2GB is actually used for swapping. You can lower it even more if you do not need swapping.



I've considered LVM for a regular system, but it's not worth it. Even if you can save space by it (by increasing/ decreasing logical volumes), recovery on mechanical failure/ power loss/ crash may be harder. If you've a big disk which will be unused for the big part, stay away from LVM since you do not need the extra space.



The only reason why you want to use LVM is in conjunction with LUKS (cryptsetup; a way to encrypt a partition). Since a LVM partition can hold more partitions, it'd save you from entering a passphrase for each partition because one LVM partition is encrypted, not the logical partitions in it. Of course, this advantage will only be available if you've a setup like "disk - LUKS - LVM - partition" and not "disk - LVM - LUKS - partition".


[#44180] Saturday, July 9, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
warrdel

Total Points: 356
Total Questions: 103
Total Answers: 118

Location: Bangladesh
Member since Sat, Jan 23, 2021
3 Years ago
;