Faruque Ahmed : MCP, MCSA, MCSE, MCTS, MCIT, CCNA, OCA, OCP, GCP
$ ps aux | grep -i apt
$ sudo kill -9 <PID>
$ sudo killall program_name
sudo killall apt apt-get
If none of the above works, remove the lock files. Run in terminal: (Note that this can seriously break your system.)
sudo rm /var/lib/apt/lists/lock
sudo rm /var/cache/apt/archives/lock
sudo rm /var/lib/dpkg/lock*
sudo rm -v /var/lib/dpkg/lock-frontend
then reconfigure the packages. Run in terminal:
sudo dpkg --configure -a
OR
apt install -f
and
sudo apt update
------------------------------------