1 |
Molle Bestefich wrote: |
2 |
> Hi |
3 |
> |
4 |
> Follow-up question to the backup thingy. |
5 |
> |
6 |
> Is there an easy way to share Portage's database between multiple |
7 |
> virtual machines? |
8 |
> |
9 |
> Optimally, I would emerge --sync and the results would land in a |
10 |
> filesystem that I'd share between VMs, so I don't have to do emerge |
11 |
> --sync in each and all of them. The filesystem could perhaps be |
12 |
> readonly to the virtual machines, except for the one doing the --sync |
13 |
> of course. |
14 |
|
15 |
I share /usr/portage across several machines as an nfs mount. 'emerge |
16 |
--sync' is done on only one machine. |
17 |
|
18 |
Until recently, 'emerge --metadata' was still needed on the other |
19 |
machines, but thanks to the metadata_overlay database, this is no longer |
20 |
necessary. And most emerge-related activities are much, much faster. |
21 |
|
22 |
[To use the new database module, with portage-2.1, put |
23 |
|
24 |
in /etc/portage/modules: |
25 |
portdbapi.auxdbmodule = cache.metadata_overlay.database |
26 |
|
27 |
in /etc/make.conf: |
28 |
FEATURE="-metadata-transfer" |
29 |
|
30 |
and remove /var/cache/edb/dep/\${PORTDIR} ] |
31 |
|
32 |
|
33 |
To have distfiles safely shared across the many machines, you need |
34 |
FEATURES="distlocks" and you'll need to relocate (or mount separately) |
35 |
${DISTDIR} if ${PORTDIR} is read-only. |
36 |
|
37 |
|
38 |
Also, I think you're getting into questions that should be on -user. ;) |
39 |
|
40 |
j. |
41 |
-- |
42 |
gentoo-dev@g.o mailing list |