Jump to content

Can’t install packages in Linux

I am very new to Linux and am trying to install the Python package, but I keep getting into an infinite loop of “Waiting for cache lock: Could not get lock /var/lib/dpkg/lock-front end. It is held by process 3792 (apt)” The command I was trying to use was “sudo apt install python” am I doing something wrong? P.S. This is also happening with Java JDK installer, the command I was using for that one was “sudo apt install oracle-java14-installer” I am using Linux Mint 20 if it helps.

Link to comment
Share on other sites

Link to post
Share on other sites

Seems like you're trying to install multiple things at once. Either kill 3792 or just reboot your system.

Quote me to see my reply!

SPECS:

CPU: Ryzen 7 3700X Motherboard: MSI B450-A Pro Max RAM: 32GB I forget GPU: MSI Vega 56 Storage: 256GB NVMe boot, 512GB Samsung 850 Pro, 1TB WD Blue SSD, 1TB WD Blue HDD PSU: Inwin P85 850w Case: Fractal Design Define C Cooling: Stock for CPU, be quiet! case fans, Morpheus Vega w/ be quiet! Pure Wings 2 for GPU Monitor: 3x Thinkvision P24Q on a Steelcase Eyesite triple monitor stand Mouse: Logitech MX Master 3 Keyboard: Focus FK-9000 (heavily modded) Mousepad: Aliexpress cat special Headphones:  Sennheiser HD598SE and Sony Linkbuds

 

🏳️‍🌈

Link to comment
Share on other sites

Link to post
Share on other sites

31 minutes ago, Stlerfn said:

“Waiting for cache lock: Could not get lock /var/lib/dpkg/lock-front end. It is held by process 3792 (apt)” The command I was trying to use was “sudo apt install python” am I doing something wrong?

It sounds like some other installation/update process is already running. "apt" is (on possible) package manager for Ubuntu. So either wait until it is done, kill it or reboot.

 

You can install multiple things with a single command e.g. "apt-get install <a> <b> <c>", but you can't run "apt-get install <a>" in one terminal and "apt-get install <b>" in another terminal at the same time.

Remember to either quote or @mention others, so they are notified of your reply

Link to comment
Share on other sites

Link to post
Share on other sites

42 minutes ago, Stlerfn said:

I am very new to Linux and am trying to install the Python package, but I keep getting into an infinite loop of “Waiting for cache lock: Could not get lock /var/lib/dpkg/lock-front end. It is held by process 3792 (apt)” The command I was trying to use was “sudo apt install python” am I doing something wrong? P.S. This is also happening with Java JDK installer, the command I was using for that one was “sudo apt install oracle-java14-installer” I am using Linux Mint 20 if it helps.

Like others said, apt is already in use. Ubuntu periodically updates package-lists and installs security-updates and since Linux Mint is based on Ubuntu, that might be what's going on.

Hand, n. A singular instrument worn at the end of the human arm and commonly thrust into somebody’s pocket.

Link to comment
Share on other sites

Link to post
Share on other sites

Do NOT kill it, just wait 15 minutes and try again. Ubuntu based distros will silently auto check for updates in the background and while that's going you can't use apt.

F@H
Desktop: i9-13900K, ASUS Z790-E, 64GB DDR5-6000 CL36, RTX3080, 2TB MP600 Pro XT, 2TB SX8200Pro, 2x16TB Ironwolf RAID0, Corsair HX1200, Antec Vortex 360 AIO, Thermaltake Versa H25 TG, Samsung 4K curved 49" TV, 23" secondary, Mountain Everest Max

Mobile SFF rig: i9-9900K, Noctua NH-L9i, Asrock Z390 Phantom ITX-AC, 32GB, GTX1070, 2x1TB SX8200Pro RAID0, 2x5TB 2.5" HDD RAID0, Athena 500W Flex (Noctua fan), Custom 4.7l 3D printed case

 

Asus Zenbook UM325UA, Ryzen 7 5700u, 16GB, 1TB, OLED

 

GPD Win 2

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×