[2573] in SIPB_Linux_Development
Re: /bin/login (ttylogin) and /etc/sendmail.cf (athena-rc)
daemon@ATHENA.MIT.EDU (Salvatore Valente)
Wed Feb 10 22:06:31 1999
Date: Wed, 10 Feb 1999 22:06:15 -0500 (EST)
To: warlord@MIT.EDU
Cc: linux-dev@MIT.EDU
In-Reply-To: <sjmn22l92si.fsf@datkins.ihtfp.org> (message from Derek Atkins on
10 Feb 1999 19:55:57 -0500)
From: Salvatore Valente <svalente@MIT.EDU>
Derek wrote:
If there is an update of util-linux, it will write-through the symlink
and we will lose /bin/athena/login...
I've tested this in the past.
As far as I can tell, rpm has been fixed so it works now. "rpm -U"
appears to erase the old files (whether they are actual files or
symlinks) before it creates the new files.
To test this, I created a two revisions of a package called "lntest"
which contained the file /tmp/lntest, and a package called "trigger"
which contained the following trigger:
%triggerin -- lntest
mv -f /tmp/lntest /tmp/lntest.orig
ln -s /tmp/athena-lntest /tmp/lntest
Notice that, when I upgraded to the second revision of lntest, it
created the new /tmp/lntest without destroying /tmp/athena-lntest.
Then, the trigger kicked in (again). It renamed the new "lntest" to
"lntest.orig" (overwriting the original lntest.orig), and recreated
the symlink.
# rpm -i /usr/src/redhat/RPMS/i386/lntest-1-1.i386.rpm
# cat lntest
this is lntest 1
# rpm -i /usr/src/redhat/RPMS/i386/trigger-1-1.i386.rpm
# cat lntest
this is athena-lntest
# rpm -U /usr/src/redhat/RPMS/i386/lntest-1-2.i386.rpm
# cat lntest
this is athena-lntest
# cat lntest.orig
this is lntest 2
Also, as the ttylogin scripts currently exist, if there is
ever an upgrade to ttylogin it will wind up restoring the original
/bin/login (%postun _IS_ run on upgrade!)
I'll fix the %postun.
Sal.