Farm synchronization
Roland Smith
rsmith at xs4all.nl
Sun May 2 15:18:12 UTC 2010
On Sun, May 02, 2010 at 06:17:34PM +0400, Oleg Lutchenko wrote:
> Hello!
>
> Is there any regular way to synchronize installed packages in the farm of
> FreeBSD servers quickly.
Forget packages. Here is wat I do to keep the ports on a couple of machines in
sync.
- Ports are built and installed on a single powerfull workstation, the build machine.
- After updating the build machine (using portsnap and portmaster), the
/usr/local and /var/db/pkg directories from that machine are distributed to
the dependent machines using rsync(1).
- You may need to exclude /usr/local/etc from rsync, or use a script to change files in
that directory afterwards to account for different hostnames and or IP
addresses! I tend to keep config files for every machine in a git
repository on my workstation, merge any chances from the updates and roll
them out to the dependent machines.
- Note that if you use ports that install kernel modules, you'll need to sync
/boot/modules as well!
- On the dependent machines, the /usr/ports directory is removed to save space.
This solution has made my life a lot easier.
You'll have tha same ports installed on all machines. This can be viewed as
making life easier or as a security risk, depending on how you look at it. :-)
But if your thoughts are leaning in the second direction, you can always use a
script to pkg_delete the ports you don't need on specific machines.
Roland
--
R.F.Smith http://www.xs4all.nl/~rsmith/
[plain text _non-HTML_ PGP/GnuPG encrypted/signed email much appreciated]
pgp: 1A2B 477F 9970 BA3C 2914 B7CE 1277 EFB0 C321 A725 (KeyID: C321A725)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20100502/2f9c1a53/attachment.pgp
More information about the freebsd-questions
mailing list