LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 12-01-2010, 07:09 PM   #1
cslucsm
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Rep: Reputation: 0
Cannot Install and remove package


Hi

I am using ubuntu 10.10. Recently I install a package named astah-community_6.3_all.deb. But It took very long time to complete installation. No error message display.So I canceled it. After that,
I cann't install or remove any software.I show the following error.

Code:
E: dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the problem.
So I try command 'dpkg --configure -a'.

After doing so, when I install or remove any package it show the following error.


Code:
E: The package astah-community needs to be reinstalled, but I can't find an archive for it.
If I tried to remove it, it show the following error


Code:
installArchives() failed: dpkg: error processing astah-community (--remove):
 Package is in a very bad inconsistent state - you should
 reinstall it before attempting a removal.
Errors were encountered while processing:
 astah-community
If I tried to to reinstall that package again, it no longer response.

How can I solve this problem? Plz Let Me Know.

Thanks.
 
Old 12-01-2010, 07:48 PM   #2
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 292Reputation: 292Reputation: 292
Quote:
Originally Posted by cslucsm View Post
So I try command 'dpkg --configure -a'.
Note: Be sure to use sudo when running dpkg --configure -a.
If that does not help, then try:
Code:
sudo dpkg --clear-avail && sudo apt-get update
Then see if you can update and install packages.
If that still does not work, then try:
Code:
sudo apt-get install -f
sudo dpkg --configure -a
sudo apt-get update
Sudo apt-get upgrade
In the future, stick with packages from the Ubuntu repositories and you will not have these problems.
 
Old 12-09-2010, 04:53 PM   #3
cslucsm
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Original Poster
Rep: Reputation: 0
I tried the following command.
Code:
sudo dpkg --clear-avail && sudo apt-get update
But a lot of file cannot be downloaded because of 404 error.

When I tried
Code:
sudo apt-get install -f
, it show the same error again
Code:
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: The package astah-community needs to be reinstalled, but I can't find an archive for it.
If you have any other idea, please let me know.
When I view astah-community package, in ubuntu software center, It show that it is installed but size on disk is 0 byte.
If I reinstall that package, it is no longer responding. How can I solve that problem?
 
