[Infrastructures] how to build an internal (local) filestructure?

David Magda David Magda <dmagda+infra@ee.ryerson.ca>
Thu, 31 Mar 2005 21:41:44 -0500


On Wed, Mar 30, 2005 at 10:22:09PM -0800, Steve Traugott wrote:

> and while GNU 'stow' seems to do a good job at helping to manage
> the link farms (it kinda inherited the job from 'depot'), and while
> I've seen other very large sites using link farms and @sys to good

And program that does this is pkglink. It can even allow you to have
multiple versions installed, but only one being 'live' in
/usr/lcoal/bin. If someone wants a different version they can adjust
their $PATH to have that version.

> in the last 10 years, and I've seen way too many orgs waste way too
> much time reverse-engineering and rehacking the installation code
> for applications and libraries in order to make them fit into their
> tree structure.  These tree structures normally prevent you from
> using vanilla .deb, .rpm, .pkg, 'make install', and other
> vendor-supplied installation code; you instead have to
> painstakingly spend hours or even days repackaging something that
> you otherwise could have deployed to your users in a few minutes.

The vendor supplied code is handy, but sometimes the compiled-in
defaults are not want you want. With Deb and RPMs you can pick up the
soruce versions and tinker of course.

One option is a system like NetBSD's pkgsrc (there's also OpenPKG). A
multi-platform compile-from-source system. There is even some
experimental support for having multiple versions of a program
installed via "pkgviews":

www.netbsd.org/Documentation/software/pkgviews.pdf
http://www.schemamania.org/projects/pkgviews/book1.htm

> In other words, if it takes you 5 minutes to install something
> manually on one machine, and it takes an hour of your time to do it
> for all of your machines, then you're probably doing something
> wrong.  (And no, this doesn't include testing time -- this is
> install time only; the amount of time it takes to drop it in place
> and say 'make install', or to drop it on your gold server, add it
> to the Makefile, and futz around with CVS.)

One option now available is radmind. You have a a host machine, add
some files to it (in whatever way you want). Create a new
'transaction log' (the file data and meta-data (permissions,
checksums, etc.)) of the machine, which would simply be list of the
new files. (All the old files would already be in previously created
transaction logs.) The transaction log would then be uploaded to a
central server (the file contents are also uploaded).

Each host has a file containing the transaction logs which apply to
it: so a web server would include the transaction log for Apache, but
the mail server wouldn't have that transaction log.

When you want a host to have some software as another host you edit
its configuration file to have that transaction log and run the
radmind client software on the host in question. Or you can have the
client software in a cron job so that any differences are mailed to
you right away (think Tripwire).

Radmind works on any OS that has POSIX file semantics (Unix, OS X).

I've played around with it a bit, but haven't had an opportunity for
large-scale deployment yet. Many people swear by it though (as
opposed to swearing at it).

http://rsug.itd.umich.edu/software/radmind/

-- 
David Magda <dmagda at ee.ryerson.ca>, http://www.magda.ca/
Because the innovator has for enemies all those who have done well under
the old conditions, and lukewarm defenders in those who may do well 
under the new. -- Niccolo Machiavelli, _The Prince_, Chapter VI