dpkg-statoverride - Linux


Overview

dpkg-statoverride overrides the original statistics kept by the Debian package management system for the specified package. This allows simulating the installation of a package without actually installing it.

Syntax

dpkg-statoverride [options] <package>

Options/Flags

  • -i|–install: Simulate the installation of the package.
  • -r|–remove: Simulate the removal of the package.
  • -p|–purge: Simulate the purging of the package (removing all files and configuration).
  • -a|–all: Simulate the installation/removal/purge of all installed packages.
  • -h|–help: Display this help message.

Examples

# Simulate the installation of package "foo"
dpkg-statoverride -i foo

# Simulate the removal of package "bar"
dpkg-statoverride -r bar

# Simulate the purging of package "baz"
dpkg-statoverride -p baz

# Simulate the installation of all installed packages
dpkg-statoverride -a

# Simulate the removal of all installed packages
dpkg-statoverride -ar

Common Issues

No common issues are associated with dpkg-statoverride.

Integration

dpkg-statoverride can be used in conjunction with other Debian package management commands, such as dpkg, apt, and aptitude.

For example, the following command simulates the installation of package "foo" and installs another package "bar":

dpkg-statoverride -i foo && apt install bar

Related Commands

  • dpkg – Debian package management system
  • apt – Advanced Package Tool
  • aptitude – Text-based package management tool