MyBB Community Forums

Full Version: Backup and restore
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I am trying to resurrect a hacked account but can't get to the Admin CP to run a backup (I can get to ModCP and UserCP but not AdminCP). I've got an old backup which contains much of what I need but it was made with MyBB 1.4 back in 2008. Can I run this against my new MyBB 1.6 installation or am I likely to hit problems because the database structure has changed between versions?

Thanks

David
If you want to use it on 1.6 files you'd need to run the upgrade script on it.
Sorry, I don't quite follow. Are you saying that there is a script that I can run on a backup file from MyBB 1.4 to convert it to a format suitable for MyBB 1.6?
Import it into a 1.4 setup then upgrade said setup to 1.6 is what Matt is meaning for you to do, I believe.
Get a backup from PhP Myadmin? Couldn't you just do that or run this SQL query?
UPDATE `mybb_users` SET `usergroup` = '4' WHERE `uid` = '1' 
It's just the standard MyBB upgrade procedure, the same way you'd upgrade any other 1.4 forum to 1.6: [Wiki: Upgrading] (Broken link, head over to docs.mybb.com instead)

But yes you'll still also need to sort out the admin access; if that query doesn't work (depends what's actually caused the loss of admin access), run these:

UPDATE `mybb_usergroups` SET `cancp` = '1' WHERE `gid` = '4';
DELETE FROM `mybb_datacache` WHERE `title` = 'usergroups';
Thanks for that - fresh MyBB 1.4 install, load data, upgrade db to MyBB 1.6, export data and re-load on my new server sounds like the right approach. I'm not sure what those SQL statements are doing for me though or at what point I should run them...
You said you didn't have access to the ACP and either mine or blake's queries will restore it; we don't know exactly what's caused the loss of admin access, but if you run all 3 of these actually it should give you admin access back.
The loss of admin access seems to be due to some hack on the server so that whatever php file is run in the admin folder, it always seems to display the hacked screen. I don't think that there is a problem with the database. I am suspecting that there is something more devious under the hood at the Linux security level rather than MyBB itself. I think I have verified this by loading back a valid index.php file to the admin folder (didn't work), renaming the file/folder (still didn't work by manually entering the URL for this) and trying to run another php file in the admin folder.

It's as if whatever is run in the admin folder forces the server to default back to the hack screen. However, you guys are more probably more knowledgeable than I about Linux hacking and how to prevent/fix. So, based on what I have just said, do you think your suggestions still might work? Would I stand to lose anything if I tried it and it didn't?
(2010-10-12, 10:22 PM)SteelD Wrote: [ -> ]The loss of admin access seems to be due to some hack on the server so that whatever php file is run in the admin folder, it always seems to display the hacked screen. I don't think that there is a problem with the database. I am suspecting that there is something more devious under the hood at the Linux security level rather than MyBB itself. I think I have verified this by loading back a valid index.php file to the admin folder (didn't work), renaming the file/folder (still didn't work by manually entering the URL for this) and trying to run another php file in the admin folder.

It's as if whatever is run in the admin folder forces the server to default back to the hack screen. However, you guys are more probably more knowledgeable than I about Linux hacking and how to prevent/fix. So, based on what I have just said, do you think your suggestions still might work? Would I stand to lose anything if I tried it and it didn't?

Just a quick query based on this. Have you checked for .htaccess files either in the admin directory or the mybb root? It may be that the hacker has simply edited a htaccess file.

If not, then all the above suggestions SHOULD work anyway Smile

Pages: 1 2