[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Best practices for updating systems over extremely slow links



hello.

don't know how many different set ups that you have going on in the boondocks, yet if they are basically all the same you could install a virtual machine(s) at your location that copies what is at your distant locations.

this is from page 108 of the debian handbook(comments added) -
Installing the same selection of packages several times

It can be useful to systematically install the same list of packages on several
computers. This can be done quite easily.

First, retrieve the list of packages installed on the computer which will serve
as the “model” to copy.

dpkg --get-selections > pkg-list

The pkg-list file then contains the list of installed packages. Next, transfer
the pkg-list file onto the computers you want to update and use the following commands:

## Update dpkg’s database of known packages
# avail=‘mktemp‘
# apt-cache dumpavail > ”$avail”
# dpkg --merge-avail ”$avail”
# rm -f ”$avail”
## Update dpkg’s selections
# dpkg --set-selections < pkg-list
## Ask apt-get to install the selected packages
# apt-get dselect-upgrade
The first commands records the list of available packages in the dpkg database,
then dpkg --set-selections restores the selection of packages that you wish to
install, and the apt-get invocation executes the required operations! aptitude
does not have this command.

so with this you could basically mirror your remote system running as a virtual guest.

with this do can do an 'apt-get -d upgrade' (on virtual system)
this will only download your packages and then you can tar.gz them up and rsync that to the remote systems and unpack in /var/cache/apt/archives/ and then 'apt-get upgrade' (on remote system).

if you set up a cron job to 'apt-get update' on the remote systems (before you rsync the tar.gz) then you could just write a script that 'upgrades' on them when the rsync is done.

for the individual package updates you could push those on an as needed basis to upgrade what you needed.

depending on the variety of your remote systems, you could probably get away with having all of the variants installed on one virtual system, and then push the same tar.gz file to all of them and they will only install what is needed from what is in the archive dir.


Reply to: