Linux partitioning

Kaoticfire

New Member
Joined
Apr 3, 2024
Messages
4
Reaction score
1
Credits
33
My apologies if that has already been answered as I did not see anything. My question is this. I have seen posts all over the internet for and against multiple partitions. What is the general consensus to having multiple partitions? Is there really just use cases, or is it recommended to have or not have multiple partitions. I know now a days at the OS install a lot if not most distros create or recommend a seperate home partition and or have a swap. However I am curious if it ultimately is a personal preference.
 


To a certain extent it is a personal choice. Maybe the best way is to list some the advantages of having a separate /home partition. I like it that way because if you ever have to reinstall the system you can keep your /home untouched and you'll keep intact most of your settings, ETC. But I always advise keeping it backed up on computer so just in case things go wrong.
As for a swap partition on most modern systems that have sufficient ram you do not really need one or a swap file will work just as well. only exception to that rule is on a laptop if you plan to have it hibernate you need a swap space.

this quote from It's Foss is good.

Why is swap needed?​

There are several reasons why you would need swap.

  • If your system has RAM less than 1 GB, you must use swap as most applications would exhaust the RAM soon.
  • If your system uses resource heavy applications like video editors, it would be a good idea to use some swap space as your RAM may be exhausted here.
  • If you use hibernation, then you must add swap because the content of the RAM will be written to the swap partition. This also means that the swap size should be at least the size of RAM.
  • Avoid strange events like a program going nuts and eating RAM.
But most Distros today if you allow them to create the partitions will create one big one with a swap file.
Good Luck.
 
Personally I do not use a swap I have 16GBs of RAM and I do not use hibernation, when I an done with my machine I turn it off - I also do not use multiple partitions here is my GParted layout - like @kc1di has stated it is really a personal preference - I do not have multiple OS's or dual boot or anything like it just one OS

2.png
 
Ok, then what about separate partitions like bar and what not. Outside of more control over total disk usage, is there really any advantage to using separate system partitions?
 
Ok, then what about separate partitions like bar and what not. Outside of more control over total disk usage, is there really any advantage to using separate system partitions?
Not Really any advantage.
You can use LVM or BTRFS file systems that will basically add what we used to call partition but are really only files today.
I like to stick to EXT4 it's well tested and I don't need the extras offered by the the other systems.
Which Distro will you be using by the way?
 
My apologies if that has already been answered as I did not see anything. My question is this. I have seen posts all over the internet for and against multiple partitions. What is the general consensus to having multiple partitions? Is there really just use cases, or is it recommended to have or not have multiple partitions. I know now a days at the OS install a lot if not most distros create or recommend a seperate home partition and or have a swap. However I am curious if it ultimately is a personal preference.
The choice of partitioning scheme is individual. I have documents on separate partition so if OS partition needs to be formated, I don't lose anything and I have access to the latest version of the documents and config files. Swap partition or swap file usage in Linux was explained by Ingo Molnar. In short swap is needed and kernel will swap if needed irrelevant of OS configuration. There are more efficient ways of administering swap.
I have one encrypted partition on my laptop for sensitive documents.
Whatever scheme, it is user's convenience and comfort that counts.
 
I run Ubuntu, arch, and kali all on different systems. But I had never really figured why partitioning over single partition. So I always used either a single or home on a separate, with no swap
 
I stopped creating partitions years ago...the Distro installer creates two partitions on the Drive...Boot and the Root partition which has worked just fine for me.
m1212.gif

1712187108738.png


The installer also creates a Swap File of 2GB which is fine because these days you don't need Swap...just add more Ram...I have 16GB of Ram...
1712187460844.png

As you can see no Swap is used and never is.
m1203.gif
 
then what about separate partitions like bar and what not.

G'day and welcome @Kaoticfire

is that "bar" /var ? If not, what?

Having separate partititons for /var /etc /proc /sys and so on is an anachronism no longer required, but still subscribed to by some.

As for my RAM, it is 16 GB, with no swap at all

Code:
free -m
               total        used        free      shared  buff/cache   available
Mem:           15885        3183        3961         478        8740       11889
Swap:              0           0           0

Chris Turner
wizardfromoz
 
The old adage KISS still applies as far as I'm concerened, Keep it as simple as possible and still get the job done.
 
G'day and welcome @Kaoticfire

is that "bar" /var ? If not, what?

Having separate partititons for /var /etc /proc /sys and so on is an anachronism no longer required, but still subscribed to by some.

As for my RAM, it is 16 GB, with no swap at all

Code:
free -m
               total        used        free      shared  buff/cache   available
Mem:           15885        3183        3961         478        8740       11889
Swap:              0           0           0

Chris Turner
wizardfromoz
Chris,
My apologies yes it is /var (stupid auto correct)
 

Staff online


Top