Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I installed a .deb package and it did not get installed properly. Now, when I try to remove it by

sudo apt-get --purge remove <packagename>


sudo dpkg remove <packagename>

I get

E: The package <packagename> needs to be reinstalled, but I can't find an archive for it.

I also followed this article,


which seem to have solved a lot of people's problems(check comment) The link basically tell us to,

open cd /var/lib/dpkg/info

ls <packagename>

In my case, I check the shell scripts, i did not have /bash/sh -e , instead I had set -e.

I tried removing set -e (check comments, it had worked for people), but it does not work for me.

I also tried removing the package from /var/lib/dpkg/status and /var/lib/dpkg/status-old tried to run update and upgrade commands, Still it did not work.

Can someone help me out here also explain what is this issue. Seems like a lot of people are stuck on this issue for days.


share|improve this question
Did you manually download the deb file? –  saiarcot895 Jul 30 '14 at 14:32
Try first sudo dpkg --configure -a –  Pandya Jul 30 '14 at 14:40
Does not work. it returns exit status 1 again. –  jarvis11 Jul 30 '14 at 14:46
Found the solution. thanks –  jarvis11 Jul 30 '14 at 15:53
@jarvis11 please post the solution as an answer to your own question. If you found the solution in another answer, please give us the link to it. –  Alaa Ali Jul 30 '14 at 16:10

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.