RepairMyOS
live db
user@ubuntu:~$ journalctl -xe | grep "Sub-process /usr/bin/dpkg returned an error code (1)"
Info

Sub-process /usr/bin/dpkg returned an error code (1)_

Sub-process /usr/bin/dpkg returned an error code (1)

Ubuntu · Linux/APT

Seeing Sub-process /usr/bin/dpkg returned an error code (1) on Ubuntu means the OS detected "Sub-process /usr/bin/dpkg returned an error code (1)". Before reinstalling anything, work through the steps below — the fix is often simpler than it looks.

What Actually Happened

Package manager encountered: a package's post-install script failed, which is often visible a few lines above this summary message.

Symptoms

APT command failed: 'Sub-process /usr/bin/dpkg returned an error code (1)'

Common Causes

  • Package state: a package's post-install script failed, which is often visible a few lines above this summary message

How to Fix It

  1. 01
    Refresh package index:
    sudo apt update
  2. 02
    Fix broken dependencies:
    sudo apt --fix-broken install
  3. 03
    Configure pending packages:
    sudo dpkg --configure -a
⚡ INSTANT REFERENCE KIT

System Administrator Emergency Kit

Stop searching for syntax under pressure. Get 100+ verified, battle-tested emergency recovery commands for Windows & Linux in one printable PDF guide.

Root Cause Breakdown

dpkg/APT constraint resolver aborted transaction.

Should You Worry?

Safe. Package manager halts to prevent further corruption.

Power-User Tip

Always run sudo apt update before attempting repair commands.

Estimated Fix Cost USD
$0 $0

Always free