How to Fix dpkg Was Interrupted on Linux

If dpkg was interrupted, Kudu can help clean package cache and temporary clutter during recovery.

By Kudu Team

Fix this automatically with Kudu

Run a free system scan to detect and resolve this issue automatically — no manual steps required.

Download Kudu Free →

What Causes This?

The “dpkg was interrupted” error usually appears when a package install, upgrade, or removal did not finish properly. This can happen after a forced shutdown, power loss, terminal window being closed, or another package manager process stopping unexpectedly. It may also show up if package locks, broken dependencies, or damaged cache files are left behind after the interruption.

Common Symptoms

  • You see a message like dpkg was interrupted, you must manually run 'sudo dpkg --configure -a'
  • apt, apt-get, or Software Updater refuses to install or update packages
  • Package installs stop with dependency or lock-file errors
  • System updates remain stuck or partially installed
  • You notice repeated errors when trying to repair packages

How to Fix It Manually

  1. Open a terminal

    • On Ubuntu or Debian-based systems, press Ctrl+Alt+T to open Terminal.
    • If you cannot open Terminal normally, open the app menu and search for Terminal.
  2. Finish the interrupted package configuration

    • Run:
      sudo dpkg --configure -a
    • Enter your password when prompted.
    • Let the command complete fully, even if it takes a few minutes.
  3. Fix broken dependencies

    • If dpkg --configure -a reports missing packages or dependency problems, run:
      sudo apt --fix-broken install
    • Confirm with Y if asked.
    • When it finishes, run this again to make sure everything is configured:
      sudo dpkg --configure -a
  4. Update package lists

    • Refresh your package database:
      sudo apt update
    • If this completes without errors, your package manager is working again.
  5. Clear package cache if errors continue

    • Corrupted or incomplete package files can keep causing the same issue. Clean them with:
      sudo apt clean
      sudo apt autoclean
    • Then try:
      sudo apt update
      sudo apt upgrade
  6. Check for lock files only if the package manager is not running

    • First, see whether another package process is active:
      ps aux | grep -E 'apt|dpkg'
    • If no real apt or dpkg process is running but lock errors remain, remove stale lock files:
      sudo rm -f /var/lib/dpkg/lock
      sudo rm -f /var/lib/dpkg/lock-frontend
      sudo rm -f /var/cache/apt/archives/lock
    • Then run:
      sudo dpkg --configure -a
  7. Reboot and test package installation

    • Restart your system:
      sudo reboot
    • After reboot, test with:
      sudo apt update
    • If that works, the interruption issue is resolved.

Fix It Automatically with Kudu

If you are recovering from a failed Linux setup, dual-boot issue, or package problem caused by low disk space, Kudu can help by cleaning temporary clutter, cache files, and other junk that may be getting in the way. It gives you a quick way to free up space and remove unnecessary files so recovery steps like apt and dpkg have a better chance of completing cleanly.

Download Kudu Free →

Fix this automatically with Kudu

Run a free system scan to detect and resolve this issue automatically — no manual steps required.

Download Kudu Free →