Assuming you are running vbulletin upgrade in staging before production and that staging has a different domain name… Here are some useful tips:
I use chrome as the preferred browser when doing vbulletin upgrades. firefox is notorious for caching which might result in hours of debugging time.
1. Backup Database.
2. login to /admincp and put the site in maintenance mode, ie options -> turn vbulletin off
3. Export production db and update staging DB with that of production.
4. Deploy code changes to staging.
5. Run queries in staging,
// your staging homepage might be something like http://yoursite/forums
// update forum domain
mysql_query("UPDATE `setting` SET `value` = 'staging_forum_homepage' WHERE `varname` = 'bburl';");
mysql_query("UPDATE `setting` SET `value` = 'staging_forum_homepage' WHERE `varname` = 'homeurl';");
// update forum title
mysql_query("UPDATE `setting` SET `value` = 'Your Forums (Staging)' WHERE `varname` = 'bbtitle';");
// update links in posts
mysql_query("UPDATE post SET pagetext = REPLACE(pagetext,'production_forum_homepage', 'staging_forum_homepage');");
6. In staging,
copy do_not_upload/tools.php (found in do_not_upload folder) to forums_root/admincp
click on “reset cookie domain”
remove tools.php in forum_root/admincp after that
login to admincp -> settings -> options -> Site name /URL/Contact Details. Change all options to reflect the staging url.
7. Now is the crucial part: If you are running multiple servers in load balancing environment, change your host file to point to just one server. Then go to forum_root/install/upgrade.php and enter the customer number from vbulletin. Then upgrade. If this doesn’t work for whatever reason, backup plan: run the upgrade from command line, ie cd forum_root/install/;php -f upgrade.php. After that, run the upgrade from the web again.
8. In admincp, to upload new styles, templates -> upload styles -> select “create a new style” and “ignore style version”
9. In To switch styles, options -> style and language -> choose style. Verify the changes in the homepage.
10. To upload new plugins or products, manage product -> add/import product -> upload plugin -> set “allow overwrite” to yes.
11. Go back to admincp control panel and run post upgrade instructions.
12. Turn maintenance mode off.
13. Get people to test the website.
To deploy to production, go thru steps 1, 3, 6, 7, 8, 9, 10 and 11 again
other tips: time the upgrade process. Document the upgrading steps on a piece of paper.