Old 12-09-2010, 09:32 PM   #4
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 292Reputation: 292Reputation: 292
Quote:
Originally Posted by cslucsm View Post
I tried the following command.
sudo dpkg --clear-avail && sudo apt-get update
But a lot of file cannot be downloaded because of 404 error.
This is not the expected behavior.
Post your /etc/apt/sources.list file. Also post any files you have in your /etc/apt/sources.d/ directory.
If you have added any third party repositories to Ubuntu, then comment those out
(place a # in front of them) and try those commands again.
This is why I avoid third party repositories in Ubuntu.

Last edited by tommcd; 12-09-2010 at 09:35 PM.
 
Old 12-11-2010, 12:10 PM   #5
cslucsm
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Original Poster
Rep: Reputation: 0
The followings are the content of etc/apt/sources.list file
Code:
deb http://us.archive.ubuntu.com/ubuntu/ maverick main universe restricted
deb http://us.archive.ubuntu.com/ubuntu/ maverick-updates main universe restricted
deb http://security.ubuntu.com/ubuntu maverick-security main universe restricted
deb http://archive.ubuntu.com/ubuntu/ hoary-updates main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ hoary-updates main restricted universe multiverse
Many other lines are commented.

In the etc/apt/sources.list.d directory, there is only one file

Code:
google-chrome.list
What I have to do with them? plz guide me.

When I unchecked some software source from ubuntu software center, it request to reload package information. So I reload, but some files can not still downloaded.
They are
Code:
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/main/source/Sources.gz  404  Not Found
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/restricted/source/Sources.gz  404  Not Found
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/universe/source/Sources.gz  404  Not Found
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/multiverse/source/Sources.gz  404  Not Found
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/main/binary-i386/Packages.gz  404  Not Found
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/restricted/binary-i386/Packages.gz  404  Not Found
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/universe/binary-i386/Packages.gz  404  Not Found
Failed to fetch http://archive.ubuntu.com/ubuntu/dists/hoary-updates/multiverse/binary-i386/Packages.gz  404  Not Found
Some index files failed to download, they have been ignored, or old ones used instead.
It give me the same error

Code:
E: The package astah-community needs to be reinstalled, but I can't find an archive for it.
What is that problem?
 
Old 12-11-2010, 01:50 PM   #6
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 292Reputation: 292Reputation: 292
Quote:
Originally Posted by cslucsm View Post
The followings are the content of etc/apt/sources.list file

deb http://us.archive.ubuntu.com/ubuntu/ maverick main universe restricted
deb http://us.archive.ubuntu.com/ubuntu/ maverick-updates main universe restricted
deb http://security.ubuntu.com/ubuntu maverick-security main universe restricted
deb http://archive.ubuntu.com/ubuntu/ hoary-updates main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ hoary-updates main restricted universe multiverse

What is that problem?
You have repositories for both maverick and hoary in your sources.list. That is the problem!
How did this happen? You must have put the Hoary repos in there yourself.
Ubuntu Hoary reached end of life years ago, and it's repositories no longer exist. That is why you are getting those errors. Remove the Hoary repos and then run:
Code:
sudo apt-get update
sudo apt-get dist-upgrade
And see if you can then update your system. If you still get errors, then try running the commands I posted in post #2 of this thread again and see if that fixes things.
In the future, never mix repos from different versions of Ubuntu. This is a good way to wreck your system.

Last edited by tommcd; 12-11-2010 at 01:54 PM.
 
Old 12-12-2010, 08:01 AM   #7
cslucsm
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Original Poster
Rep: Reputation: 0
I tried what you want me to do. I can run apt-get update successfully.Everything is ok.
But apt-get dist-upgrade show me the same error
Code:
E: The package astah-community needs to be reinstalled, but I can't find an archive for it.
So I tried sudo dpkg --clear-avail && sudo apt-get update.
It can also run successfully.
But I cannot perform install, update, upgrade operations. The same error occurs.

One more things I would like to know you is that I installed astah-community package offline from .deb file. When I install it,it is no longer responding. So I closed ubuntu software center by force. I think that is why the system is in unstable state. After that I can't reinstall or remove that package and also any others. Although it is in installed package, it is no longer exit on disk and show me 0B in size.
 
Old 12-12-2010, 08:19 PM   #8
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 292Reputation: 292Reputation: 292
Quote:
Originally Posted by cslucsm View Post
I tried what you want me to do. I can run apt-get update successfully.Everything is ok.
But apt-get dist-upgrade show me the same error
Code:
E: The package astah-community needs to be reinstalled, but I can't find an archive for it.
So I tried sudo dpkg --clear-avail && sudo apt-get update.
It can also run successfully.
But I cannot perform install, update, upgrade operations. The same error occurs.
Did you try these commands:
Code:
sudo apt-get install -f
sudo dpkg --configure -a
sudo apt-get update
Sudo apt-get upgrade
If not then try that after removing the Hoary repo.
If that does not work, see this:
https://answers.launchpad.net/ubuntu/+question/14619
As it says there, try this:
Code:
sudo dpkg --purge --force-all astah-community
Or whatever exactly is the name of the package that is messed up.
If that does not work, then remove the entry for the package manually in the /var/lib/dpkg/status file as it says there.
I would first backup /var/lib/dpkg/status just in case something goes wrong.
Then see if you can upgrade the system.

Where did you get this astah-community package from? Why did you add the Hoary repo to your sources.list?

Last edited by tommcd; 12-12-2010 at 08:22 PM.
 
Old 12-13-2010, 12:18 PM   #9
cslucsm
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Original Poster
Rep: Reputation: 0
Thanks you very much, tommcd. Your help solve my problem. I am a newbie in ubuntu (linux) I don't exactly how package management system work. I want to use jude-community software which is a software design tool. So I search it for ubuntu. But jude-community is transformed to astah-community, I downloaded it from its official website http://astah.change-vision.com/en/pr...community.html. I downloaded astah-community.deb from these website. But It is not working. I download it in .zip file and manually extract it. But I don't have no chance to install or remove other software.

Now my system is working properly and I got a lot of knowledges about ubuntu software management, Thanks for your help.



I am sorry for my English.
 
Old 12-13-2010, 06:07 PM   #10
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,230

Rep: Reputation: 292Reputation: 292Reputation: 292
Quote:
Originally Posted by cslucsm View Post
Thanks you very much, tommcd. Your help solve my problem.
Glad we got this fixed! I was just about running out of ideas on this one.
So what was it exactly that fixed the problem?
Was it
Code:
sudo dpkg --purge --force-all astah-community
Or was it the
Code:
sudo apt-get install -f
Or did you manually remove the entry for astah in /var/lib/dpkg/status?
Please post back with how you fixed it. I am curious to know what solved the problem. Also, this may help others who run into similar problems.
 
Old 12-13-2010, 07:08 PM   #11
cslucsm
LQ Newbie
 
Registered: Sep 2010
Posts: 16

Original Poster
Rep: Reputation: 0
I really respect your willingness.
All I need is the command
Code:
sudo dpkg --purge --force-all astah-community
I think this command force to remove astah-community package that is in unstable state.
Thanks you very much.
 
Old 09-13-2011, 06:06 PM   #12
IsaacS
LQ Newbie
 
Registered: Sep 2011
Location: Mountain View, CA
Distribution: Ubuntu 10 & 11
Posts: 3

Rep: Reputation: Disabled
Btw for the sake of people who arrived at here seeking the specific software's problem (astah-community) like me, possible workaround is here: http://astah-users.change-vision.com...?topic_id=1358
 
Old 02-03-2017, 06:23 PM   #13
boontong72
LQ Newbie
 
Registered: Feb 2017
Posts: 3

Rep: Reputation: Disabled
Quote:
Originally Posted by cslucsm View Post
Hi

I am using ubuntu 10.10. Recently I install a package named astah-community_6.3_all.deb. But It took very long time to complete installation. No error message display.So I canceled it. After that,
I cann't install or remove any software.I show the following error.

Code:
E: dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the problem.
So I try command 'dpkg --configure -a'.

After doing so, when I install or remove any package it show the following error.


Code:
E: The package astah-community needs to be reinstalled, but I can't find an archive for it.
If I tried to remove it, it show the following error


Code:
installArchives() failed: dpkg: error processing astah-community (--remove):
 Package is in a very bad inconsistent state - you should
 reinstall it before attempting a removal.
Errors were encountered while processing:
 astah-community
If I tried to to reinstall that package again, it no longer response.

How can I solve this problem? Plz Let Me Know.

Thanks.

sudo dpkg --clear-avail && sudo apt-get update

then

apt --fix-broken install

Hope it helps.
 
Old 02-03-2017, 06:25 PM   #14
boontong72
LQ Newbie
 
Registered: Feb 2017
Posts: 3

Rep: Reputation: Disabled
sudo dpkg --clear-avail && sudo apt-get update

then

apt --fix-broken install

Hope it helps.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
failed to configure, remove and install package after cancelling configuration umarzuki Debian 4 10-09-2009 09:17 AM
Remove package ust Linux - Software 13 05-29-2009 05:27 AM
Remove a package raysr SUSE / openSUSE 3 03-22-2006 10:47 AM
Remove package maurovezz Mandriva 3 07-04-2005 07:57 PM
how to remove a package abd_bela Debian 6 05-14-2005 12:01 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 03:43 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration