Dpkg Was Interrupted You Must Manually Run Sudo Dpkg Configure To Correct The Problem Top →

If you see this error in Ubuntu, Debian, or any Debian-based Linux distribution:

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

It means a previous package installation or upgrade was interrupted (e.g., terminal closed, system crashed, or network failed).
Don’t panic – the fix is simple. If you see this error in Ubuntu, Debian,

dpkg is the low-level package management tool in Debian and its derivatives. It's responsible for installing, removing, and providing information about packages on your system. When you use apt or apt-get to manage packages, these commands interact with dpkg under the hood to perform the actual package management tasks.

The error message actually tells you exactly what to do, though the command can look intimidating to beginners. Follow these steps to resolve the issue. dpkg was interrupted, you must manually run 'sudo

If sudo dpkg --configure -a continues to fail, use these alternative commands in order:

| Command | Purpose | |---------|---------| | sudo dpkg --configure -a | Configure all pending packages | | sudo apt --fix-broken install | Fix broken dependencies | | sudo apt-get install -f | Alternate fix for broken packages | | sudo dpkg --clear-avail | Clear available package cache | | sudo apt-get update --fix-policy | Regenerate package policy | It means a previous package installation or upgrade

Nuclear option (but safe):

sudo apt-get update --fix-missing
sudo apt-get dist-upgrade