1. Changing system behaviour
Searching
Fooling the package system
Anticipating and correcting problems
Debian menu
Debian Secrets
Power tools for Power users
Wouter Verhelst
FOSDEM 2010/Loadays 2010
Wouter Verhelst Debian Secrets
2. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
update-alternatives
multiple packages providing a particular command
Wouter Verhelst Debian Secrets
3. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
update-alternatives
multiple packages providing a particular command
update-alternatives −−config x-terminal-emulator
Wouter Verhelst Debian Secrets
4. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
update-alternatives
multiple packages providing a particular command
update-alternatives −−config x-terminal-emulator
more info: man update-alternatives
Wouter Verhelst Debian Secrets
5. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
dpkg-statoverride
Limit access to wodim to a group of users
Wouter Verhelst Debian Secrets
6. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
dpkg-statoverride
Limit access to wodim to a group of users
−rwxr−x− − − 1 root cdwriters 401624 May 25 20:12
/usr/bin/wodim
Wouter Verhelst Debian Secrets
7. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
dpkg-statoverride
Limit access to wodim to a group of users
−rwxr−x− − − 1 root cdwriters 401624 May 25 20:12
/usr/bin/wodim
upgrades?
Wouter Verhelst Debian Secrets
8. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
dpkg-statoverride
Limit access to wodim to a group of users
−rwxr−x− − − 1 root cdwriters 401624 May 25 20:12
/usr/bin/wodim
upgrades?
dpkg-statoverride −−update −−add root cdwriters
0750 /usr/bin/wodim
Wouter Verhelst Debian Secrets
9. Changing system behaviour
Searching
update-alternatives
Fooling the package system
dpkg-statoverride
Anticipating and correcting problems
Debian menu
dpkg-statoverride
Limit access to wodim to a group of users
−rwxr−x− − − 1 root cdwriters 401624 May 25 20:12
/usr/bin/wodim
upgrades?
dpkg-statoverride −−update −−add root cdwriters
0750 /usr/bin/wodim
more info: man dpkg-statoverride
Wouter Verhelst Debian Secrets
10. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: debtags
apt-cache search: works, but limited.
Wouter Verhelst Debian Secrets
11. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: debtags
apt-cache search: works, but limited.
too dicult search = brain goes banana
Wouter Verhelst Debian Secrets
12. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: debtags
apt-cache search: works, but limited.
too dicult search = brain goes banana
debtags: more ne-grained searching
Wouter Verhelst Debian Secrets
13. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: debtags
apt-cache search: works, but limited.
too dicult search = brain goes banana
debtags: more ne-grained searching
GoPlay! (or GoAdmin! :)
Wouter Verhelst Debian Secrets
14. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: debtags
apt-cache search: works, but limited.
too dicult search = brain goes banana
debtags: more ne-grained searching
GoPlay! (or GoAdmin! :)
package: debtags, goplay
more info: http://debtags.alioth.debian.org/
Wouter Verhelst Debian Secrets
15. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: grep-available
you know some things about the package
Wouter Verhelst Debian Secrets
16. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: grep-available
you know some things about the package
searching for packages by control elds
Wouter Verhelst Debian Secrets
17. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: grep-available
you know some things about the package
searching for packages by control elds
grep-available -FMaintainer 'wouter@debian.org'
-sPackage
Wouter Verhelst Debian Secrets
18. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: grep-available
you know some things about the package
searching for packages by control elds
grep-available -FMaintainer 'wouter@debian.org'
-sPackage
grep-available -FSource 'linux-2.6' -a -FPackage
'image' -sPackage
Wouter Verhelst Debian Secrets
19. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: grep-available
you know some things about the package
searching for packages by control elds
grep-available -FMaintainer 'wouter@debian.org'
-sPackage
grep-available -FSource 'linux-2.6' -a -FPackage
'image' -sPackage
grep-available -FSource 'linux-2.6' -a -FPackage
'image' -sPackage -sVersion
Wouter Verhelst Debian Secrets
20. Changing system behaviour
Searching
debtags
Fooling the package system
grep-available
Anticipating and correcting problems
Debian menu
Searching for packages: grep-available
you know some things about the package
searching for packages by control elds
grep-available -FMaintainer 'wouter@debian.org'
-sPackage
grep-available -FSource 'linux-2.6' -a -FPackage
'image' -sPackage
grep-available -FSource 'linux-2.6' -a -FPackage
'image' -sPackage -sVersion
package: dctrl-tools
more info: man grep-available
Wouter Verhelst Debian Secrets
21. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-divert: move les aside
Install nVidia binary module from nvidia.com
Wouter Verhelst Debian Secrets
22. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-divert: move les aside
Install nVidia binary module from nvidia.com
nVidia wants to install /usr/lib/libGL.so
Wouter Verhelst Debian Secrets
23. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-divert: move les aside
Install nVidia binary module from nvidia.com
nVidia wants to install /usr/lib/libGL.so
apt-get upgrade...
Wouter Verhelst Debian Secrets
24. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-divert: move les aside
Install nVidia binary module from nvidia.com
nVidia wants to install /usr/lib/libGL.so
apt-get upgrade...
instead: dpkg-divert −−divert
/usr/lib/libGL.so.Debian /usr/lib/libGL.so
Wouter Verhelst Debian Secrets
25. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-divert: move les aside
Install nVidia binary module from nvidia.com
nVidia wants to install /usr/lib/libGL.so
apt-get upgrade...
instead: dpkg-divert −−divert
/usr/lib/libGL.so.Debian /usr/lib/libGL.so
Then, and only then, install nVidia binary module and software
Wouter Verhelst Debian Secrets
26. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-divert: move les aside
Install nVidia binary module from nvidia.com
nVidia wants to install /usr/lib/libGL.so
apt-get upgrade...
instead: dpkg-divert −−divert
/usr/lib/libGL.so.Debian /usr/lib/libGL.so
Then, and only then, install nVidia binary module and software
Warning: do NOT use for conguration les
Wouter Verhelst Debian Secrets
27. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-divert: move les aside
Install nVidia binary module from nvidia.com
nVidia wants to install /usr/lib/libGL.so
apt-get upgrade...
instead: dpkg-divert −−divert
/usr/lib/libGL.so.Debian /usr/lib/libGL.so
Then, and only then, install nVidia binary module and software
Warning: do NOT use for conguration les
more info: man dpkg-divert
Wouter Verhelst Debian Secrets
28. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-repack: Re-create a package le from an installed
package
Install great-game-nonfree from game-writer-company
Wouter Verhelst Debian Secrets
29. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-repack: Re-create a package le from an installed
package
Install great-game-nonfree from game-writer-company
game-writer-company goes bankrupt, and your CD-ROM is
lost
Wouter Verhelst Debian Secrets
30. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-repack: Re-create a package le from an installed
package
Install great-game-nonfree from game-writer-company
game-writer-company goes bankrupt, and your CD-ROM is
lost
Buy new computer, want to play great-game-nonfree there too
Wouter Verhelst Debian Secrets
31. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-repack: Re-create a package le from an installed
package
Install great-game-nonfree from game-writer-company
game-writer-company goes bankrupt, and your CD-ROM is
lost
Buy new computer, want to play great-game-nonfree there too
Use dpkg-repack to create new package to install on new
computer
Wouter Verhelst Debian Secrets
32. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
dpkg-repack: Re-create a package le from an installed
package
Install great-game-nonfree from game-writer-company
game-writer-company goes bankrupt, and your CD-ROM is
lost
Buy new computer, want to play great-game-nonfree there too
Use dpkg-repack to create new package to install on new
computer
package: dpkg-repack
more info: man dpkg-repack
Wouter Verhelst Debian Secrets
33. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
Equivs: NIH
Install self-written not-invented-here MTA
Wouter Verhelst Debian Secrets
34. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
Equivs: NIH
Install self-written not-invented-here MTA
apt-get install cron pulls in exim4
Wouter Verhelst Debian Secrets
35. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
Equivs: NIH
Install self-written not-invented-here MTA
apt-get install cron pulls in exim4
install bogus mail-transport-agent package to satisfy depends
Wouter Verhelst Debian Secrets
36. Changing system behaviour
Searching dpkg-divert
Fooling the package system dpkg-repack
Anticipating and correcting problems equivs
Debian menu
Equivs: NIH
Install self-written not-invented-here MTA
apt-get install cron pulls in exim4
install bogus mail-transport-agent package to satisfy depends
package: equivs
more info: man equivs-build and man equivs-control, also see
/usr/share/doc/equivs
Wouter Verhelst Debian Secrets
37. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
apt-listbugs/apt-listchanges: reviewing before installing
install very-buggy-package from unstable
Wouter Verhelst Debian Secrets
38. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
apt-listbugs/apt-listchanges: reviewing before installing
install very-buggy-package from unstable
apt-listbugs nds and lists release-critical bugs
Wouter Verhelst Debian Secrets
39. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
apt-listbugs/apt-listchanges: reviewing before installing
install very-buggy-package from unstable
apt-listbugs nds and lists release-critical bugs
User can choose to decline downloading/installing
Wouter Verhelst Debian Secrets
40. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
apt-listbugs/apt-listchanges: reviewing before installing
install very-buggy-package from unstable
apt-listbugs nds and lists release-critical bugs
User can choose to decline downloading/installing
apt-get or aptitude downloads packages
Wouter Verhelst Debian Secrets
41. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
apt-listbugs/apt-listchanges: reviewing before installing
install very-buggy-package from unstable
apt-listbugs nds and lists release-critical bugs
User can choose to decline downloading/installing
apt-get or aptitude downloads packages
apt-listchanges lists changelog items and/or NEWS.Debian
items
Wouter Verhelst Debian Secrets
42. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
apt-listbugs/apt-listchanges: reviewing before installing
install very-buggy-package from unstable
apt-listbugs nds and lists release-critical bugs
User can choose to decline downloading/installing
apt-get or aptitude downloads packages
apt-listchanges lists changelog items and/or NEWS.Debian
items
User can choose to decline installing
Wouter Verhelst Debian Secrets
43. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
apt-listbugs/apt-listchanges: reviewing before installing
install very-buggy-package from unstable
apt-listbugs nds and lists release-critical bugs
User can choose to decline downloading/installing
apt-get or aptitude downloads packages
apt-listchanges lists changelog items and/or NEWS.Debian
items
User can choose to decline installing
packages: apt-listbugs, apt-listchanges
Wouter Verhelst Debian Secrets
44. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
debfoster, deborphan, aptitude: nding unused packages
apt-get install warzone2100
Wouter Verhelst Debian Secrets
45. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
debfoster, deborphan, aptitude: nding unused packages
apt-get install warzone2100
Pulls in several libraries
Wouter Verhelst Debian Secrets
46. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
debfoster, deborphan, aptitude: nding unused packages
apt-get install warzone2100
Pulls in several libraries
You don't like the game; apt-get −−purge remove
warzone2100
Wouter Verhelst Debian Secrets
47. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
debfoster, deborphan, aptitude: nding unused packages
apt-get install warzone2100
Pulls in several libraries
You don't like the game; apt-get −−purge remove
warzone2100
Libraries?
Wouter Verhelst Debian Secrets
48. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
debfoster, deborphan, aptitude: nding unused packages
apt-get install warzone2100
Pulls in several libraries
You don't like the game; apt-get −−purge remove
warzone2100
Libraries?
debfoster/aptitude: keep track of what was installed manually
or as a dependency
Wouter Verhelst Debian Secrets
49. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
debfoster, deborphan, aptitude: nding unused packages
apt-get install warzone2100
Pulls in several libraries
You don't like the game; apt-get −−purge remove
warzone2100
Libraries?
debfoster/aptitude: keep track of what was installed manually
or as a dependency
deborphan: nd unused libraries needs to guess, may be
wrong.
Wouter Verhelst Debian Secrets
50. Changing system behaviour
Searching
Finding problems before installing
Fooling the package system
Keeping your system tidy
Anticipating and correcting problems
Debian menu
debfoster, deborphan, aptitude: nding unused packages
apt-get install warzone2100
Pulls in several libraries
You don't like the game; apt-get −−purge remove
warzone2100
Libraries?
debfoster/aptitude: keep track of what was installed manually
or as a dependency
deborphan: nd unused libraries needs to guess, may be
wrong.
packages: debfoster, deborphan
Wouter Verhelst Debian Secrets
51. Changing system behaviour
Searching
Fooling the package system
Anticipating and correcting problems
Debian menu
Changing the Debian menu
Standard menu in most window managers (not all desktop
environments)
Wouter Verhelst Debian Secrets
52. Changing system behaviour
Searching
Fooling the package system
Anticipating and correcting problems
Debian menu
Changing the Debian menu
Standard menu in most window managers (not all desktop
environments)
Modify through /etc/menu, /.menu
Wouter Verhelst Debian Secrets
53. Changing system behaviour
Searching
Fooling the package system
Anticipating and correcting problems
Debian menu
Changing the Debian menu
Standard menu in most window managers (not all desktop
environments)
Modify through /etc/menu, /.menu
package: menu
more info: /usr/share/doc/menu/html, chapter 3 (syntaxis),
chapter 6 (how to override)
Wouter Verhelst Debian Secrets