How do I list the files installed by a deb package?
Solution 1:
Yes, use the dpkg
command like
dpkg -L hadoop-0.20
The converse question (finding the package providing a given file) is answered with e.g.
dpkg -S /usr/include/gc/gc.h
Read more about Debian packaging related tools.
P.S. Ubuntu (and other Linux distributions, e.g Mint) is a derivative of Debian.
Solution 2:
What files are installed on your system varies from package to package. To be 100% sure you should take a look into the .deb
package yourself. Download the package first.
First you need to extract the .deb
archive:
ar vx mypackage.deb
Now this should result in three new files: debian-binary
, control.tar.gz
and data.tar.gz
. You're interested in the last one.
Now you can extract it as well using tar
:
tar xzvf data.tar.gz
Now you can browse the package content freely. Look for any makefiles, install scripts and such like to see where things gets installed.
Solution 3:
You can list the installed files for a package by passing the --listfile flag to dpkg. For example, if your package is actually named "hadoop-0.20" then:
dpkg --listfiles hadoop-0.20