[Tfug] my /usr and /var are huge
Bexley Hall
bexley401 at yahoo.com
Tue Apr 3 11:51:32 MST 2007
--- Stephen Hooper <stephen.hooper at gmail.com> wrote:
> On 4/2/07, Charles R. Kiss
> <charles at kissbrothers.com> wrote:
> > I have like three har d har hard drives; do I just
> move the data around
> > and repartition on the same drive as / for
> separate /usr /var partitions
> > (I'll figure out how to do that); or can I just
> copy the data sets to
> > another drive with /usr /var directories and
> sym-link from the /
> > partition (that's on a separate drive)? Do I
> sacrifice speed, energy,
> > error, all of the above?
> > I have no clue. I just know my / partition is
> getting huge.
/ should be kept small and, "ideally", treated as
if it was R/O. Ditto with /usr, /opt, etc. -- any
place where binaries are likely to congregate
(i.e. there should be little *need* for them to
be writable and, thus, "written to" in normal use).
I've run configurations where /etc was a separate
partition just to help keep / "pure" in this regard
(though it didn't win much).
> An easy way to do this would be to take downtime,
> boot the computer
> into single user mode, partition the new drives the
> way you want them
> (i.e. /usr, and /var'), and then tar-copy the
> contents doing something
> like:
>
> cd /newusr
> (cd /usr ; tar cvpf - .) | tar xvpf -
I didn't catch a reference to which OS was being used,
etc. Some OS's have buggy tar's and choke on this
sort of approach (cpio can be a help)
> then add the new "/usr", and "/var" partitions to
> your fstab, and reboot.
>
> If it all seems to work, then boot into single user
> again, make sure
> "/usr", and "/var" are not mounted, and then rm the
> contents of the
> old directories.
>
> You could also look at LVM to make sure this kind of
> thing doesn't
> bite you in the future.
____________________________________________________________________________________
Be a PS3 game guru.
Get your game face on with the latest PS3 news and previews at Yahoo! Games.
http://videogames.yahoo.com/platform?platform=120121
More information about the tfug
mailing list