Debian: How can I tell which package an executable came from?

Olivier Potin published on

1 min, 95 words

Categories: Technical

Debian: How can I tell which package an executable came from?

Install apt-file

# apt-get install apt-file 

Update apt-file

# apt-file update

https://askubuntu.com/questions/308045/differences-between-bin-sbin-usr-bin-usr-sbin-usr-local-bin-usr-local

https://wiki.debian.org/WhereIsIt

Apt supports regular expression, so you can use:

apt search ^python$ which looks for a package started with a p followed by ytho and ended to the n, (in other words: looks exactly for python).

or even limit your search to the package names using:

apt search --names-only python