Gentoo Archives: gentoo-user

From: Walter Dnes <waltdnes@××××××××.org>
To: Gentoo Users List <gentoo-user@l.g.o>
Subject: [gentoo-user] An alternative to http-replicator
Date: Sat, 10 Jun 2006 03:38:43
Message-Id: 20060610033154.GA22420@waltdnes.org
1 We want to be "kinder and gentler" to the Gentoo mirrors. I have 2
2 machines; my main machine and a 1999 450 mhz PIII as "hot backup". I
3 try to keep the backup up to date with apps duplicating the main
4 machine, so that if the main machine dies, I can restore some data from
5 backups and be running in a couple of hours.
6
7 The procedure for "emerge --rsync" using the main machine as server is
8 simple. I'll now present my solution for /usr/portage/distfiles. This
9 obviously works best for machines with a similar set of apps. Run
10 emerge update on the server machine first. It'll get the tarballs it
11 needs, and they'll be sitting in /usr/portage/distfiles, waiting to be
12 served out to other machines in your LAN that need the same tarballs.
13
14 I use the "boa" webserver. It's lighweight, simple to configure, and
15 you can run multiple instances simultaneously. That is the best way to
16 separate privileges for different clients.
17
18 *IMPORTANT* Gentoo's emerge command always looks in the "distfiles"
19 folder below whatever URL it's given for a mirror. E.g. if I specify
20 "http://www.bad.example.com" as the mirror to use, emerge will look in
21 "http://www.bad.example.com/distfiles". The "Alias" declaration in
22 boa.conf handles this. The secondary machine's /etc/make.conf has the
23 line...
24
25 GENTOO_MIRRORS="http://192.168.123.252:1024 ftp://ftp.ndlug.nd.edu/pub/gentoo/ http://mirror.datapipe.net/gentoo"
26
27 so it'll try my main machine (192.168.123.252 on port 1024) first. I
28 invoke the portage server dedicated boa with the command...
29 boa -c /root/.boa/portage/
30 which implies that the config file to use is /root/.boa/portage/boa.conf
31
32 My /root/.boa/portage/boa.conf currently looks like so...
33
34 Port 1024
35 Listen 192.168.123.252
36 User nobody
37 Group nogroup
38 ErrorLog /var/log/boa/portage/error_log
39 AccessLog /var/log/boa/portage/access_log
40 DocumentRoot /usr/portage/distfiles/
41 UseLocaltime
42 DirectoryMaker /usr/lib/boa/boa_indexer
43 KeepAliveMax 1000
44 KeepAliveTimeout 10
45 MimeTypes /etc/boa/mime.types
46 DefaultType text/plain
47 Alias /distfiles /usr/portage/distfiles
48
49 Note that in addition to using a dedicated I/O port, the "portage
50 instance" of boa also has its own log files.
51
52 --
53 Walter Dnes <waltdnes@××××××××.org> In linux /sbin/init is Job #1
54 My musings on technology and security at http://tech_sec.blog.ca
55 --
56 gentoo-user@g.o mailing list

Replies

Subject Author
Re: [gentoo-user] An alternative to http-replicator Anielkis Herrera Gonzalez <aherrerag@×××××××××××××××.cu>
Re: [gentoo-user] An alternative to http-replicator Jeremy Olexa <olexa@××××××.edu>