SCIENTIFIC-LINUX-USERS Archives

September 2013

SCIENTIFIC-LINUX-USERS@LISTSERV.FNAL.GOV

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Sean Murray <[log in to unmask]>
Reply To:
Sean Murray <[log in to unmask]>
Date:
Tue, 17 Sep 2013 16:16:57 +0200
Content-Type:
multipart/signed
Parts/Attachments:
text/plain (1666 bytes) , smime.p7s (1933 bytes)
Hi

Before I begin let me say my bash is putrid.

As I read it the afs startup script in /etc/rc.d/init.d/afs does not permit the
case of a cell not being in the CellServDB file even if you enable ENABLE_AFSDB
to append the -afsdb command line switch.

It looks like the line 213 will block it from working ?
CELL gets defined as the dnsname correctly but then the script refuses to start
as the CELL is not in the CellServDB, causing the script to bomb out on line 218

Offending function is this :

195 check_thiscell() {
196     CELL=
197     if [ -s /usr/vice/etc/ThisCell ] ; then
198         CELL="$(cat /usr/vice/etc/ThisCell)"
199         if [ -n "$CELL" ]; then
200             grep -w -q -s ">$CELL" /usr/vice/etc/CellServDB
201             if [ $? -ne 0 ] ; then
202                 echo afs: $CELL from ThisCell is not in CellServDB.  Not starting. 1>&2
203                 return 1
204             fi
205             return 0
206         fi
207     fi
208     CELL=`dnsdomainname`;
209     if [ $? -ne 0 -o -z "$CELL" ] ; then
210         echo afs: No cell defined. Trying to figure it out failed. Not starting. 1>&2
211         return 1
212     fi
213     grep -w -q -s ">$CELL" /usr/vice/etc/CellServDB
214     if [ $? -ne 0 ] ; then
215         echo afs: No cell defined. Trying to figure it out failed. Not starting. 1>&2
216         return 1
217     fi
218     echo "$CELL" > /usr/vice/etc/ThisCell && chmod 0644 /usr/vice/etc/ThisCell
219     if [ $? -ne 0 ] ; then
220         echo afs: No cell defined. Trying to configure "$CELL" failed. Not starting. 1>&2
221         return 1
222     fi
223     echo afs: Warning: No cell was defined. Autoconfigured "$CELL". 1>&2
224 }



ATOM RSS1 RSS2