I seem to have gotten dpkg into an inconsistent state for the portmap package. I can't install it and I can't remove it either.
I have tried the following: apt-get install portmap apt-get -f install portmap apt-get remove portmap --purge apt-get install portmap --fix-missing Should I manually delete all the portmap files installed by dpkg? Below is the error messages: Thanks for any suggestions. Mark. # apt-get -f install Reading Package Lists... Done Building Dependency Tree... Done 0 packages upgraded, 0 newly installed, 0 to remove and 299 not upgraded. 7 packages not fully installed or removed. Need to get 0B/24.2kB of archives. After unpacking 0B will be used. (Reading database ... 90682 files and directories currently installed.) Preparing to replace portmap 5-2 (using .../archives/portmap_5-2_i386.deb) ... /var/lib/dpkg/info/portmap.prerm: /etc/init.d/portmap: No such file or directorydpkg: warning - old pre-removal script returned error exit status 1 dpkg - trying script from the new package instead ... /var/lib/dpkg/tmp.ci/prerm: /etc/init.d/portmap: No such file or directory dpkg: error processing /var/cache/apt/archives/portmap_5-2_i386.deb (--unpack): subprocess new pre-removal script returned error exit status 1 update-rc.d: /etc/init.d/portmap: file does not exist dpkg: error while cleaning up: subprocess post-installation script returned error exit status 1 Errors were encountered while processing: /var/cache/apt/archives/portmap_5-2_i386.deb E: Sub-process /usr/bin/dpkg returned an error code (1) # apt-get remove portmap --purge Reading Package Lists... Done Building Dependency Tree... Done The following packages will be REMOVED: portmap* 0 packages upgraded, 0 newly installed, 1 to remove and 299 not upgraded. 7 packages not fully installed or removed. Need to get 0B of archives. After unpacking 56.3kB will be freed. Do you want to continue? [Y/n] y dpkg: error processing portmap (--purge): Package is in a very bad inconsistent state - you should reinstall it before attempting a removal. Errors were encountered while processing: portmap E: Sub-process /usr/bin/dpkg returned an error code (1) -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]