Re: Cleaning up portage/distfiles var/tmp/portage Peter wrote:
> 1) Is it OK to remove the Distfiles? The only way I would emerge again
> would be to upgrade, and that means I would not need the old bz2 files.
Yes, but usually packages upgrading from -rn to -rn+1 (eg something-r1
to something-r2) use the same source (it is another patch to the same
source). So don't kill BZ2 of currently installed packages.
> 2) Is it OK to remove the /var/tmp/portage directories after a successful
> emerge?
Yes it is.
> 3) What if I decide to archive the Distfiles to another location? Would
> there be any reason I'd bring it back?
I did that trick:
1) copy all distfiles to another directory
2) setup WWW server for that directory (ensuring the distfiles are in
'distfiles' subdirectory, not root directory)
3) tell gentoo to lookup distfiles in local server first.
I did the trick (including local RSYNC) to feed a few machines with
Gentoo at home.
> 4) If it IS necessary to keep them, can I symlink to the archive location
> so I don't clutter up my root partition?
Yes, works for me. 'portage/distfiles' is a symlink at my system.
Well, for my laptop (small HDD) I tried two things:
NFS mount the whole portage tree - this appeared VERY slow, as emerge
browses through it quite a lot.
NFS mount just distfiles - this was quite a good idea, no sources
occupied scarce laptop's HDD. I connected it with DistCC and it worked
perfectly.
General answer to your questions is
"http://www.stacken.kth.se/~foo/gentoo/" with its "DISTCLEAN" package.
It removes all distfiles entries that are no longer referred to by any
installed ebuild. Does quite amazing job.
I modified it to move unreferenced sources to a shadow directory
(instead of nuking'em), and that directory is visible by local WWW
server. So if I wipe file, and it is necessary in a short time (eg,
upgrade - wipe - downgrade sequence), it would be loaded from shadow,
not from net.
--
Pawel Kraszewski |