Fix for Flash plugin crashing on Ubuntu karmic & lucid

I've had a few problems over recent weeks on both Ubuntu karmic (9.10) and lucid (10.04) whereby web pages built on Flash player (such as ABC iView) would display a large error screen proclaiming that Flash player had crashed. I first saw it on my son's ThinkPad X31 which i had upgraded to lucid very shortly after it was released, and assumed that it was just part and parcel of the new release, and that the bug would be fixed shortly. I was surprised when i found this week that it had come up on my other son's ThinkPad T43, which is still running karmic. I also found that some user accounts on the laptop were affected, and others were not. This led me to do some more investigating.

Packaging of the Flash plugin on Ubuntu has changed names several times in Ubuntu over the last few years, but things seem to be relatively stable at the moment, with the package "adobe-flashplugin" being available from the Canonical partner repository (you can enable this in System -> Administration -> Software Sources -> Other Software). On the affected systems, i found some old versions of the plugin hanging around in ~/.mozilla/plugins" from the days when the packaging was different, which explained the differing results for different users. I also found that the cache and preferences were stored in different locations (~/.adobe/Flash_Player and ~/.macromedia/Flash_Player/).

The steps i followed to get Flash working again were:

  1. Shut down all running copies of Firefox
  2. Remove old versions of the plugin: rm -rf /home/*/.mozilla/plugins/*flash*
  3. Remove the cache and preferences: rm -rf /home/*/.{adobe,macromedia}/Flash_Player
  4. Install or reinstall adobe-flashplayer from Canonical's partner repository. I usually use the command-line tools to do this (aptitude install/reinstall adobe-flashplugin), but Ubuntu Software Centre and Synaptic Package Manager should work equally well, provided you have the partner repository enabled.

This problem seems most likely to affect systems which have been upgraded from jaunty or earlier.