Syntax Explanation Example
dpkg -i {.deb package} Install the package dpkg -i zip_2.31-3_i386.deb
dpkg -i {.deb package} Upgrade package if it is installed dpkg -i zip_2.31-3_i386.deb
else install a fresh copy of package
dpkg -R {Directory-name}Install all packages recursively dpkg -R /tmp/downloads
from directory
dpkg -r {package} Remove/Delete an installed package dpkg -r zip
except configuration files
dpkg -P {package} Remove/Delete everything including dpkg -P apache-perl
configuration files
dpkg -l List all installed packages, along dpkg -l,dokg -l | less,
with package version and short dpkg -l '*apache*'
description dpkg -l | grep -i 'sudo'
dpkg -l {package} List individual installed packages, dpkg -l apache-perl
along with package version and
short description
dpkg -L {package} Find out files are provided by the dpkg -L apache-perl,dpkg -L perl
installed package i.e. list where
files were installed
dpkg -c {.Deb package} List files provided (or owned) by dpkg -c dc_1.06-19_i386.deb
the package i.e. List all files
inside debian .deb package file,
very useful to find where files
would be installed
dpkg -S {/path/to/file} Find what package owns the file dpkg -S /bin/netstat
i.e. find out what package does dpkg -S /sbin/ippool
file belong
dpkg -p {package} Display details about package dpkg -p lsof
package group, version, maintainer,
Architecture, display depends
packages, description etc
dpkg -s {package} | grep Status Find out if Debian package dpkg -s lsof | grep Status
is installed or not (status)
No comments:
Post a Comment