simon@spunky@corona.att.com (06/28/90)
When running yppasswdd with the -m flag to force a remake in /var/yp I
noticed that my YP (NIS for the British Telcom folks) passwd map was not
properly being updated from the intermediate file which yppasswd modifies.
I tracked it down by making a dummy version of the make program. As it
turns out rpc.yppasswdd does indeed invoke make with current working
directory /var/yp. Unfortunately it completely appended the arguments
provided after the -m flag to its own, and calls make with the resulting
arglist i.e.
On server: (in /etc/rc.local)
if [ -f /usr/etc/rpc.yppasswdd -a -d /var/yp/`domainname` ]; then
rpc.yppasswdd /etc/passwd -m DIR=/var/yp
echo -n ' yppasswdd'
fi
will result in calls to make in /var/yp with the following arguments
argv 0 1 2 3 4
make rpc.yppasswdd /etc/passwd -m DIR=/var/yp
needless to say this doesn't work. A user who thought they changed their
password with yppasswd will only be able to use their new password once
someone manually does a make in /var/yp - not optimal. I'll bug Sun about
this. Hopefully others will too.
Marc Simon simon@corona.ATT.COMcasper@fwi.uva.nl (Casper H.S. Dik) (06/29/90)
In article <9425@brazos.Rice.edu> simon@spunky@corona.att.com writes: >X-Sun-Spots-Digest: Volume 9, Issue 244, message 3 > >When running yppasswdd with the -m flag to force a remake in /var/yp I >noticed that my YP (NIS for the British Telcom folks) passwd map was not >properly being updated from the intermediate file which yppasswd modifies. >I tracked it down by making a dummy version of the make program. As it >turns out rpc.yppasswdd does indeed invoke make with current working >directory /var/yp. Unfortunately it completely appended the arguments >provided after the -m flag to its own, and calls make with the resulting >arglist i.e. I used also used a dummy version of make to get to the bottom. This is the work around I now use: -----/var/yp/make--- #!/bin/sh # throw away excess arguments rcp.yppasswd passwdfile -m shift ; shift ; shift # set the umask (passwd.dir,passwd.pag ended up rw-rw-rw-!) umask 022 #echo "$@" >> /tmp/kladje /bin/make "$@" ------end of /var/yp/make --- On server: (in /etc/rc.local) if [ -f /usr/etc/rpc.yppasswdd -a -d /var/yp/`domainname` ]; then PATH=/var/yp:$PATH rpc.yppasswdd /etc/passwd -m DIR=/var/yp echo -n ' yppasswdd' fi Hope this is of some use. Casper H.S. Dik VCP/HIP: +31205922022 University of Amsterdam | casper@fwi.uva.nl The Netherlands | casper%fwi.uva.nl@hp4nl.nluug.nl