0

I got a Linux OS today. I was playing around the terminal, downloading some things that I find interesting, but I think I have run a command that messed the apt-get command. Whenever I try to install something, I receive an error message:

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

There are no processes updating anything, and I already tried to manually delete the lock files.

I was trying to use Wireshark and nmap, and there are some commands that I have run, and I believe that they are messing the lock files :

$ sudo usermod -a -G wireshark rafael

$ sudo chown root /usr/bin/dumpcap

I was not able to use Wireshark because of permission problems, so I tried to give it permission with these commands, obviously I got it on random forums on the internet (I'm a total newbie on the Linux commands)

How do I get the apt-get command running again ?

1 Answers1

0

You need to run apt with root privileges

sudo apt-get install <something>
sudo apt install <something> 

Do not mess with locked processes and files. Ubuntu Linux technology has advanced to a degree that there will probably never arise the need to remove such blocks.

Good luck.