2

If I want to install a program by:

sudo apt-get install package_name

I always get the error:

E: Could not open lock file /var/lib/apt/lists/lock - open (2 No such file or directory)
E: Unable to lock the administration directory (/var/lib/dpkg) , are you root?

I am root, but still get the error. Any idea ?

Jacob Vlijm
  • 83,767

1 Answers1

1

Start a terminal by pressing Ctrl + Alt + T on keyboard, copy this following to Terminal window

sudo cp /var/backups/dpkg.status.0 /var/lib/dpkg/status
sudo apt-get update

Or for more detail you can read here

Liso
  • 15,377
  • 3
  • 51
  • 80