Ubuntu software center blocking any new installation ?

Asked by lord-ralf-adolf

I tryed to install a package few days ago the package using the ubuntu software center and accidentaly forced reboot my PC after booting back to ubuntu I opened ubuntu software center and notice that there is one package being download but after 5 days he still downloading 0% so I tryed to cancel it but he still remain active the problème now I can't download or anstall any other package using apt-get or synaptics !!

My question : is there any thing I can do to force cancel the installation of a package ?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu software-center Edit question
Assignee:
No assignee Edit question
Solved by:
lord-ralf-adolf
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

What is the output of:

sudo apt-get update; sudo apt-get upgrade

Thanks

Revision history for this message
Warren Hill (warren-hill) said :
#2

What package and what version of Ubuntu?

Try killing the app or rebooting then open a terminal CTRL+ALT+T and try

-------------------------------------------------------------
sudo apt-get install -f

sudo dpkg --configure -a
-----------------------------------------------------------

Answer "Y" to let it try to fix any issues

If it does not work post the output back here

Revision history for this message
lord-ralf-adolf (rachidboudjelida) said :
#3

first thank you for the quick answer :)

here is the out put for "sudo apt-get install -f" and "apt-get-update"

[code]
E: Could not open lock file / var / lib / apt / lists / lock - open (13: Permission denied)
E: Unable to lock / var / lib / apt / lists /
E: Could not open lock file / var / lib / dpkg / lock - open (13: Permission denied)
E: Unable to lock the administration directory (/ var / lib / dpkg /). Do you have root privileges?
[/code]

and the out put for "sudo dpkg --configure -a"

[code]
dpkg: error: database dpkg status database is locked by another process
[/code]

Revision history for this message
Warren Hill (warren-hill) said :
#4

Follow the procedure here:

https://help.ubuntu.com/community/PackageManagerTroubleshootingProcedure

It may fix it for you. If not

at step 6 post the results back here instead of in a new question. That is don't the link given but this one instead

https://answers.launchpad.net/ubuntu/+source/software-center/+question/227219

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#5

sudo fuser -vki /var/lib/dpkg/lock;sudo dpkg --configure -a

Kill the process you find.

Revision history for this message
lord-ralf-adolf (rachidboudjelida) said :
#6

thank you problème resoleved !!

with actionparsnip's first commande then I had a probleme with sun-java-doc so I removed it to fix every thing then I used "Warren Hill"'s link just to be sure ;)

thank you guys