MyBB Community Forums

Full Version: Upgrade with only the mysql dump
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I am attempting to do an upgrade from 1.6.0 of mybb to the current version using only a mysql dump.

From what i was reading on the upgrade page you need to have the actual files in order to do the upgrade. As of right now i am unable to get these files. Is there a way to upgrade using only the current version installed, with the older mysql database? or would i need to do a install of 1.6.0 and then do a regular upgrade from there.
i would say almost certainly you would need to install 1.6.0 then import your backup before upgrading the site.
Hi welcome to MyBB mirthen:

(2012-04-19, 12:36 AM)mirthen Wrote: [ -> ]...From what i was reading on the upgrade page you need to have the actual files in order to do the upgrade....

You can do this, but need to be aware of several details.
1a) You need a "usable" inc/config.php file
1b) If you have an (already installed) test forum, then just copy the file and change the database details. Note: settings.php can be recreated (from Admin), so don't worry about that file.

2a) On a normal upgrade: You upload the new files before updating the database (with an upgrade.php script), so using the files for the newest MyBB is not a big problem**

2b) ** You need to upload your logo (and all related theme files) || Also be prepared to replace all the files related to all installed plugins.

3) ASAP run "install/update.php" so your DB is upgraded from 1.6.0 to the newest version.

Easy, if you don't have too many plugins. Toungue

ps. If you need a list of all installed plugins, just look in your 'mybb_datacache' table (Using phpmyadmin / after importing the DB)
does your sql dump include the table structures and create table queries?

if so, just import it into a new DB, then upload the latest MyBB files to your site, rename /inc/config.default.php to /inc/config.php and edit it.

Populate it with the contents as shown in http://wiki.mybb.com/index.php/Inc/config.php and change the DB settings at minimum to what the new DB you just uploaded is.

Then run the /install/upgrade.php script and select version 1.6.0 as the current version. It should be as simple as that to get your base forum running.

Then you need to figure out what plugins were active on your site and try to reinstall those. This is where you may run into issues, depending on how well the plugin was coded. See if the plugin made DB changes and it does not test for the changes before attempting to make them again, you will get errors.
If you first replace all the plugin files, then you can get by w/ no error messages.

(2012-04-20, 03:35 AM)pavemen Wrote: [ -> ]...you will get errors.

Yep, especially if you had a lot of plugins installed, then you could be chasing many errors.
(2012-04-20, 03:50 AM)seeker Wrote: [ -> ]If you first replace all the plugin files, then you can get by w/ no error messages.

(2012-04-20, 03:35 AM)pavemen Wrote: [ -> ]...you will get errors.

Yep, especially if you had a lot of plugins installed, then you could be chasing many errors.

but do you know what plugins you had installed? I can't recall all the plugins I have installed off the top of my head, let alone which ones are active versus inactive but installed. remembers, he has nothing but a sql dump.

you could look into the dump file for the datacache table and extract the list of active plugins, but you wont get the deactivated but installed plugins.
(2012-04-20, 04:46 AM)pavemen Wrote: [ -> ]...you could look into the dump file for the datacache table and extract the list of active plugins, but you wont get the deactivated but installed plugins.

True, thanks for catching that detail pavemen:
At that point (after dealing w/ the list of active plugins) the forum is updated and functioning; Now it's safe to use the ACP to look for deactivated but installed plugins. Toungue
Yeah i was going with no mods that were not included by default. I managed to get it working using a fresh install of mybb current version. i cleared the database for all mybb_ tables, then imported the mysql backup(which included structure). After that i ran the install script on mybb/install and ran through it fine.

Once that was done it was just a matter of updating a few options like the URLs and such for the forum. Thankfully it was a pretty basic default mybb setup i was restoring/migrating, default theme and everything. so went pretty smooth. Had some issues with cookies, as it was trying to use the old cookies and getting a bit mixed up with login/logout. fixed that by setting a custom cookie name for the new site.
Cookies might have just been stale in your browser; Glad you have it working now.