[OpenAFS-devel] RC-Script correctness for Linux 2.6

Mike Becher Mike.Becher@lrz-muenchen.de
Fri, 17 Dec 2004 08:44:52 +0100 (CET)


  This message is in MIME format.  The first part should be readable text,
  while the remaining parts are likely unreadable without MIME-aware tools.
  Send mail to mime@docserver.cac.washington.edu for more info.

--8323584-308963984-1103269492=:32519
Content-Type: TEXT/PLAIN; charset=US-ASCII

On Thu, 16 Dec 2004, Matthew Miller wrote:

> On Thu, Dec 16, 2004 at 06:54:19PM +0100, Mike Becher wrote:
> > I work on ia64_linux26 stuff for openafs. Anytime I try to use CVS 
> > snapshots or unstable versions of source code I have to apply a patch to 
> > afs.rc.linux to make it work for Linux 2.6. The nameing conventions for 
> > modules is now "<module>.ko". The patch makes afs.rc able to distiguish 
> > between module extensions for old and new nameing convention.
> 
> You may want to take a look at the new client init script from my
> 1.3.x RPMs for Fedora Core -- <http://www.mattdm.org/misc/openafs/>.
OK, I have taken a look at your openafs-init.sh. It depends really on 
redhat based distributions.

Comments:
 * Patch supplied make it work on other systems (I hope). 
   There are some functions and features which only exists on redhat 
   systems like echo_failure, echo_success and daemon. 
   Additionally /etc/rc.d/init.d/functions exists only on redhat.
 * If "openafs-init.sh stop" will be called it is better to kill all
   processes which CWD is in /afs or which have files open in /afs.
   You can find out such processes with for example
     lsof | awk '($NF ~ /^\/afs/){print $2}' | uniq
   Then seend them a kill -HUP <pids> and after some times scan again and 
   send a kill -KILL <pids> then umount will probably not fail.
 * If you want that openafs-init.sh should umount AFS only when there are 
   no clients of /afs then provide another option like for example 
     openafs-init.sh softstop
 * SuSE need also some suggestions for default Start/Stop runlevels.

best regards
  mike

> 
> (If unpacking the src rpm is a pain for you, let me know, and I can send you
> the init script directly.)
> 
> As always, anyone's help in making this better is much appreciated.
> 
> 
> -- 
> Matthew Miller           mattdm@mattdm.org        <http://www.mattdm.org/>
> Boston University Linux      ------>                <http://linux.bu.edu/>
> 
--8323584-308963984-1103269492=:32519
Content-Type: TEXT/PLAIN; charset=US-ASCII; name="openafs-init.sh.patch"
Content-Transfer-Encoding: BASE64
Content-ID: <Pine.LNX.4.58.0412170844520.32519@lxmbe01.lrz.lrz-muenchen.de>
Content-Description: openafs-init.sh.patch
Content-Disposition: attachment; filename="openafs-init.sh.patch"

LS0tIG9wZW5hZnMtaW5pdC5zaC5vcmlnCTIwMDQtMDYtMTggMTk6MjU6NTEu
MDAwMDAwMDAwICswMjAwDQorKysgb3BlbmFmcy1pbml0LnNoCTIwMDQtMTIt
MTcgMDg6MTc6MTMuNjY1OTEwNzEwICswMTAwDQpAQCAtMjIsMTMgKzIyLDQx
IEBADQogIyBQcm92aWRlczogYWZzDQogIyBSZXF1aXJlZC1TdGFydDogJG5l
dHdvcmsNCiAjIFJlcXVpcmVkLVN0b3A6ICRuZXR3b3JrDQorIyBEZWZhdWx0
LVN0YXJ0OiAzIDUNCisjIERlZmF1bHQtU3RvcDogMCAxIDIgNg0KKyMgRGVz
Y3JpcHRpb246ICBBRlMgaXMgYSBkaXN0cmlidXRlZCBmaWxlIHN5c3RlbSB3
aGljaCBwcm92aWRlcyBsb2NhdGlvbg0KKyMgICAgICAgICAgICAgIHRyYW5z
cGFyZW5jeSwgY2FjaGluZyBhbmQgc2VjdXJlIGF1dGhlbnRpY2F0aW9uLg0K
KyMgICAgICAgICAgICAgIEFkZGl0aW9uYWwgY29uZmlndXJhdGlvbiBjYW4g
YmUgZG9uZSBpbiB0aGUgL2V0Yy9zeXNjb25maWcvYWZzDQorIyAgICAgICAg
ICAgICAgZmlsZS4gUmVhZCB0aGUgZG9jdW1lbnRhdGlvbiBpbiB0aGF0IGZp
bGUgZm9yIG1vcmUgaW5mb3JtYXRpb24uDQorIyMjIEVORCBJTklUIElORk8N
CisNCisNCiAjIyMgRU5EIElOSVQgSU5GTw0KIA0KICMgTm90ZSB0aGF0IEFG
UyBkb2VzIG5vdCB1c2UgYSBwaWQgZmlsZSBpbiAvdmFyL3J1bi4gSXQgaXMg
dHVybmVkIG9mZiBieQ0KICMgdW5tb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