Question about (trigger)script execution and arguments

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

 



Hi,

I have made two test packages to see the rpm script execution order
and the arguments passed to those scripts.  This raises two questions.

The rpm documentation says the following about script execution:

  new-%pre      for new version of package being installed
  ...           (all new files are installed)
  new-%post     for new version of package being installed

  any-%triggerin (%triggerin from other packages set off by new install)
  new-%triggerin
  old-%triggerun
  any-%triggerun (%triggerun from other packages set off by old uninstall)

  old-%preun    for old version of package being removed
  ...           (all old files are removed)
  old-%postun   for old version of package being removed

  old-%triggerpostun
  any-%triggerpostun (%triggerpostun from other packages set off by old un
                install)

Having two packages installed, rpmtrace-a and rpmtrace-b, both version
0.1, triggering each other, and upgrading rpmtrace-a to version 0.2
(*only* "-a", not "-b"!), I see this script execution order:

Thu Jun 3 22:45:56 CEST 2004 rpmtrace-a-0.2-1 %{pre} 2
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-a-0.2-1 %{post} 2
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-b-0.1-1 %{triggerin}[rpmtrace-a] 2 2
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-a-0.2-1 %{triggerin}[rpmtrace-b] 1 1
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-a-0.1-1 %{triggerun}[rpmtrace-b] 0 1
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-b-0.1-1 %{triggerun}[rpmtrace-a] 2 1
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-a-0.1-1 %{preun} 1
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-a-0.1-1 %{postun} 1
Thu Jun 3 22:45:56 CEST 2004 rpmtrace-b-0.1-1 %{triggerpostun}[rpmtrace-a] 2 1

Now my two questions:

-  The documented "old-%triggerpostun" does not seem to be executed.

-  I do not understand the parameters of the %trigger scripts.  I thought
   it showed the # packages installed after the whole rpm operation of
   the package that included the trigger script and the trigger packages.
   But I even *two* 2's at some point (first trigger script).

   How are the exact semantics of the arguments given to the scripts?

Thanks,

--
--    Jos Vos <jos@xxxxxx>
--    X/OS Experts in Open Systems BV   |   Phone: +31 20 6938364
--    Amsterdam, The Netherlands        |     Fax: +31 20 6948204


_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux