News:

Wondering if this will always be free?  See why free is better.

Main Menu

Backup. Database or Files?

Started by Stanyy, January 22, 2012, 01:28:28 PM

Previous topic - Next topic

Stanyy

Hi SimpleMachines, i would like to confirm something thats a bit confusing to me... If i backup my database from the Admin control area, and then i install a mod which crashes my forum, would restoring the database remove the mod or do i have to backup my files as well?

Herman's Mixen

just use the large upgrade package to restore the original files no need for restoring the database ;)

if you make backups of your database use your webhost control panel --> phpmyadmin feature to backup/restore.
Met vriendelijke groet, The Burglar!

 House Mixes | Mixcloud | Any Intelligent fool can make things bigger, more complex, and more violent.
It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Albert Einstein

Former Godfather of our dutch community ;)

Stanyy

Thanks for posting a reply but that did not answer my question... I installed a mod in a test forum and it killed the forum (all the pages are blank. I cant see anything). My question is.. if i had saved a backup of the database, will restoring the database remove the mod?

Illori

no restoring the database will not remove the mod, but you can take a look at Installed a mod? Broke your forum? No backup? This might help.

Herman's Mixen

restore a database will not remove a mod, the original files will do that, that is why i refer to the large upgrade package ;)
Met vriendelijke groet, The Burglar!

 House Mixes | Mixcloud | Any Intelligent fool can make things bigger, more complex, and more violent.
It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Albert Einstein

Former Godfather of our dutch community ;)

Stanyy

Thanks Illori that was what i needed. But what if i did multiple file edits and something goes wrong and i cant remember what files i edited? Will restoring the database undo those or would i have to save all my files somewhere in case?

Stanyy

Quote from: The Burglar! on January 22, 2012, 01:54:52 PM
restore a database will not remove a mod, the original files will do that, that is why i refer to the large upgrade package ;)
The original files? The original 'fresh' files? :/

Illori

you dont need to touch the database at all, you just need to use that package from the backup folder or the large upgrade package.

MrPhil

Don't use the "admin" backup. It is very unreliable. Use phpMyAdmin or similar tools to back up your database. You will need to know how to use them anyway in order to do a restore (SMF admin can't do a restore).

Database backup and file backup are two entirely separate things. They should preferably be done together so that you have consistency between your files and the database upon a restore. Some mods may change the database structure and content, but most don't.

Installing (unzipping from "large upgrade") a fresh set of files will wipe out any mods you have installed. You will need to re-install your mods. Be careful if any of your mods also change your database, as the mod installation may attempt to change your database again, leading to errors. Such mods may have to be (re-)installed manually, leaving out the database changes.

Stanyy

Thank you so much Mr.Phil for your reply it really explained a lot. Thank you Illori for explaining the purpose of that backup folder.
But please guys i have made mistakes in the past because of not understanding the 'hows', 'whats' 'whys' and 'when' to save or restore backups. I really have a lot of questions to ask on this subject thats why i would like you guys to please stay with me on this one.

1. Okay first, concerning the ''large upgrade'', what if i decide to reinstall Smf the normal way, will that still do it? Whats the difference between the normal files and the ''large upgrade'' files

2. Still concerning the large upgrade method. Assuming the mod made changes to the database, what then?

Case A. (This really happened) I installed a mod in a forum and it somehow deleted all my files, how do i get my forum back assuming i had saved a backup of my database?

Case B. (Assumption) I installed a mod that made changes to both database and files but this mod does not allow me access my admin panel. Will Illori's ''backup folder'' method work?

I just want to know the importance of saving my files.

Illori

the large upgrade package has all the files needed, the install package has all files needed for an install. the large upgrade package will not touch the parts that the mods changed in the database.

blackshoe

I'm a newb at SMF, too, but long ago in another life I was a mainframe database administrator. I think the answers to your questions, Stan, are these:

1. Routinely backup your forum software and database frequently. I do mine once a week. If usage takes off, I'll switch to daily.
2. Backup your forum software before installing any mods.
3. If the mod you're installing changes the database, backup that too.
4. Save at least the last few backups of both the database and the forum software.
5. If you need to restore both the software and the database, make sure the backups of each are compatible with the other. If you're only restoring one, make sure the backup from which you're restoring is compatible with the part you aren't restoring.
6. The easiest way to do 5 is to always backup both the database and the forum software whenever you do a backup.

Aleksi "Lex" Kilpinen

In order to have full backups of everything, you would need to have backup copies of all files AND the whole database.

Most smaller mods only edit files, so for mod related trouble files are the best to have backups of - but it's always recommended that you have a backup of your DB as well.
Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

Advertisement: