Living with Lucid: 8.04 to 10.04 migration problems: Flash strikes again

I have now begun upgrading my 100+ installations of Ubuntu 8.04 to 10.04 at work.  It should come as no big surprise that the first problem worth mentioning is Flash.

In particular, the flashplugin-nonfree package from 8.04 to 10.04 can leave apt in an unpleasant state.  The solution, found here, is to run the following:

sudo rm /var/lib/dpkg/info/flashplugin-nonfree.prerm
sudo dpkg --remove --force-remove-reinstreq flashplugin-nonfree
sudo dpkg --purge --force-remove-reinstreq flashplugin-nonfree

I ran this after seeing errors on upgrade like the following:

Preconfiguring packages …
dpkg: error processing flashplugin-nonfree (–remove):
Package is in a very bad inconsistent state – you should
reinstall it before attempting a removal.
Errors were encountered while processing:
E: Sub-process /usr/bin/dpkg returned an error code (1)

I tried the usuals: apt-get remove, apt-get remove –purge apt-get install flashplugin-nonfree –reinstall, dpkg -r –force-all flashplugin-nonfree, none worked.  Thankfully, the above worked a treat.

%d bloggers like this: