You are not logged in.

#1 2012-04-19 15:46:44

zwl
Member
From: Tallahassee
Registered: 2012-04-15
Posts: 58

Why separate / and /home in two dfferent partitions?

For my first install of Arch Linux I partitioned the harddrive according to its suggestions.  However, I am now running out of room for applications in the / partition.  I am wondering why I need to separate / at all.  What is the reason for this?  Is it a bad idea to reinstall with only a swap and main partition?  (Regardless, I need to reinstall because I didn't optimize my partitions for my SSD.)

Offline

#2 2012-04-19 15:49:26

Ramses de Norre
Member
From: Leuven - Belgium
Registered: 2007-03-27
Posts: 1,289

Re: Why separate / and /home in two dfferent partitions?

You can easily reinstall the OS without touching your data, you can more easily make backups of the OS and your data using different methods, frequency, ..., you can have the partitions on different drives, ...

Offline

#3 2012-04-19 16:05:07

Awebb
Member
Registered: 2010-05-06
Posts: 6,688

Re: Why separate / and /home in two dfferent partitions?

You don't NEED to do this, it's just good practice. Home might have different mount options than root. It is also easier to fix, should anything kill your root partition and it's easier to backup. But in the end, you should use whatever partitioning works best for you. If you don't have much space anyway and won't keep much data on /home, put them together.

Offline

#4 2012-04-19 16:06:05

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 20,334

Re: Why separate / and /home in two dfferent partitions?

Or you can install a different OS on a different partion and then allow home to be mounted on theat OS without exposing the entire Arch installation.  Note that it is not recommended to use the same home on multiple OSs, but one can mount  it elsewhere on the other OS to provide access. 

A separate home also allows you to copy home to a different size partition and then subsequently use that other partition as home.  That partition need not be on the same disk as /


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#5 2012-04-19 16:17:29

zwl
Member
From: Tallahassee
Registered: 2012-04-15
Posts: 58

Re: Why separate / and /home in two dfferent partitions?

A few quick notes:

Ramses de Norre wrote:

Yyou can have the partitions on different drives, ...

I only have one drive

ewaller wrote:

Or you can install a different OS on a different partion and then allow home to be mounted on theat OS without exposing the entire Arch installation.

I also only have one OS (and only intend to have one OS

The easier to back up is quite compelling.  How do you predict how much space they will need in their / partition?  (And the other partitions for that matter.)

Offline

#6 2012-04-19 16:19:37

GERGE
Member
From: Turkey
Registered: 2008-09-29
Posts: 157
Website

Re: Why separate / and /home in two dfferent partitions?

If you ever want to change the distro you use, you won't have to backup you personal files.

Offline

#7 2012-04-19 16:30:06

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Why separate / and /home in two dfferent partitions?

GERGE wrote:

If you ever want to change the distro you use, you won't have to backup you personal files.

Not backing up personal files doesn't seem like a great idea ...

Offline

#8 2012-04-19 16:56:52

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 4,092
Website

Re: Why separate / and /home in two dfferent partitions?

zwl wrote:

How do you predict how much space they will need in their / partition?  (And the other partitions for that matter.)

I think it's just experience.

My operating system is on a 10 GB partition. I'm sort of "liberal" in what I install (many libraries, toolkits, webserver, and GUI applications) and Arch Linux only uses about half of that space. The only time time I get a little low on space is when I try out a big video game, such as Xonotic, but most other games I play on Linux are very small.

Everything else goes to /home.

So, what do you plan on installing?

Offline

#9 2012-04-19 17:17:40

GERGE
Member
From: Turkey
Registered: 2008-09-29
Posts: 157
Website

Re: Why separate / and /home in two dfferent partitions?

karol wrote:
GERGE wrote:

If you ever want to change the distro you use, you won't have to backup you personal files.

Not backing up personal files doesn't seem like a great idea ...

Not like that. If you have one HD, with every re-install you have to copy or download all files back from CrashPlan or something to your machine if you use one partition.

Offline

#10 2012-04-19 17:24:41

Ramses de Norre
Member
From: Leuven - Belgium
Registered: 2007-03-27
Posts: 1,289

Re: Why separate / and /home in two dfferent partitions?

zwl wrote:

How do you predict how much space they will need in their / partition?  (And the other partitions for that matter.)

I have 15GB for / of which currently 7.6GB is used. You can easily increase the size if necessary though, I originally only gave 10GB to / but found it to be a bit too tight.

Offline

#11 2012-04-20 01:08:17

ngoonee
Forum Fellow
From: Between Thailand and Singapore
Registered: 2009-03-17
Posts: 7,358

Re: Why separate / and /home in two dfferent partitions?

And I have 23.4 GiB on root, 20.2 GiB of that is currently being used smile. Obviously it varies from system to system (I have a 4 GB swap file for hibernating, and texlive by itself is already 1 GB (plus another half a GB in cache).... 2 GB for /var/abs/local/aur....

Like I said, depends on your system and usage.


Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.

Offline

#12 2012-04-20 01:35:55

bergersau
Member
Registered: 2012-01-19
Posts: 52

Re: Why separate / and /home in two dfferent partitions?

I find 10GB plenty for / though I do need to periodically purge my pacman cached tarballs - they can add up over a few months.

Offline

#13 2012-04-20 04:39:56

headkase
Member
Registered: 2011-12-06
Posts: 1,983

Re: Why separate / and /home in two dfferent partitions?

I have:

/boot -> ext2 -> 200MB

swap -> 2GB (2GB RAM in machine too)

/ -> ext4 -> everything else. (which includes /home of course)

I'm on a laptop so it has one hard drive and will never have another hard drive.  Arch is my only OS on the drive.

Edit, forgot to mention: I also have another computer, Win7, which has a network share which is on a USB HD connected to that machine.  I access this share from Arch to back-up anything that is even remotely important.  That USB HD is 2TB and serves as backup for both my Arch laptop and Win7 desktop.

Last edited by headkase (2012-04-20 04:47:07)

Offline

#14 2012-04-20 04:45:54

zwl
Member
From: Tallahassee
Registered: 2012-04-15
Posts: 58

Re: Why separate / and /home in two dfferent partitions?

How do you know how much swap you need for hibernating? 

I think I am leaning towards partitioning mine similar to @headkase's.  I am also on a laptop that won't have another hard drive or another OS.

Offline

#15 2012-04-20 04:55:20

headkase
Member
Registered: 2011-12-06
Posts: 1,983

Re: Why separate / and /home in two dfferent partitions?

I believe your swap file needs to be the same size or larger than your amount of RAM to hibernate.  I may be wrong but I'm pretty sure on that! wink Also, I made an edit to my above post: regarding back-ups and why I need a separate /home less because I have external-to-my-laptop redundancy in case of failure.

Offline

#16 2012-04-20 05:01:36

zwl
Member
From: Tallahassee
Registered: 2012-04-15
Posts: 58

Re: Why separate / and /home in two dfferent partitions?

Is hibernation the same as when laptops "suspend" or "sleep?"

Offline

#17 2012-04-20 05:04:55

headkase
Member
Registered: 2011-12-06
Posts: 1,983

Re: Why separate / and /home in two dfferent partitions?

There is suspend to RAM and suspend to disk.

Suspend to RAM

Suspend to Disk

Basically, suspend to disk totally powers down the machine.  Suspend to RAM powers down everything but the RAM.

Hibernation is suspend to disk.

Last edited by headkase (2012-04-20 05:06:05)

Offline

#18 2012-04-20 05:10:30

zwl
Member
From: Tallahassee
Registered: 2012-04-15
Posts: 58

Re: Why separate / and /home in two dfferent partitions?

Thank you! Now I just need to figure out what Gnome 3 means by suspend.  I suspect it means suspend to RAM.  Do you know which it is and if the suspend to Disk option can be added?

Offline

#19 2012-04-20 05:13:06

headkase
Member
Registered: 2011-12-06
Posts: 1,983

Re: Why separate / and /home in two dfferent partitions?

You're welcome.  For GNOME, sorry, don't know offhand - I'm xfce4.  The: Arch GNOME wiki is the best place to start.  wink

Edit:
A cursory examination of that page doesn't reveal much of anything useful.  I'm sure suspend and hibernate is available in GNOME 3 - I just don't know how you'd go about it..

Last edited by headkase (2012-04-20 05:15:55)

Offline

#20 2012-04-20 07:47:24

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: Why separate / and /home in two dfferent partitions?

I trust you know not to use swap and /var on an SSD.

You don't need a different /home. I haven't had one for at least 4 years now. I like to keep my dot files separate from storage drives. There are some advantages to using a separate home but IMO nothing to worry about too much. Some people pointed out that if a program goes haywire it can fill up your / with junk or the browser cache fills up your /, but I've never had such problems. In the old days you couldn't log in if your / had 0 KB available. Now, EXT4 has about 5% reserved space in case something like this happens (google "reserved ext4 space"), which also helps with fragmentation.


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#21 2012-04-20 15:50:40

zwl
Member
From: Tallahassee
Registered: 2012-04-15
Posts: 58

Re: Why separate / and /home in two dfferent partitions?

DSpider wrote:

I trust you know not to use swap and /var on an SSD.

My laptop only has one drive and it is SSD.  Is their a workaround for this?

Offline

#22 2012-04-20 21:18:11

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: Why separate / and /home in two dfferent partitions?

https://wiki.archlinux.org/index.php/SSD

Make sure you read it properly. There are some good tips in there.


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#23 2012-04-21 03:33:29

zwl
Member
From: Tallahassee
Registered: 2012-04-15
Posts: 58

Re: Why separate / and /home in two dfferent partitions?

Does partition order matter?

For example is there a difference if swap comes before /?

Offline

#24 2012-04-21 07:31:32

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: Why separate / and /home in two dfferent partitions?

On a HDD, yes, because the platters spin faster at the edges. It's basic physics. It's also why it's recommended that you keep your OS (along with any swap/pagefile) installed as close to the beginning of the drive as possible and keep your storage data on the remaining free space. In contrast, CD/DVD's start writing data from the centre because it lowers the risk of CRC errors (due to scratches, fingerprints, etc).

On an SSD, no. It doesn't matter, as there are no moving parts.


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#25 2012-04-22 20:13:51

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,152

Re: Why separate / and /home in two dfferent partitions?

As far as I know, there isn't a problem with having swap on an SSD for hibernation. You can set it to not use it as memory so that the swap is reserved for hibernation. Of course, that involves writing to the disk but presumably you want it to in that case. 'swappability" I think - it probably has something on the SSD page.

I set linux up for somebody with an ssd. I included swap because I've read not having it can cause issues rarely. Instead I just set it so that the system will be maximally reluctant to ever use it unless it is really, really desperate. I figure that will happen so rarely, if ever, it is a non-issue write-wise and I'd rather it had the option if things are that dire. (This is partly calculated based on the user of the machine, though. Since user is not at all technically savvy, I wanted to be maximally conservative.)

I also put /var on the ssd. I don't know what else you are meant to do with it if you've only got a ssd to install to.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

Board footer

Powered by FluxBB