In article <[EMAIL PROTECTED]>,
Pat Wilson <[EMAIL PROTECTED]> wrote:
>
>Someone else wrote first:
>>  a) How can package be used to "fs newcell $cell $server_list"
>>     for each cell listed in /usr/vice/etc/CellServDB?
>>     ("reboot the client" is not the right answer in our environment.)
>>  
>>  b) Changes to CellServDB involve cells being added and removed.
>>     How can I use package to keep my AFS cell mounts consistent
>>     with these changes?
>>  
>>  Reading package documentation, it is not clear if package can do a) and b).
>>  Hence, reciprocated "shooting from the hip" from over here!     ;-)
>
>Of course, package by itself can't do that (at least as far as _I_ know).
>You'd have to check the return code from the package run, and fire off a
>shell script to Do the Right Things if the files had changed.  I suppose
>that the perl script wouldn't be _too_ hard to write, and lots of folks
>would benefit from it...  

We have our package runs wrapped in a script called "run_package".  It
performs some assorted housecleaning and status checking before actually
running package.   Some of these files are actually moved back into AFS
as a crude database of system configuration.

Assuming package runs successfully, another script called "post_package"
is called, that deals with things like restarting inetd if a new inetd.conf,
got installed, generating spool directories if the printcap file got
changed, and so on.   One of the things this does, is fs newcell if
the cellserv.db file has changed.   (I just happened to notice this
today when I ran package manually on a machine for another reason.)

These scripts (run_package, post_package) can be found in 
    /afs/rpi.edu/wsadmin/InstallFiles/sun4c_41/usr/local/etc

Warning - We often do things in strange ways here, even for an AFS shop
they might be considered strange......  However, the scripts can provide
a handy model if nothing else.

-- 
Jon Finke                           [EMAIL PROTECTED]
Senior Network Systems Engineer     http://www.rpi.edu/~finkej
Information Technology Services     518 276 8185 (voice) | 518 276 2809 (fax)
Rensselaer Polytechnic Institute    110 8th Street, Troy NY, 12180

Reply via email to