apt-file - Find programs inside APT/Debian-repositories

Recently I noticed on a freshly installed server that there was no command called nslookup. Luckily, Debian-like distributions have the apt-file tool.

This makes it possible to search for applications that are not yet installed but are in principle available in the APT repository. The command

apt-file search nslookup

quickly shed light on the matter and delivered the following output:

bash-completion: /usr/share/bash-completion/completions/nslookup
bind9-doc: /usr/share/doc/bind9-doc/arm/man.nslookup.html
dnsutils: /usr/bin/nslookup
dnsutils: /usr/share/man/man1/nslookup.1.gz
exim4-doc-html: /usr/share/doc/exim4-doc-html/spec_html/ch-the_dnslookup_router.html
fpc-source-3.0.4: /usr/share/fpcsrc/3.0.4/packages/fcl-net/examples/cnslookup.pp
libnet-nslookup-perl: /usr/share/doc/libnet-nslookup-perl/changelog.Debian.gz
libnet-nslookup-perl: /usr/share/doc/libnet-nslookup-perl/copyright
libnet-nslookup-perl: /usr/share/lintian/overrides/libnet-nslookup-perl
libxpa-dev: /usr/share/man/man3/xpanslookup.3.gz

So it was clear that the dnsutils package had to be installed afterwards. Calling

apt-get install dnsutils

was enough and the nslookup tool was already available on my server.

If apt-file itself is not yet installed, it can be installed beforehand using

apt-get install apt-file

It is important that the cache is set up immediately afterwards. This is done using

apt-file update

Linux administration can be so easy …

Created on January 15, 2023 by Andreas Wittmann

Home - Sitemap - Privacy-policy/Impressum

Coypright 2024 by Andreas Wittmann
All rights reserved