A dpkg trigger is a facility that allows events caused by one package but of interest to another package to be recorded and aggregated, and processed later by the interested package. This feature simplifies various registration and system-update tasks and reduces duplication of processing.
(NB: Triggers are intended for events that occur during package installation, not events that occur in general operation.)
For full documentation about dpkg triggers, see /usr/share/doc/dpkg/spec/triggers.txt or /usr/share/doc/dpkg/triggers.txt.gz, as well as the deb-triggers(5), and dpkg-trigger(1) man pages. A tutorial on how to get started (with an example) is available on stackoverflow dpkg-how-to-use-trigger.
This page will be used to track triggerisation of parts of Debian.
update-menus: triggers supported in menu since 2.1.39; for etch packages still need to call update-menus, to handle partial upgrades. Post etch, update-menus will only need to be called for menu-methods. (See 473467)
However, this doesn't actually work. See 518919
- update-initramfs: Triggers are supported from version 0.92 on.
- scrollkeeper: Triggerization would avoid ugly hacks in d-i, and speed up upgrades. TODO (However, scrollkeeper may be deprecated soon.)
- tetex: maintainers plan to use triggers to speed up greatly
ldconfig: patch in 447609, but ldconfig's caching has improved in the meantime, may not be necessary
apt: Triggers are supported from version 0.7.7 on. Additional changes allow triggers to run less often, see 473461
d-i: Should be able to defer all triggers across multiple apt runs, and run them at the end, avoiding a certian amount of redundant work. Will need apt changes described in 473461
- dpkg: Triggers are supported from version 1.14.17 on.
- update-mime: Estimated speedup of 1 minute for desktop installs by triggerizing these. TODO
- update-mime-database: Supports triggers from version 0.51-2 (post-lenny)
- update-icon-caches: Could be triggerized to eliminate dh_icons and improve icon cache handling robustness. TODO
- update-desktop-database: Supports triggers from version 0.21-1
install-info: Transition ongoing Transitions/DpkgToGnuInstallInfo.
- insserv: Unknown if triggers could be used for this.
xine-lib: Triggers could be used to update xine-lib front ends' desktop files. See 472870
- fc-cache: Candidate to use triggers. TODO
update-grub: When many kernel packages are installed/removed in one go, update-grub is called many times unnecessarily. Ubuntu has patched grub for this, we'd need to adapt that patch to grub2. See 481542
- metainit: (if it will be continued) Could be triggerized to eliminate dh_metainit TODO
- flash-kernel: Could be triggerised to avoid multiple writes to flash in a single dpkg run. (Robustness is a concern.) TODO
- mandb: Triggers are supported from version 2.5.1-4 on.
- doc-base: Triggers are supported from version 0.8.11 on.
auctex: Currently runs update-auctex-elisp via cron.weekly; could run via trigger instead. 478733
- libapache2-mod-php5 ?
- python-support: Triggers on /usr/share/python-support and /usr/lib/python-support since 0.8.0.
- yorick-doc: triggers on /usr/share/yorick-doc/, /u/s/yorick/i/ and /u/s/yorick/i0 since 2.1.05+dfsg-5 (20080522).
- debhelper: maintainer script fragments are being removed once trigger support is in a stable release
- update-inetd: plans to migrate to triggers
- bash-completion: triggers on /usr/bin, /usr/sbin, /usr/games, /bin and /sbin since 1:1.3-2
* https://lists.ubuntu.com/archives/ubuntu-devel/2007-January/023212.html - Original spec