1 |
Anthony G. Basile posted on Thu, 18 Jan 2018 06:46:53 -0500 as excerpted: |
2 |
|
3 |
> I'm trying to design an update system for many identical Gentoo systems. |
4 |
> Using a binhost is obvious, but there are still problems with this |
5 |
> approach. |
6 |
> |
7 |
> Unless there's some magic I don't know about (and this is why I'm |
8 |
> sending this email) each machine still needs to have the portage tree |
9 |
> installed locally (1.5 GB) or somehow mounted by a network filesystem |
10 |
> (which is not practical if the machines are not on a local network). |
11 |
> Furthermore, each machine would have to run emerge locally to do the |
12 |
> calculation of what packages need updating. |
13 |
> |
14 |
> This procedure is redundant because each machine is housing the same |
15 |
> data and doing the same dependence-tree calculation. |
16 |
|
17 |
I had a gen-1.5 32-bit netbook for a number of years, that I updated |
18 |
using rsync from a 32-bit chroot on my main machine, no portage tree on |
19 |
the target netbook, tho I didn't worry about separating out build deps |
20 |
from run deps. |
21 |
|
22 |
That was a single machine config, but it should be even easier if you're |
23 |
running nearly identical machines and thus don't need the separate chroot |
24 |
build image. |
25 |
|
26 |
If you have temporary networking you can rsync directly machine to |
27 |
machine, as I did after I was fully setup, but at first I was sneaker- |
28 |
netting it, rsyncing to a thumb drive from the build machine, that I |
29 |
would then plug into the target and rsync thumb drive to target. |
30 |
|
31 |
The thumb drive was bootable, and I used it to do the first gentoo boots |
32 |
on the target as well, testing my config and updating as necessary as I |
33 |
went. When I got everything I initially wanted booting from the thumb |
34 |
drive, I booted the thumb drive, wiped the initial Pingus Linux on the |
35 |
netbook and setup the partitioning, etc, then rsynced selected bits into |
36 |
the appropriate place on the target. |
37 |
|
38 |
For multiple nearly identical machines you can exclude the non-identical |
39 |
bits from the primary rsync image, keeping the specific bits in |
40 |
individual images synced on top of the primary. Of course you can sync |
41 |
in reverse as well to keep the non-identical bits updated, giving you a |
42 |
nice backup of each one as well. =:^) |
43 |
|
44 |
Alternatives would include simply creating the thumb drive once and then |
45 |
cloning it enough times to give every machine a bootable thumb drive copy |
46 |
(using symlinking and/or mounts to handle the non-identical stuff, so |
47 |
simply toggling a symlink lets you switch machine layouts), or if the |
48 |
machines have enough memory, setting up a single thumb drive to boot and |
49 |
put everything in a tmpfs for the machine to run from, so you can use the |
50 |
same thumb drive to boot them all, effectively the sneakernet version of |
51 |
net-boot. |
52 |
|
53 |
-- |
54 |
Duncan - List replies preferred. No HTML msgs. |
55 |
"Every nonfree program has a lord, a master -- |
56 |
and if you use the program, he is your master." Richard Stallman |