Chromebook & Linux

Package manager errors: broken dependencies (apt/dnf)

Messages like 'unmet dependencies' or 'broken packages' mean an install was interrupted or two packages want conflicting versions of the same file. Most cases are fixed with built-in repair commands.

Difficulty
Intermediate
Time
10–45 minutes
DIY cost
$0
Pro cost
$60–$120

Symptoms

  • 'You have held broken packages' message
  • Install fails with dependency errors
  • 'dpkg was interrupted' warning
  • Can't install or update anything

Likely causes

  • CommonInterrupted install or updateClosing a terminal or losing power mid-install leaves the package database in a half-finished state.
  • CommonConflicting third-party repositoryAn added PPA or repo can require different versions of shared libraries.
  • PossibleMixing package managers or manual .deb/.rpm installsInstalling packages outside the normal system can create version conflicts.
  • PossibleOutdated package indexThe local list of available packages is stale and doesn't match the repository anymore.

What to do

  1. On Debian/Ubuntu, run 'sudo apt update' first to refresh the package index.
  2. Run 'sudo apt --fix-broken install' to let apt try to resolve and repair dependencies automatically.
  3. If dpkg was interrupted, run 'sudo dpkg --configure -a' to finish any half-installed packages.
  4. On Fedora/RHEL, run 'sudo dnf clean all' followed by 'sudo dnf distro-sync' to resolve conflicts.
  5. If a specific recently added repository is the cause, disable or remove it (delete its file from /etc/apt/sources.list.d/ or use 'sudo add-apt-repository --remove').
  6. Retry the original install or update once the fix commands complete without errors.
  7. As a last resort, note down key installed packages and consider a fresh OS reinstall if the system stays inconsistent.

Tools and parts

  • Terminal access with sudo privileges

When to call a pro

If fix-broken commands loop without resolving, a Linux support forum or professional can review your exact package list.

Safety

Generally low risk

Generally low risk for a careful person. Stop if anything looks different from what this guide describes.

Related guides

Operator provides AI-generated troubleshooting information. It can be wrong. For safety-critical, electrical, gas, structural, medical, automotive safety, or other high-risk problems, consult a qualified professional.