multiple ports trees

Greg 'groggy' Lehey grog at
Tue Nov 14 23:24:58 UTC 2006

On Thursday,  9 November 2006 at  8:46:00 -0600, Christopher M. Hobbs wrote:
> Hello, list!
> I've got about six production servers and a couple of workstations
> running FreeBSD 6.1-STABLE and 6.2-PRERELEASE.  Some of these machines
> are sitting in DMZ, the others are internal.  Currently, each of them
> has their own ports tree.
> How terrible of an idea would it be to take one of the production
> servers that isn't really doing a whole lot of work, and make it's
> /usr/ports available over NFS to the other machines?  Am I headed in a
> bad direction here?

This is what I do.  It's not completely without its problems, though:

- Some programs, notably GNU autotools, get upset if you run across
  NFS.  I've worked around this problem by copying the tree where
  necessary; it's not as bad as it seems.
- The ports collection stores build information in the work
  directory.  For example:

    $ ls -lart work3
    -rw-r--r--   1 root  wheel     0 Nov 14 13:29 .patch_done.mythtv._usr_local
    -rw-r--r--   1 root  wheel     0 Nov 14 13:29 .extract_done.mythtv._usr_local
    -rw-r--r--   1 root  wheel     0 Nov 14 13:44 .configure_done.mythtv._usr_local
    -rw-r--r--   1 root  wheel     0 Nov 14 15:56 .build_done.mythtv._usr_local
    drwxr-xr-x   3 root  wheel   512 Nov 14 15:56 .
    drwxr-xr-x   7 grog  lemis   512 Nov 14 17:14 ..
    drwxr-xr-x  13 root  wheel  1024 Nov 14 21:56 mythtv-0.20

  If you build a package on one system, and then try on another, the
  Ports Collection will find these files and assume that there is
  nothing to do.  You need to do a 'make clean' first to get it to do
  the process again, including dependency checks, on the new machine.

> Also, what about user accounts between machines?

With NFS you typically have the same user ID on all related machines.

> I got to thinking that because some of the servers have the same
> user accounts, would it be possible to share a password file or home
> directories?

Yes, again with some caveats.  The biggest ones are configuration
files in the home directory that contain references to the system
you're working on.  My biggest problem is the .emacs file: it refers
to packages that I have installed on some systems only.

> Should I build another box strictly for this purpose?

I get by quite happily with a separate tree on one of my existing

When replying to this message, please copy the original recipients.
If you don't, I may ignore the reply or reply to the original recipients.
For more information, see
See complete headers for address and phone numbers.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url :

More information about the freebsd-questions mailing list