[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: --test and scripts



Kenneth Porter wrote:
> 
> I always test-install a package before really installing it to watch
> for surprises. Today I tried upgrading wu-ftpd and during my test phase
> a script ran that deleted the wuftpd line from my /etc/conf.linuxconf.

Ouch!

> Is RPM working as designed, or should I be using some other switch to
> suppress scripts while testing?

I don't know, but I'd love to.  Anyone?

> I also searched the spec file and couldn't find any reference to
> conf.linuxconf. Where did that script come from? Is there some way to
> know ahead of time what scripts will run and what packages they come
> from?

I usually query the file for pre-install, post-install, pre-uninstall,
and post-uninstall (of course, for your purposes, you'd have to query
the currently installed package for the uninstall stuff):
===============================================================
rpm -q --qf "%{PREIN}\n%{POSTIN}\n%{PREUN}\n%{POSTUN}\n" -p
wu-ftpd-2.6.1-9.i386.rpm
(none)
if [ ! -f /var/log/xferlog ]; then
    touch /var/log/xferlog
    chmod 600 /var/log/xferlog
fi
(none)
(none) 
===============================================================

So, in this case, wu-ftpd-2.6.1-9 has a post-install script which
creates a transfer log.  Which version-release of wu-ftpd were you
testing?  Which version-release of wu-ftpd were you replacing?

(FWIW, %{POSTINPROG} for this file is simply "/bin/sh".)


-- 
Mark Amidon                | "Even within the walls of Microsoft,
amidon@acrylis.com         |  Microsoft Outlook is known as 
(978) 251-1987 x252        |  'Look Out!'."
http://www.whatiflinux.com |    -- Erik Heino





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] []