Categories: debianUbuntu

[SOLVED] E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it?

You get the following error message while installing a .deb package on Debian or Ubuntu or while installing Updates?

E: Could not get lock /var/lib/dpkg/lock – open (11: Resource temporarily unavailable)
E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it?

This error means that there is already an apt process running or the apt process dies and left his lock file.

Solution

First, you should wait a few minutes to ensure that the lock has not been set by the automatic update job (in case you enabled automatic updates on your system). If you just run an apt command and this command ended abruptly e.g. due to a disconnect of your SSH session, then there is no need to wait.

When the same error still shows up after you waited some time, then it’s time to fix the issue by removing the stale apt lock file.

Run this command to remove the lock file:

sudo rm -f /var/lib/dpkg/lock

Now you should be able to run the original apt command successfully.

The post [SOLVED] E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it? appeared first on FAQforge.

Ubuntu Server Admin

Recent Posts

Canonical announces Ubuntu support for the NVIDIA Rubin platform

Official Ubuntu support for the NVIDIA Rubin platform, including the NVIDIA Vera Rubin NVL72 rack-scale…

14 hours ago

Meet Canonical at CES 2026: A trusted foundation for your device lifecycle

CES 2026 is here, bringing together the technologies defining the next generation of connected devices.…

2 days ago

🚀 Deploy Elastic Stack on Ubuntu VPS (5 Minute Quick-Start Guide)

Here’s the guide to deploy Elastic Stack on Ubuntu VPS, with secure access, HTTPS proxying,…

6 days ago

🚀 Deploy Nagios on Ubuntu VPS

This guide walks through deploying Nagios Core on an Ubuntu VPS, from system prep to…

6 days ago

Shoryuken Has a New Maintainer, and v7.0.0 Is Almost There

After a decade under Pablo Cantero's stewardship, Shoryuken has a new maintainer - me. I'm…

1 week ago

A better way to provision NVIDIA BlueField DPUs at scale with MAAS

MAAS 3.7 has been officially released and it includes a bunch of cool new features.…

3 weeks ago