Slackware Partitioning Question
These are questions I always never really got a question for that although simple maybe someone can give me some insight? The Swap partition how big is to big how small is to small? For example if I had 16gigs of ram would I even need a swap? If I had 1gig of ram could I make a 15gig swap?! Is that a waste? Would a 3gig swap with 1gig of ram be bad? How big should
root/Boot/Home be? I see some people have partitions for usrs and so forth why is this needed? I just want someone to explain these things.
some info here about system layouts, not much about swap size, I have 16 gigs of ram and use this to disable swap
echo 0 > /proc/sys/vm/swappiness
found this somewhere: Linux won't use swap at all unless physical memory is completely filled.
RAM has gotten so plentiful that it has turned a lot of the old swap "rules of thumb" (for example, swap = 2 x RAM) on their heads.
If you have 16 GB RAM, you might not "need" a swap partition. However, if this is a machine that you would want to hibernate, you should have a swap partition that is slightly larger than the amount of RAM, as hibernate saves RAM to swap. If you have one GB RAM, two GB swap would likely be plenty (the amount of RAM is small enough that the old rule comes into play).
I have a machine with eight GB RAM and 500 GB HDD. I gave it 9 GB swap because of the "hibernate" feature--I hardly ever use it, but I like to have it available. On another machine that has four GB RAM, I set up four GB swap, and the system seldom uses more that one GB of that.
If "hibernate" is not a feature you would use and you have umpty-ump GB of RAM, you still might want a gig or two of swap, so the swapping does not take place to the active partition.
A separate "home" partition is nice, but not essential, in that you can install a new/updated OS and not touch the data files in /home. This article should tell you more. http://www.howtogeek.com/howto/35676...your-linux-pc/
I have never created a separate "boot" partition on my own, but some distros will do so automatically if you use their automatic partitioning tools.
Hope this helps.
Most compiling projects will require a swap space of at least 4-8 GB but if you have 6+GB of RAM you can actually limit swap to 4 GB to be perfectly safe. If you're running a server system and have high RAM you should at least have 25-50% of your RAM as an emergency stop-gap. If a desktop/workstation you should use at least 4-8 GB depending on how much you'll be compiling and re-compiling. You should never go without a swap though even on modern systems.
I go without swap on a modern system and nothing bad happens. I have 8GB of RAM and I've never run out so far. I used to run out when I had 2GB on my previous system and I compiled something massive with '-j4'. However, with '-j2' or '-j3' it compiled fine.
The reason I hate swap is because the computer slows to crawl when some buggy program decides to hog all the RAM. It takes me much longer to kill the program than it does the OOM killer. Go OOM killer !
The swap part has been covered (I have 8 GB RAM and a 10 GB swap partition, no problems with large, complex compilation or anything else).
I create a bunch of partitions, one for root, one for /home, one for /usr/local, one for /opt, one for /var/lib/mysql, one for /var/lib/pgsql, one for /var/lib/virtual, one /spares.
All of them are 20 GB except /var/lib/virtual (92 GB), /spares (92 GB) and /var/lib/pgsql (173 GB).
That's on this machine, I have other servers where the data base systems are separate drives altogether, but all my systems follow the same partitioning.
Why? Well, the root file system is what gets installed by a new Slackware release (I do a full install rather than upgrading) but the rest of them don't get touched by the installation (you simply don't format a partition when you're adding it to fstab). I copy /etc to /spares so I can get configuration back where needed, I install a lot stuff in /usr/local and in /opt that I don't want to have to back off somewhere and then reinstall. /var/lib/virtual contains at least one virtual machine, Win7, and you can imagine the PITA it is to reinstall Win7 from scratch (I don't use it for much of anything but damned if I want to have to reinstall that abortion again).
One desktop, two data base servers and a lap top get a clean install of Slackware up and running in about 20 minutes.
Works for me.
Hope this helps some.
I wish I'd thought to ask around about partitioning more when I was new to linux. Good insights in the thread. This could be a good sticky in "Slackware - Installation" sub-thread.
@IwannaSlack: it's hard to give you a sound advice not knowing what is your hardware (how many hard disks? what capacity?), what you want to install on it and what are the intended usages of your system(s).
Without that information the best answers you can get are like "this is my layout, that I have chosen for such reasons, and that works here". But what's good for me may not be good for you, because there is no general and definitive answer to your question, in other words no "one size fits all" here.
At the other extreme from @tronayne, for simplicity I sometimes use only one partition for everything, then create a swap file.
You don't need to worry about one of your partitions filling up, but damage from a runaway log, etc will be less confined. Swings and roundabouts.
Also, hibernation is much more difficult to do (although possible, I believe)
Man I love you guys. Okay so here is the run down.
Power Supply: Antec NeoECO 620w
Motherboard: ASUS M5A97 R2.0 AM3+
CPU: AMD FX-8350 Vishera 4.0GHz (4.2GHz Turbo)
Operating System : Windows 8.1 64bit Professional
Graphics Card: XFX Core Edition Radeon HD 7850 1GB
Hard Drive: 4TB =(not including a 120gig ssd)
eventually I am trying to dual boot win 8.1 and slackware?
On a older much worse laptop I have 1gig of ram 120gig hdd and intel core 2. I feel like I need only two partions Swap and hDD but I always see people run at least 3. From a VM slackware seems to run fine from a cd in the past it seemed to install fine but now I can't get it to install via flash drive on to the laptops hardrive.
|All times are GMT -5. The time now is 05:36 PM.|