Q . Ubuntu 16.04 update problem about third party repositories

@mit $ingh. asked, Mar 05 ' 2017

I use Ubuntu 16.04 and I get update problems after installing skype. When I try to install updates by using Software Updater, it stops and gives an

The package system is broken

error. And says:

Check if you are using third party repositories. If so disable them, since they are a common source of problems. Furthermore run the following command in a Terminal: apt-get install -f

I disable third party repositories and even remove mendeley from the list but the problem did not solved. I tried apt-get install -f command, it gives also problem and says:

E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?

How can I solve this problem?

  • ubuntu
  • apt-get

2 Answers

Execute the command as a root

sudo apt-get install -f

You need elevated privileges for the package manager.

The message is clear. Something went wrong and it's most likely because some non-Ubuntu repository in your system. You can disable them using many ways, but my favourite is:

sudo mv /etc/apt/sources.list.d/ /etc/apt/sources.list.d.bk/
sudo mkdir /etc/apt/sources.list.d/

Leave a Ansewer