Gentoo Archives: gentoo-user

From: Rich Freeman <rich0@g.o>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] where is /usr/portage?
Date: Mon, 11 Nov 2019 12:03:01
Message-Id: CAGfcS_nZ-+FWAENgD3cOte9Wb3J708TLj_833Yg3VyN9GK8GFQ@mail.gmail.com
In Reply to: Re: [gentoo-user] where is /usr/portage? by "Mickaël Bucas"
1 On Mon, Nov 11, 2019 at 5:28 AM Mickaël Bucas <mbucas@×××××.com> wrote:
2 >
3 > My two systems are currently using the old locations.
4 > Is there a documentation about the way to migrate to the new locations
5 > without breaking things ?
6 > The profile links comes to mind but other things are probably necessary !
7 >
8 > Has anyone already done the migration ?
9 > In this case do you have advices or warnings about it ?
10
11 Moving both paths around have been trivial for a very long time. Both
12 are completely disposable when you think about it so there isn't much
13 you can do wrong.
14
15 Just set DISTDIR and PORTDIR anywhere you want. You can optionally
16 move the existing files to those locations, but if you don't portage
17 will just re-create everything on the next emerge --sync and re-fetch
18 distfiles as needed.
19
20 If you're ever concerned that something bad has happened to either
21 directory you can always just wipe it out and let portage repopulate
22 it.
23
24 I personally keep both in /var/cache and am not a fan of the non-LSB
25 /var/db in general, as I think the repo basically is a cache.
26 However, this was not the majority view. In any case it is just a
27 default so it really isn't a big deal - any user can put both of these
28 directories anywhere they prefer. Ditto for binary packages, logs,
29 etc.
30
31 The only thing you'd need to be careful about migrating is the
32 installed package metadata, as that can't be easily regenerated.
33
34 I also keep a /usr/portage symlink because I must be getting old. :)
35 Some tools also have that path hard-coded.
36
37 The one thing I do strongly recommend is not nesting DISTDIR inside
38 PORTDIR. That really wasn't a great design from day 1 and I don't
39 think anybody disagreed with separating them. I'm not sure how much I
40 like $PORTDIR/metadata being where it is either, but I can at least
41 see the argument of keeping syncs of it and PORTDIR atomic and that is
42 an easy way to accomplish this.
43
44 --
45 Rich

Replies

Subject Author
Re: [gentoo-user] where is /usr/portage? Mick <michaelkintzios@×××××.com>