[svlug] Removing stubborn Debian package

Rick Moen rick at linuxmafia.com
Tue Mar 21 10:20:00 PST 2006

Quoting stripes (stripes at tigerlair.com):

> Since the maintainer of the nessus package says he doesn't maintain it
> (grr), I need to forcefully remove a package that doesn't want to go
> away.
> I have tried:
> # dpkg --remove --purge nessus
> # dpkg --remove --force-depends nessus
> # dpkg --remove --force-conflicts nessus
> And I always get the same thing:
> # dpkg -r --force-depends Nessus
> (Reading database ... 76294 files and directories currently installed.)
> Removing nessus ...
> dpkg: error processing nessus (--remove):
>  subprocess post-removal script returned error exit status 1
> Errors were encountered while processing:
>  nessus

Anne --

Script /var/lib/dpkg/info/nessus.postrm appears to encounter some sort of
error.  You might run it manually and see what's wrong (like, /var
mounted noexec ;->  ).  Sometimes, just commenting out most of the
script except its initial steps and the "exit 0" will do the trick.

The brute-force method (to be avoided except as a last resort) is to
make a safety copy of /var/lib/dpkg/status, then open that file in a
text editor, locate the stanza for package nessus (searching for
"Package: nessus"), remove it, and save.  This hits dpkg over the head
with a cudgel and makes it forget nessus was ever installed.

Cheers,       "What a pity [Standard Oil exec] H. H. Rogers's money is tainted."
Rick Moen                 -- some commentator of the day    "It's twice tainted:
rick at linuxmafia.com  'Tain't yours, and 'tain't mine."  -- Mark Twain, replying.

More information about the svlug mailing list