On Thursday 20 December 2007 10:50:33 Benjamen R. Meyer wrote:

> I set up a server system a little while ago, and in performing updates
> to portage it ran out of disk space as I didn't quite allow enough space
> on the root partition (3.8 GB).

That's way too much. 256M is enough.

> As a result, I took a partition that I had cleaned up (this was from a
> rebuild of a system that was a different
> distro in the past) and moved over /usr/portage to it. It's a 47 GB
> partition (as reported by df -h) and the system works fine.
>
> I do realize that if the mount command got screwed up, I'd probably have
> issues recovering the system, but that is that system.
>
> I am now thinking of converting my desktop over to Gentoo as well, and
> was wondering whether what I did above on the server was wise or not.

I think it is not. You'll undoubtedly get different answers about this, but 
IMHO it is best (regardless what kind of system) to use small, special purpose 
logical volumes. This way you can add space when needed, use the filesystem 
that fits best for the kind of data you store on this volume and have a certain 
degree of safety against volume corruption.

Here is what I would recommend for a normal linux system:

[hs]da1: /boot, 64M, ext2
[hs]da2: /, 256M, ext3 or xfs
[hs]da3: LVM

Then, create a volume group spawning [hs]da3 with name vg00 (you can choose the 
name freely) and create logical volumes inside:

/dev/vg00/swap: size as needed, swapfs # can be omitted if enough RAM
/dev/vg00/usr: /usr, 2-5G (dep. on number of pkgs), ext3 or xfs
/dev/vg00/var: /var, 512M-1G, ext3 or xfs

For /home, I prefer to have one LV per user, like /dev/vg00/john_doe, 
/dev/vg00/jane_doe and have the kernel automounter mount them on demand (at 
login time).

> I will be using the server as the portage provider for my desktop too.
> Otherwise, what is the recommended space to have available for the
> portage tree in /usr/portage so I can have root as an appropriately
> sized partition?

Here again, I use the kernel automounter to mount three different LVs under 
/gentoo when needed: /dev/vg00/build (5.5G to be able to build OO.org), 
/dev/vg00/distfiles for the source packages and /dev/vg00/overlays for 
overlays, incl. the portage tree.

On the desktop machine, you should be able to mount distfiles and overlays from 
the server via NFS. The build volume I would leave locally on the desktop to 
get faster build times (unless your network connection to your server is faster 
than harddisc access).

HTH...

        Dirk

Reply via email to