I recently attempted to upgrade my Statusnet installation from 0.9.7. to the latest, 0.9.9. I followed the README’s “Upgrading” section, before bumping into this:
ERROR 1146 (42S02) at line 99: feedsub doesn't exist
It seems I’m not the only person to have misunderstood the Statusnet upgrade instructions. This post is largely a recap of everything mentioned in the linked article but I hope people will find this post when Googling “Upgrading Statusnet”. I have also submitted patches for the issues encountered below in the hopes that I save others from similar problems.
Tip 1: Do not run rebuilddb.sh if you’re on version 0.9.x
It appears that rebuilddb.sh should only be run if you’re on versions older than 0.8 (e.g. 0.5, 0.6, 0.7).
Tip 2: Do not dump your database ($dbname) to /tmp/$dbname.sql
This is partly my own fault; for quick upgrades I usually MySQL dump my database to /tmp/$dbname.sql (e.g. /tmp/statusnet.sql). As it turns out the rebuilddb.sh script also backs up to this location. The issue is that rebuilddb.sh does not perform a default/vanilla MySQL dump (it uses the -t flag — do not CREATE tables).