Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I can't re-install packages that fulfill at least one of the following criteria:

  • Custom-made packages
  • Packages created by alien package (e.g. alien --install pkg.rpm)
  • Packages installed from some repository that is no longer available
  • Packages installed from some repository, but is no longer available there
  • Packages whose repositories have been removed from "/etc/apt/sources.list"

How do I list any of these packages?

share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

Aptitude lists them under “Obsolete and Locally Created Packages”. The corresponding search pattern is ?obsolete or ~o.

aptitude search '?obsolete'
share|improve this answer
add comment

You should be able to list packages installed via alien just by running rpm -qa.

For Debian packages, maybe some combination of apt-cache policy and apt-get autoclean can help?

   autoclean
       Like clean, autoclean clears out the local repository of retrieved
       package files. The difference is that it only removes package files
       that can no longer be downloaded, and are largely useless.
share|improve this answer
    
autoclean doesn't work as advertised; I guess I must file a bug –  Tshepang Feb 7 '11 at 11:51
    
Does it work after doing apt-get update? –  Mikel Feb 7 '11 at 11:52
    
The command rpm -qa doesn't return anything, even though I have packages installed via alien; Has it worked for you before? –  Tshepang Feb 7 '11 at 11:52
    
Yes, I did an update. –  Tshepang Feb 7 '11 at 11:53
    
I'm not sure. It would make sense if it worked, but I don't have any packages installed using alien that I can test with. –  Mikel Feb 7 '11 at 11:53
show 3 more comments

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.