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”

Android Android Build system Android Commands Android Java Applications Application Libraries Application Stack / User Interface Bash / Shell Scripts Commands and Packages Compilation Content Management System - CMS Core Kernel C Programs Development & Build Development Environment Setup Errors & Failures Flutter git Go Language Programs Hardware Platforms HTML JAVA Programs Kernel & Device Drivers Linux, OS Concepts and Networking Linux Device Drivers Linux Host, Ubuntu, SysAdmin Linux Kernel Linux Networking Middleware Libraries, HAL Monetization / Google AdSense NDK / Middleware / HAL OS Concepts PHP Programming Languages RaspberryPi Scripting and Automation Search Engine Optimisation ( SEO ) Social Media Socurce Code Management ( SCM ) System Administration, Security Testing and Debugging Uncategorized Userspace Utilities Web design and development Wordpress Yocto / Bitbake / Openembedded

Leave a Reply / Ask Question