Unix Technical Forum

/var and /usr

This is a discussion on /var and /usr within the Linux Operating System forums, part of the Unix Operating Systems category; --> Why is it said that /var should reside on a separate partition from / usr ?...


Go Back   Unix Technical Forum > Unix Operating Systems > Linux Operating System

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 10-15-2008, 08:09 AM
annalissa
 
Posts: n/a
Default /var and /usr

Why is it said that /var should reside on a separate partition from /
usr ?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 10-15-2008, 08:09 AM
=?ISO-8859-1?Q?Fran=E7ois_Patte?=
 
Posts: n/a
Default Re: /var and /usr

Le 14.10.2008 08:31, annalissa a écrit :
> Why is it said that /var should reside on a separate partition from /
> usr ?


For instance: /var is the place where logs are written, suppose some
process becomes mad and fill the partition with logs....

--
François Patte
Université Paris Descartes
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 10-15-2008, 08:09 AM
Grant
 
Posts: n/a
Default Re: /var and /usr

On Tue, 14 Oct 2008 08:50:06 +0200, François Patte <francois.patte@mi.parisdescartes.fr> wrote:

>Le 14.10.2008 08:31, annalissa a écrit :
>> Why is it said that /var should reside on a separate partition from /
>> usr ?

>
>For instance: /var is the place where logs are written, suppose some
>process becomes mad and fill the partition with logs....


And /usr may be mounted read-only.

Grant.
--
http://bugsplatter.id.au/
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 10-15-2008, 08:09 AM
The Natural Philosopher
 
Posts: n/a
Default Re: /var and /usr

François Patte wrote:
> Le 14.10.2008 08:31, annalissa a écrit :
>> Why is it said that /var should reside on a separate partition from /
>> usr ?

>
> For instance: /var is the place where logs are written, suppose some
> process becomes mad and fill the partition with logs....
>

Yes. /var is for /variable/ data. Logs and often databases live there.

So it can grow and possibly exceed limits: having it separate from the
parts that are necessary for recovery from such a state, means you CAN
recover..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 10-15-2008, 08:09 AM
Mark Hobley
 
Posts: n/a
Default Re: /var and /usr

Grant <g_r_a_n_t_@dodo.com.au> wrote:

> And /usr may be mounted read-only.


And /var may be mounted noexec.

Mark.

--
Mark Hobley,
393 Quinton Road West,
Quinton, BIRMINGHAM.
B32 1QE.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 10-15-2008, 08:09 AM
Andrew Halliwell
 
Posts: n/a
Default Re: /var and /usr

annalissa <aarklon@gmail.com> wrote:
> Why is it said that /var should reside on a separate partition from /
> usr ?


Because the root "/" filesystem should never be allowed to fill up.
If it does, all kinds of nastiness can occur.

And var is one of the partitions on which programs dump their data,
especially e-mail and news, web proxies, log files, etc.

It's a safeguard.
--
| spike1@freenet.co.uk | "I'm alive!!! I can touch! I can taste! |
| Andrew Halliwell BSc | I can SMELL!!! KRYTEN!!! Unpack Rachel and |
| in | get out the puncture repair kit!" |
| Computer Science | Arnold Judas Rimmer- Red Dwarf |
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 10-15-2008, 08:09 AM
Unruh
 
Posts: n/a
Default Re: /var and /usr

annalissa <aarklon@gmail.com> writes:

>Why is it said that /var should reside on a separate partition from /
>usr ?


Many things are said. Not all are sensible.
Anyway, /var/ is written to. /usr is in general not. So /var can fill up.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 10-15-2008, 08:09 AM
Unruh
 
Posts: n/a
Default Re: /var and /usr

=?ISO-8859-1?Q?Fran=E7ois_Patte?= <francois.patte@mi.parisdescartes.fr> writes:

>Le 14.10.2008 08:31, annalissa a écrit :
>> Why is it said that /var should reside on a separate partition from /
>> usr ?


>For instance: /var is the place where logs are written, suppose some
>process becomes mad and fill the partition with logs....


So what? /usr is not written to, and you can read from a full partition.
And /var is far more likely to fill up if it is on a separate partition
(that spare space on /usr is not available to it).



>--
>François Patte
>Université Paris Descartes

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9 (permalink)  
Old 10-15-2008, 08:09 AM
Nico Kadel-Garcia
 
Posts: n/a
Default Re: /var and /usr

François Patte wrote:
> Le 14.10.2008 08:31, annalissa a écrit :
>> Why is it said that /var should reside on a separate partition from /
>> usr ?

>
> For instance: /var is the place where logs are written, suppose some
> process becomes mad and fill the partition with logs....
>


And /var/spool/mail, /var/spool/news, /var/spool/mqueue and /var/tmp/. Any of
those may be overflowed quite badly.

The separation of /var also goes back to the days of much smaller disks, when
a modest mail spool would be wise to put on a separate disk or partition.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #10 (permalink)  
Old 10-15-2008, 08:09 AM
Keith Keller
 
Posts: n/a
Default Re: /var and /usr

On 2008-10-14, Unruh <unruh-spam@physics.ubc.ca> wrote:
>=?ISO-8859-1?Q?Fran=E7ois_Patte?= <francois.patte@mi.parisdescartes.fr> writes:
>
>>For instance: /var is the place where logs are written, suppose some
>>process becomes mad and fill the partition with logs....

>
> So what? /usr is not written to, and you can read from a full partition.
> And /var is far more likely to fill up if it is on a separate partition
> (that spare space on /usr is not available to it).


That's just the reason to separate /var from the rest of the filesystem.
One reason to separate /usr from the rest of the filesystem is to make
upgrades easier; you can mke2fs the /usr partition to wipe all vestiges
of old binaries clean and start fresh. (Grant already mentioned another
reason, the ability to mount /usr read-only.)

--keith


--
kkeller-usenet@wombat.san-francisco.ca.us
(try just my userid to email me)
AOLSFAQ=http://www.therockgarden.ca/aolsfaq.txt
see X- headers for PGP signature information

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 11:10 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com