# List all installed packages
#
dpkg-query -l
 
# List files in an installed package
#
dpkg-query -L $PACKAGE_NAME
 
# List the package that owns a particular file
#
dpkg-query -S $FULL_PATH_TO_FILE