Home

varlibdpkgstatus

varlibdpkgstatus refers to the Debian package status database used by the dpkg package manager. On Debian-based systems, the main database is stored in the file /var/lib/dpkg/status. The file is a plain-text catalog that records information about packages known to the package system, including those currently installed, unpacked but not configured, or removed, as well as transitional or failed-state entries. It serves as the authoritative source for the current state and metadata of packages on the system.

The file contains a sequence of package records. Each record begins with a line such as Package:

Utilities such as dpkg-query, dpkg -l, and apt show or inspect the information in this database to

Directly editing /var/lib/dpkg/status is discouraged unless necessary, as corruption can destabilize the package manager. It is

name
and
is
followed
by
fields
like
Version,
Installed-Size,
Architecture,
Maintainer,
Description,
Depends,
and
Status.
The
Status
field
conveys
the
package’s
current
state,
for
example:
install
ok
installed,
deinstall
ok
config-files,
or
deinstall
remove;
these
values
help
dpkg
and
higher-level
tools
determine
what
actions
are
permissible
or
required.
Other
common
fields
include
Priority,
Section,
and
Provides
or
Recommends,
which
help
categorize
and
resolve
dependencies.
report
what
is
installed
and
to
resolve
dependencies.
APT
and
dpkg
rely
on
the
status
file
to
decide
what
operations
to
perform
during
installs,
upgrades,
or
removals,
and
to
provide
status
summaries
to
users
and
scripts.
advisable
to
manage
package
states
with
dpkg
and
APT
tools
(for
example,
dpkg
--set-selections,
apt-mark)
and
to
back
up
the
status
file
before
making
changes.
If
corruption
occurs,
verify
integrity,
restore
from
a
known-good
backup,
or
reinstall
packages
as
needed.