This chapter has some example configuration files for repositories, and a detailed explanation of the features available.
To provide a full example of a complex registration file the GCC application was chosen. Note that there are many fields in addition to the one manually entered with the "register" utility - these are internal to STORE, and updated automatically.
Full name . ... ... : GNU C kompilator Primary Version ... : 2.5.8 Release Levels ... : 2.4.5/dated 2.5.8/release Program Type .. ... : PL - Programming languages License Type .. ... : GPL - General Public License Signature . ... ... : AHJ Short Description . : C, C++ and ObjC compiler Manual Pages .. ... : 3 files - 138 KB Other Documentation : 1 files - 1716 KB Emacs Info ... ... : 30 files - 1194 KB Online Help ... ... : none Examples .. ... ... : none Init Files ... ... : none Importance ... ... : 9 Source Code ... ... : 795-files 23580-kb Source ... ... ... : prep.ai.mit.edu Nightly Command ... : Not Links . ... ... : Master pathname ... : /store/store/ludvig/gcc Master repository .. ... : ludvig Path to slave . ... : ludvig Versions .. ... ... : 2.4.5 2.5.8 Locks . ... ... ... : Compile Info .. ... : Dependencies .. ... : Begin(Versionlines) : 2.4.5 / alpha/m88k/pmax/rs6aix32/sgi3i4/sparc : 2.5.8 / alpha/linux/m88k/pmax/rs6aix32/sgi3i4/sgi4i5/... End(Versionlines) Begin(MasterVlines) : 2.4.5 / alpha/m88k/pmax/rs6aix32/sgi3i4/sparc : 2.5.8 / alpha/linux/m88k/pmax/rs6aix32/sgi3i4/sgi4i5/... End(MasterVlines) Begin(Description) : The Free Software Foundation's GNU C compiler is regarded as the best : general C-compiler around. It produces code for many different : processors and all major Unix platforms. The C++ part is more buggy : and has many known problems. End(Description) Begin(Log) : getlogin=arnej, uid=store, Sun Nov 7 02:42:08 MET 1993 : Name mangling has changed again, so people using C++ libraries : compiled with 2.4 must use 2.4.5. End(Log)
As seen in the examples for the register utility, these fields are entered by the installer:
noupdate
, which
means slave repositories should not update from the master automatically. Also
note that you cannot enter this field with register
, but must
manually edit the configuration file. This is a deliberate restriction.
Some of the computed information is only updated when you run
register
- the fields tallying different types of files:
Manual Pages,
Other Documentation,
Emacs Info,
Source Code,
Examples,
and Init Files.
The remaining fields are updated each time you run cmaster
.
The main STORE configuration file is the administrative area's `etc/config' file. There will be one such configuration file for each administrative domain.
Blank lines are ignored. Lines may be continued using backslash-newline. Keywords must be at start of lines.
Keywords:
host=<host>
(must match the value
of `uname -n`
) and archs=<arch list>
declaring
architectures to slave down.
host=<host> arch=<arch> domain=<domain>
attributes, where the architecture is the most specific
name of the host's architecture, and the domain is the
most-specific mail or organization domain the host belongs to.
Also common is the unwantedfile=<file>
to exclude applications
from consideration.
shadow
and postinst
. Like,
compile <arch> on=<host>
.
report
to
include in the report.out file.
If in doubt, consult the source (`/store/etc/internal/conffile.pl').
The configuration file is parsed line-by-line, with backslash-newline deleted first. Keywords are only recognized at start of lines, and anything else is ignored. There is no comment possibility. Attribute=value pairs are whitespace-separated, while lists are comma-separated.
The top
keyword and the logdir
attribute are part of a
scheme to allow a repository-like system using different names as a separate
universe, but using the same scripts. It is not documented at all, and
you should not use it. It is only mentioned here for completeness.
Host specifications (with on=<host>
, from=<host>
or host=<host>
)
should preferrably match exactly the value returned by the shell
command hostname
, and we recommend that you use the full
name. However, only the first component will
be compared, because we have found that various OS'es have real
problems getting this consistently right.
compile <arch> on=<host> [on=<host> ...]
run <what> on=<host> pass=<number> [ from=<host> via=<method> ]
internal <repositoryname> [<repositoryname> ...]
external <repositoryname> [<repositoryname> ...]
top <dir> <dir>
report <arch> <archs> [ <arch> ... ]
store <repositoryname> host=<host> archs=<arch list> \ [ dir=<dir> ] \ [ logdir=<dir> ] \ [ domains=<domain list> ] \ [ levels=<level list> ] \ [ autoadd=<repository list> ] \ [ unwantedfile=<file> ]
linktree <linktreename> host=<host> arch=<arch> domain=<domain> \ [ level=<level> ] \ [ dir=<dir> ] \ [ logdir=<dir> ] \ [ unwantedfile=<file> ]
Here is the simplest configuration file in actual use at our site today, for the standalone server ludvig.solan.unit.no (our primary repository server). It has two disks with repositories, ludvig and ludvig2, for a total of 4GB. It has mostly masters for core application like perl, emacs, X11, etc.
internal ludvig ludvig2 external khym ild nova vier lastebil store ludvig host=ludvig archs=sun4os4 store ludvig2 host=ludvig archs=sun4os4 linktree ludvig host=ludvig \ arch=sun4os412 domain=solan.unit.no \ unwantedfile=/store/store/Adm/etc/uwfile.ludvig compile sun4os4 on=ludvig report sun4os4 none allarchs
Here is the most complex configuration file in actual use at our site today, for the administrative domain at pvv.unit.no. PVV is the most heterogenous site, having just two Sparc/SunOS machines, one Sparc/Solaris machine, one HP-700, one IBM workstation, one DECstation running DecOSF, a Dolphin m88k server, and a PC running Linux. Each machine has its own repository and its own linktree. The main repository server (nova) has a 2GB repository disk.
internal nova dekk bigblue bob datter flipper supernova external khym ild vier ludvig ludvig2 lastebil \ flory hani smola grip mari1 kari iptibm3 \ petra1 taiyang storlind store nova host=nova archs=sun4os4,rs6aix32,m88k,hp700ux9,linux,sun4os5 \ autoadd=khym,ild,ludvig,ludvig2,vier,lastebil \ unwantedfile=/store/store/Adm/uw.pvv store dekk host=dekk archs=dsosf1 store bigblue host=bigblue archs=rs6aix32 store bob host=bob archs=hp700ux9 store datter host=datter archs=sun4os5 store flipper host=flipper.pvv.unit.no archs=m88k store supernova host=supernova archs=sun4os4 linktree nova host=nova level=newer arch=sun4os413 domain=pvv.unit.no \ unwantedfile=/store/store/Adm/uw.pvv level=newer linktree supernova \ host=supernova \ arch=sun4os41B \ domain=pvv.unit.no \ unwantedfile=/store/store/Adm/uw.pvv \ level=newer linktree bigblue host=bigblue level=newer arch=rs6aix32 domain=pvv.unit.no \ unwantedfile=/store/store/Adm/uw.pvv linktree bob host=bob level=newer arch=hp700ux9 domain=pvv.unit.no \ unwantedfile=/store/store/Adm/uw.pvv linktree datter host=datter level=newer arch=sun4os5 domain=pvv.unit.no \ unwantedfile=/store/store/Adm/uw.pvv linktree dekk host=dekk level=newer arch=dsosf1 domain=pvv.unit.no \ unwantedfile=/store/store/Adm/uw.pvv linktree flipper host=flipper.pvv.unit.no \ level=newer arch=m88k domain=pvv.unit.no \ unwantedfile=/store/store/Adm/uw.pvv run cmaster on=nova pass=1 run cslave on=nova pass=2 run cclient on=nova pass=3 run cslave on=flipper.pvv.unit.no pass=3 from=nova via=rsh run cslave on=bigblue pass=3 from=nova via=rsh run cslave on=datter pass=3 from=nova via=rsh run cslave on=dekk pass=3 from=nova via=rsh run cslave on=bob pass=3 from=nova via=rsh run cslave on=supernova pass=3 from=nova via=rsh run cclient on=flipper.pvv.unit.no pass=4 from=nova via=rsh run cclient on=bigblue pass=4 from=nova via=rsh run cclient on=datter pass=4 from=nova via=rsh run cclient on=dekk pass=4 from=nova via=rsh run cclient on=bob pass=4 from=nova via=rsh run cclient on=supernova pass=4 from=nova via=rsh run report on=nova pass=4 compile m88k on=flipper.pvv.unit.no compile dsosf1 on=dekk compile rs6aix32 on=bigblue compile sun4os5 on=datter compile hp700ux9 on=bob compile sun4os4 on=nova on=supernova report sun4os4 sun4os5 dsosf1 m88k rs6aix32 \ hp700ux9 linux 386netbsd sgi4i5 sgi3i4
Now say you have a large disk server with several different types of clients, and you want to make linktrees for the clients on the server, as well as a linktree for the server itself. Now `/store' will hold the server's own linktree, `/store/store/large' is the actual repository with lots of packages, and you allocate the directories `/linktrees/sun3', `/linktrees/linux' and `/linktrees/sun4os5' to hold linktrees. The names here doesn't really matter, as long as the server exports the directories, and the clients mount the correct linktree directory on their private `/store', as well as `/store/store/large'.
Let us further assume that some of the sun3 clients really belongs in a maildomain different from the server; they could be at a student lab named studlab.somewhere while the rest of the hosts are in the host.somewhere domain.
The configuration file could look something like this:
internal large external foo bar baz store large host=large.host.somewhere archs=sun3,sun4os4,sun4os5,linux linktree large host=large.host.somewhere \ arch=sun4os413 domain=host.somewhere \ dir=/store linktree largesun3 host=large.host.somewhere \ arch=sun3 domain=host.somewhere \ dir=/linktrees/sun3 linktree largestudlab host=large.host.somewhere \ arch=sun3 domain=studlab.somewhere \ dir=/linktrees/studlab linktree largesun4os5 host=large.host.somewhere \ arch=sun4os53 domain=host.somewhere \ dir=/linktrees/sun4os5 linktree largelinux host=large.host.somewhere \ arch=linux domain=host.somewhere \ dir=/linktrees/linux compile sun4os4 on=large.host.somewhere compile sun3 on=small.host.somewhere compile linux on=pc.host.somewhere compile sun4os5 on=sol.host.somewhere report sun4os4 sun4os5 sun3 linux
The server's `/etc/exports' file could look like:
/linktrees/sun3 -access=sun3hosts /linktrees/sun4os5 -access=sun4os5hosts /linktrees/linux -access=linuxhosts /linktrees/studlab -access=studlabhosts /store/store/large -ro
The sun3 clients' `/etc/fstab' could look like this:
large.host.somewhere:/linktrees/sun3 /store nfs hard,ro,intr large.host.somewhere:/store/store/large /store/store/large nfs hard,ro,intr
Now this is a hypothetical example, but it should hopefully give some good guidelines on how to configure disk servers with foreign linktrees.
The genarchs configuration file defines architectures and domains recognized by STORE. You will need to define your site's domains in this file to be able to use domain-specific files. Also, if you have architectures on your site that we don't have here, you need to add them alongside those already defined.
You should only need to edit the genarchs file on your site's primary repository, so this section is really only relevant to the first STORE installation on a site. If someone else is maintaining the primary repository, ask them to add architectures or domains that you need.
The primary repository will have a directory named `/store/store/<primary>/perl-internal'. To edit the genarchs file, follow this checklist:
co -l genarchs
emacs genarchs
or whatever
ci -u genarchs
cd ..
make install
You may want to change the version number in the Makefile first, so you have both the old and the new version running in parallel first.
Adding an extra architecture should be relatively straight-forward. The relevant part of the configuration file looks like this:
# Normal architectures - add architectures as needed: expand arch allarchs bigend litend expand arch bigend sun sgi apollo hp ibm m88k expand arch litend pmax i386 vax alpha expand arch sun sun3 sparc expand arch sun3 sun3os4 expand arch sun3os4 sun3os40 sun3os41 sun3os411 expand arch sparc sun4os4 sun4os5 expand arch sun4os4 sun4os40 sun4os41 sun4os41B expand arch sun4os41 sun4os411 sun4os412 sun4os413 expand arch sun4os5 sun4os50 sun4os51 sun4os52 sun4os53 ...
To add SunOS 4.1.4 for the sparc platform (fat chance), just change the sun4os41 line to:
expand arch sun4os41 sun4os411 sun4os412 sun4os413 sun4os414
For a more drastic example, let's say you start running repository on your Cray machines running UNICOS 6.0, 6.1, and 7.0. Then we need to add another family altogether. The Cray is big-endian, so change the bigend line and add like this:
expand arch bigend sun sgi apollo hp ibm m88k cray expand arch cray unicos6 unicos7 expand arch unicos6 unicos60 unicos61
The domain part of the genarchs file will probably be more interesting to change, as you will probably want to rip out the part pertaining to the University of Trondheim and substitute your own site. Whether you follow strict mail-domain lines or use some other administrative boundaries as your guide is entirely up to you - do as you feel is most natural. We have found the greatest benefit of domain-specific files to be setup files for mail and news programs, so we follow mail-domains very closely.
The relevant part of the genarchs file looks like this:
# Mail/administration domains - add your own domains as needed. expand domain alldomains unit.no sintef.no expand domain unit.no idt.unit.no fm.unit.no pvv.unit.no \ stud.unit.no kjemi.unit.no ipt.unit.no \ dsl.unit.no ifi.unit.no elkraft.unit.no expand domain fm.unit.no imf.unit.no phys.unit.no expand domain phys.unit.no nobipol.unit.no expand domain stud.unit.no lise.unit.no solan.unit.no siri.unit.no \ marin.unit.no alkymi.unit.no petra.unit.no expand domain sintef.no sima.sintef.no runit.sintef.no
If we wanted to have a global STORE installation, it would probably have to look something like this:
expand domain alldomains edu com gov mil net org countries expand domain edu mit.edu berkeley.edu toronto.edu \ 22cf.edu aa.edu ac.edu accd.edu \ ... expand domain com sun.com sgi.com dec.com cray.com \ 10a.com 1776.com 23kgroup.com 24hour.com \ 24stex.com 2600.com 35sys.com 3com.com \ ... expand domain countries no se fi dk is us ca de nl ae ag al an \ aq ar arpa at au bb be bf bg bh bm bo \ ... expand domain no unit.no uio.no uit.no uib.no sintef.no \ ... expand domain unit.no idt.unit.no fm.unit.no pvv.unit.no \ stud.unit.no kjemi.unit.no ipt.unit.no \ dsl.unit.no ifi.unit.no elkraft.unit.no ...
The syntax and semantics should be quite simple, but if you get problems, send a mail and we'll try to help you.
The nightly script must take care of running the nigthly
perl jobs cmaster
and cslave
on all hosts having
repositories, and cclient
wherever there is a linktree.
In addition it should run report
.
The night.sh script itself is most commonly started from cron. Therefore it may need to set the PATH variable, although the STORE scripts themselves use very few shell commands.
Also, the errors and warnings from the scripts should be logged and (preferably) mailed to the local STORE administrators.
One simple situation is with a standalone machine, where a typical repository script could look like this:
PATH=$HOME/bin:/store/bin:/store/gnu/bin:/local/bin:/usr/bin export PATH ADM=/store/store/Adm OUT=$ADM/output LOG=$ADM/logs/nightly.log MAIL=mail PERSONS=root SCRIPTS=/store/etc/internal exec >$OUT 2>&1 echo "(Info) Store nightly job start `date`" perl $SCRIPTS/cmaster.pl perl $SCRIPTS/cslave.pl perl $SCRIPTS/cclient.pl perl $SCRIPTS/report.pl echo "(Info) Store nightly job stop `date`" $MAIL -s "Nightly Store problems" $PERSONS < $OUT cat $OUT >> $LOG exit 0
Using the run
keyword in your configuration file properly, you
can use the nightly.pl
perl script to actually start the
perl scripts remote. Here's a real world example for the same
host that has the complex configuration file detailed in this
documentation (See section Complex config example):
#! /bin/sh # nightly script, to be run from crontab # checks vital and trivial ting about the Store system ADM=/store/store/Adm OUT=$ADM/output MAIL=/usr/ucb/mail PERSONS="arnej stigb tegge" SCRIPTS=/store/etc/internal PATH=$HOME/bin:/store/bin:/store/gnu/bin:/local/bin:\ /local/gnu/bin:/local/X11/bin:/usr/lang:/usr/ucb:/bin:\ /usr/bin:/local/etc:/etc:/usr/etc:/etc/bin:/local/games:/usr/games export PATH exec >$OUT 2>&1 perl $SCRIPTS/nightly.pl cat $OUT >> $ADM/logs/nightly.log $MAIL -s "Nightly Store problems" $PERSONS < $OUT exit 0
On another host, where logs aren't as important, the "store" user's crontab file starts the nightly.pl script directly:
lastebil:/store/store/lastebil/Adm$ crontab -l 1 1 * * * perl /store/etc/internal/nightly.pl | \ /usr/sbin/Mail -s "Nightly Store problems" arnej hanche vindvad
The most common way to do nightly commands is to
write a small script. So rplay, a sound package with
remote sound possibilities, has a registered Nightly Command
with the value perl /store/etc/make-rplay.conf.pl
that is run on each cclient
run.
As is usual in such cases, the purpose of the script is to
update a configuration file, so the registered Not Links value
is etc/rplay.conf
, meaning that the perl script should
construct /store/etc/rplay.conf (in this case, by finding sound
files by searching `/store/lib/sound').
Another example is the makewhatis packages. The relevant parts of the registration file looks like this:
Nightly Command ... : /store/etc/catman Not Links . ... ... : man/whatis.* gnu/man/whatis.*
The `/store/etc/catman' script itself is quite short, so is reproduced here as a good example of how to write a nightly command script:
#!/bin/sh topdir=${TOPDIR-/store} for MD in $topdir/man $topdir/gnu/man ; do if test -d $MD && test -w $MD; then rm -rf /tmp/mkw.log.* /tmp/mkw.err.* perl /store/etc/makewhatis.pl -M $MD \ >/tmp/mkw.log.$$ 2>/tmp/mkw.err.$$ if test -s /tmp/mkw.err.$$; then echo "(Warning) Errors when trying to run makewhatis on $MD:" sed 's/^/ /' < /tmp/mkw.err.$$ ( cat /tmp/mkw.log.$$ /tmp/mkw.err.$$ \ >> /store/store/Adm/logs/makewhatis.log ) 2>/dev/null rm -f /tmp/mkw.log.$$ /tmp/mkw.err.$$ else rm -f /tmp/mkw.log.$$ /tmp/mkw.err.$$ fi fi done
Here's a list of packages that I consider to be some of the most important in repository, as indicated by the fact that they are compiled for most architectures. The report format is as generated by the report utility. The selection is obviously somewhat biased, but I can't list everything: On last count we had more than 500 applications total.
P R O G R A M S I N S T O R E Page 1 386netbsd ---+ +--- sgi4i5 Examples ---+ dsult4 ---+| |+--- hp700ux9 Online help ---+| sun4os5 ---+|| ||+--- linux Hardcopy Documentation ---+|| sun4os4 ---+||| |||+--- rs6000 Manual pages ---+||| i386sol24 ---+|||| ||||+--- allarchs Emacs info ---+|||| ||||| ||||| ||||| Name PrimVer VVVVV VVVVV Categ. Sign Short description VVVVV ------------------------------------------------------------------------------ X11 5.26 ***** **-*+ os TE MIT Reference Port of X11 -*--- amd 920824 -*+*- ****+ os AHJ AutoMounter Daemon ***-- bash 1.14.3 ***** ****+ os TE FSF's bourne shell ****- bison 1.21 ***** ****+ pwb AHJ GNU version of yacc ***-- byacc 1.9 -**** *-*-+ pwb AHJ Berkeley version of yacc -*--- c-archie 1.4.1 ***** ***++ info AHJ Archie commandline client -*--- chimera 1.63 -**** ****+ info AHJ Web client (X/Athena) -*-*- ctwm 3.2p1 ***** ****+ app MS Fancy window manager -*--- detach 1.1 ***** ****+ adm AHJ Start programs in background -*--- dvipsk 5.55a -**-* **--+ tex HH-O DVI to PostScript converter **-*- elm 2.4.23 ***** **-++ mail Sig Interactive mail program -***- emacs19 19.28 ***** ****+ edit HE The Editor. ---*- fileutils 3.9 ***** ****+ shu AHJ Various file utilities -*--- flex 2.4.6 -**** ****+ pwb AHJ GNU version of lex from PWB **--- fvwm 1.24r ***** ****+ app SSB Motif-like fast virtual WM -*--- gawk 2.15.2 -**** ***-+ shu AHJ GNU version of the awk languag ***-- gcc 2.5.8 ****- ****+ pl AHJ C, C++ and ObjC compiler ***-- gdb 4.13 ****- ****+ pwb HE GNU debugger **--- gdiff 2.5 ***** ****+ shu AHJ difference-computing programs *---- gfind 3.8 -**** ****+ shu AHJ GNU version of find -*--- ghostscrip 2.6.1. ***** ****+ app HaNH Postscript interpreter -**-- ghostview 1.5 -**** ****+ app HE Frontend for Ghostscript -**-- gm4 1.4 ***** ****+ shu AHJ Macropreprosessor *---- gmake 3.69 ***** ****+ pwb AHJ GNU make(1) program *---- gnuplot 3.5 -**** **-*+ app MS Interactive plotting program -*-** gpatch 2.1 ***** **-*+ pwb AHJ Update sources from diffs -*--- groff 1.08 -**** ****+ os AHJ GNU [nt]roff text formatter -**-- gtar 1.11.2 -***- **-*+ arch HE backup/archival tool *---- gzip 1.2.4 ***** ****+ arch AHJ GNU (de)compression - *.gz ***--
P R O G R A M S I N S T O R E Page 2 386netbsd ---+ +--- sgi4i5 Examples ---+ dsult4 ---+| |+--- hp700ux9 Online help ---+| sun4os5 ---+|| ||+--- linux Hardcopy Documentation ---+|| sun4os4 ---+||| |||+--- rs6000 Manual pages ---+||| i386sol24 ---+|||| ||||+--- allarchs Emacs info ---+|||| ||||| ||||| ||||| Name PrimVer VVVVV VVVVV Categ. Sign Short description VVVVV ------------------------------------------------------------------------------ host 930926 ***** ****+ net AHJ Simple yet powerful DNS tool -*--- ispell 3.1.13 -**** **-*+ app Sig Spelling checker **-*- latex2e 1994.1 ***** ***** tex HH-O Macro package for TeX --*-- less 177 ***** ****+ app HE Pages, searches, &c -*-*- libg++ 2.5.2 ****- ****+ lib AHJ GNU C++ class library -*--- lndir 5 ***** ****+ pwb AHJ Create shadow tree to sourceco -*--- lynx 2.3 -**** ****+ info MS Curses based W3 browser --*** makewhatis 1990 ***** ***** adm AHJ Create whatis databases ----- mosaic 2.5 ****- ****+ info SSB X-based WWW client from NCSA ---*- ncftp 1.7.1 ***-* **-*+ net HH-O Alternative UI for FTP -*-*- pbmplus 1mar19 ***** ***-+ ip MS Image conversion and manip. -*--- perl 4.036 ***** ****+ pl AHJ Scripting language -*--- rcs 5.6.0. ***** **-*+ os SSB Simple revision control system -*--- rdist 6.1bet -**** **--+ adm TE Distribution of files -*--- shellutils 1.12 ***** ****+ shu AHJ Various shell utilities **--- startxcmd 1.2 ***** ***** shu AHJ Start remote X programs ----- storedoc 2.3 ***** ***** doc AHJ Documentation of Store *-*-- tcsh 6.05p ***** *-**+ sh MS C shell variant -**-- texinfo 3.1 ***** **-++ tex AHJ Emacs-info utilities ***-- textutils 1.11 -**** ****+ shu AHJ Various text utilities **--- web2c 5.8515 -**** **-*+ tex HH-O web2c with TeX, MF and utils -*--- xdvik 1.8 -**** **-++ tex HH-O Preview DVI files under X11 -*--- xlock 1.08ah -**** ****+ app AHJ Lock your screen (for X) -*---
Go to the first, previous, next, last section, table of contents.