0

Is it that i am missing cretin functions that Debian had, this is just Ubuntu on a 64 bit Intel processor when running any apt scrip like an sudo apt-get install

$ sudo apt-get install python-setuptools python-virtualenv python-dev

E: Malformed line 2 in source list /etc/apt/sources.list.d/100-ubnt-unifi.list (type) E: The list of sources could not be read. E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable) E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?

I had this same problem with my ARM processor and the dpkg files but it was different. what going on because because i am not sure if it just missing something about the Debian interface or maybe some bash scripting but i would like to know .

i saw that the fix isnt hard but last time i did a fix from what i saw cold be done i lost the ability to go on youtube. but that just might be the internet i have that allows me to surch for the answer. i cant really connect to the wifi, i need an inscription key. it on the wifi box but i not sure where it is located in the house and i am not quite sure if i need it. im leaving soon, nut im just looking for a apt-get fix for any other insulation of any 64 bit programs to run like virtual box.

--update--

i already did something to where the text editor doesnt come up the same but you are supposed to put these command first.

sudo cp /etc/apt/source.list /etc/apt/source.list.old

sudo cat -n /etc/apt/source.list | grep 2

sudo gedit /etc/apt/source.list

on the second command right where it says "grep 2" you are supposed to put the number of lines you have that are malformed into the command. and i believe you are supposed to put a number sine where the link starts in the test editor followed but a space and then hit save. on your terminal it should say something like this..

$ sudo gedit /etc/apt/source.list

** (gedit:3452): WARNING **: 21:16:30.900: Set document metadata failed: Setting attribute metadata::gedit-position not supported

once it does that exit out of text editor and start a new terminal and start a apt-update && upgrade to see if you can source code an update. but beacuse i fail to put in the right code at the right time i was wondering if i could just copy and past what it should look like in the text editor and save after i put in a

$ sudo gedit /etc/apt/source.list

after the command or maybe i should just uninstall and reinstall the OS to see if i can fix my issue.

$ sudo cp /etc/apt/source.list /etc/apt/source.list.old cp: cannot stat '/etc/apt/source.list': No such file or directory

$ sudo cat -n /etc/apt/source.list | grep 2 cat: /etc/apt/source.list: No such file or directory

$ sudo gedit /etc/apt/source.list

right
  • 11
  • There is an error in line 2 of the file mentioned. A user with sudo rights has made the error; that directory is empty on new installs, so it's been added by a user with sudo rights. Correct the error. You've also listed other errors, for other causes. If the system is upgrading at the same time you enter a command to, the lock file prevents damage by only allowing one update at a time to occur. It can also be user-error, ie. an update in one window waiting a response, the user forgets, and then starts another update (which ends up waiting until first is answered & completed). Check – guiverc Nov 27 '20 at 03:59
  • Welcome to AskUbuntu! Please don't revert the improvements people with experience on this site is doing to your post. – Pablo Bianchi Nov 27 '20 at 04:02
  • Use sudo nano /etc/apt/source.list instead of sudo gedit /etc/apt/source.list This will remove the ** (gedit:3452): WARNING **: 21:16:30.900: Set document metadata failed: Setting attribute metadata::gedit-position not supported error. – karel Nov 30 '20 at 06:12
  • source.list doesn't exist by default. Did you mean sources.list? Anyway you have errors in /etc/apt/sources.list.d/100-ubnt-unifi.list. Why are you editing sources.list? – Kulfy Nov 30 '20 at 06:43

1 Answers1

2

Read the error messages.

The first one tells you which file, and which line has the error. Fix that error.

The second error was caused by the first error, and will probably go away when you fix the first error.

The third and fourth error messages indicate a different problem.

Either you're running a package installer program in a different terminal, or as a detached process, or you killed an installer process so rudely that it didn't release the look.

You can see if any current process has the lock file open by

sudo lsof /var/lib/dpkg/lock-frontend

If a process has the file open, consider killing it.

If no process is shown, simply remove the file.

sudo rm /var/lib/dpkg/lock-frontend

If rm can't find the file, the process that had the file open ("holding the lock") has released the lock and exited. This is the temporally unavalible part of the messages.

waltinator
  • 36,399
  • is the lock you mentioned similar to semaphores and mutex locks in OS? Which allows only one process to be installed at a time – Abhay Patil Nov 27 '20 at 04:19
  • 1
    sometimes it says removing the lock is not a solution – NinePlusTenEqualsTwentyOne Nov 27 '20 at 04:27
  • @AbhayPatil Similar but different. See https://stackoverflow.com/a/2332868 – Kulfy Nov 27 '20 at 04:37
  • i mean this is cool in all bit i already have super user and i saw some post on you tube about how it just missing the hash sine in the 2nd place but most of the videos are missing that one symbol in the 57 position and im just the second so im not quite sure if i should put the number followed buy a space in front of all the debian web links or the second because he went all the way to the bottom of the text editor instead of the top. – right Nov 30 '20 at 02:39