Finding list of installed files from a package in Linux

Recently we installed one package, but couldn’t understood which all files it installed on Ubuntu. You can use the command as,

 dpkg-query -L PACKAGE_NAME

So, lets say, you want to identify which are files “openssh-server” package installed, then run the command as below,

 dpkg-query -L openssh-server

/.
/etc
/etc/ufw
/etc/ufw/applications.d
/etc/ufw/applications.d/openssh-server
/etc/pam.d
/etc/pam.d/sshd
/etc/init
/etc/init/ssh.conf
/etc/network
/etc/network/if-up.d
/etc/network/if-up.d/openssh-server
/etc/default
/etc/default/ssh
/etc/init.d
/etc/init.d/ssh
/lib
/lib/systemd
/lib/systemd/system
/lib/systemd/system/ssh.service
/lib/systemd/system/ssh.socket
/lib/systemd/system/[email protected]
/usr
/usr/sbin
/usr/sbin/sshd
/usr/share
/usr/share/lintian
/usr/share/lintian/overrides
/usr/share/lintian/overrides/openssh-server
/usr/share/doc
/usr/share/doc/openssh-client
/usr/share/doc/openssh-client/examples
/usr/share/doc/openssh-client/examples/sshd_config
/usr/share/man
/usr/share/man/man5
/usr/share/man/man5/sshd_config.5.gz
/usr/share/man/man8
/usr/share/man/man8/sshd.8.gz
/usr/share/apport
/usr/share/apport/package-hooks
/usr/share/apport/package-hooks/openssh-server.py
/usr/lib
/usr/lib/tmpfiles.d
/usr/lib/tmpfiles.d/sshd.conf
/usr/lib/openssh
/usr/share/doc/openssh-server
/usr/share/man/man5/authorized_keys.5.gz

You may also check, How to check which header belongs to which package in ubuntu. and “How to check some binary belongs to which package in ubuntu”

Follow Lynxbee

Leave a Reply / Ask Question