Welcome, Guest. Please Login or Register.
March 15, 2025, 07:21:41 AM
Home Help Search Log in Register
News: SMF is the next generation in forum software, almost completely re-written from the ground up, make sure you don't fall for cheap imitations that suffer from feature bloat!

YaBB SE Community  |  Development  |  Completed mods  |  [BETA]Database Back-Up/Restore « previous next »
Pages: [1] 2 Reply Ignore Print
Author Topic: [BETA]Database Back-Up/Restore  (Read 3677 times)
Thunderace
Full Member
***
Posts: 211


I'm a llama!

[BETA]Database Back-Up/Restore
« on: December 22, 2002, 10:26:56 AM »
Reply with quote

This backs up your database "totally safe" but also restores (Be wary on a live DB)

When restoring the database needs to be fresh, i.e. free of tables due to the fact that it doesn't "drop" tables. (might add this later if required, and following more testing)

I do not accept responsibility for any problems caused by its use.

***Why do it?***

I know this has been done before but I've had endless problems trying to find a way to backup and restore my database. The backup programs on here and phpmyadmin  didn't work for me as it seemed not to backup all the tables (e.g mods & _topics) and wouldn't restore because of this and timeout/memory problems.

This mod gives two options in "Admin"

Restore Database
Back-Up Database

***Changes to mod file and one upload file***

This mod requires you to edit 2 files...the mod file and uploaddb.php (DB and URL/true path only)

Please make sure you back up english.lng, index.php and Sources/Admin.php

       ***After successful loading/modding please don't leave uploaddb.php in yabbse***

The restore Database feature (uploaddb.php) does not check for admin rights and can therefore be run via browser, you should upload this ONLY as and when you need to restore. (keep it on your desktop)

***Backup***
Creates a backup.sql file on your server (Without drop tables)

***Restore***
Restores your complete database

Note: I have excluded "drop tables" which means that to restore, the database needs to be totally fresh. (Newly set up DB)

Visual HERE

Download HERE

***Credits***
Original Backup Script by woodys
Restore Script by: -
Author:  Andrea Hubacher [email protected]

***Moderators***
If this is dangerous please remove and if there is a better option please redirect
« Last Edit: December 23, 2002, 10:52:40 PM by Thunderace » Logged
Tha Master
Full Member
***
Posts: 201


G€€N G€KL!€R, !K B€N H!€R

vermeulen_yves@hotmail.com WWW
Re:[BETA]Database Back-Up/Restore
« Reply #1 on: December 22, 2002, 03:12:37 PM »
Reply with quote

Anyone tested this already???
Logged

« Last Edit: Next Week at 23:59:59 pm by Tha Master »
_________________________________________________________________________________________________________
tha master was here ;)
http://www.forumekes.tk
Thunderace
Full Member
***
Posts: 211


I'm a llama!

Re:[BETA]Database Back-Up/Restore
« Reply #2 on: December 22, 2002, 03:15:01 PM »
Reply with quote

LOL  ;D
Logged
Thunderace
Full Member
***
Posts: 211


I'm a llama!

Re:[BETA]Database Back-Up/Restore
« Reply #3 on: December 22, 2002, 03:21:57 PM »
Reply with quote

Well if you back up english.lng, index.php and Admin.php

Then the boardmod will do no harm

The 2 uploaded files will do no harm

The backup will do no harm

The only thing to watch is the restore, Don't try to restore to a populated Database.

My advice is to set up an empty "test" database with different user and password, restore to that initially.
Logged
Dr_Michael
Sr. Member
****
Posts: 317


Hellenic web

WWW
Re:[BETA]Database Back-Up/Restore
« Reply #4 on: December 22, 2002, 09:59:42 PM »
Reply with quote

Anybody has tested it?  ???
Logged

Thunderace
Full Member
***
Posts: 211


I'm a llama!

Re:[BETA]Database Back-Up/Restore
« Reply #5 on: December 23, 2002, 12:51:00 AM »
Reply with quote

Just modded a fresh 1.4.1 and ran another backup/restore with no problems.

***Note for downloaders of the first mod***
You will need to take out the "is admin()" line from the top of uploadbd.php as with a blank database this doesn't work. Zip has been updated
« Last Edit: December 23, 2002, 08:41:11 AM by Thunderace » Logged
tdkyo
Noobie
*
Posts: 19


I'm a llama!

Re:[BETA]Database Back-Up/Restore
« Reply #6 on: December 23, 2002, 01:37:07 AM »
Reply with quote

This mod function is too important to test it. I am afraid it might screw up. :-\
Logged
Mr.Sins
Full Member
***
Posts: 113


BROOD WAR FOR LIFE

ICQ - 36721259cl.david@newmail.net WWW
Re:[BETA]Database Back-Up/Restore
« Reply #7 on: January 02, 2003, 07:59:30 AM »
Reply with quote

for people running theire own linux box and that want a graphical users interface for working with mysql

try http://www.webmin.com .

here you also have to functionality to backup your mysql db and add the drop db statement
Logged


David
Destroyer Dave
Global Moderator
YaBB God
*****
Posts: 5761


I'm not a llama!

WWW
Re:[BETA]Database Back-Up/Restore
« Reply #8 on: January 02, 2003, 08:29:20 AM »
Reply with quote

Quote from: Mr.Sins on January 02, 2003, 07:59:30 AMfor people running theire own linux box and that want a graphical users interface for working with mysql

try http://www.webmin.com .

here you also have to functionality to backup your mysql db and add the drop db statement
Why not just use phpMyAdmin which only does MySQL stuff and not all sorts of nix admin?
Logged

Mr.Sins
Full Member
***
Posts: 113


BROOD WAR FOR LIFE

ICQ - 36721259cl.david@newmail.net WWW
Re:[BETA]Database Back-Up/Restore
« Reply #9 on: January 02, 2003, 08:45:50 AM »
Reply with quote

webmin has a plugin for mysqladmin, for mysql noobs like me its mutch easier to have a graph interface through you msie.

a gui is mutch more self explainable then a cmdl.
Logged


David
Destroyer Dave
Global Moderator
YaBB God
*****
Posts: 5761


I'm not a llama!

WWW
Re:[BETA]Database Back-Up/Restore
« Reply #10 on: January 02, 2003, 08:58:19 AM »
Reply with quote

Have you ever looked at phpMyAdmin?

www.phpmyadmin.net

Here is a demo
http://www.phpmyadmin.net/phpMyAdmin/
Logged

Mr.Sins
Full Member
***
Posts: 113


BROOD WAR FOR LIFE

ICQ - 36721259cl.david@newmail.net WWW
Re:[BETA]Database Back-Up/Restore
« Reply #11 on: January 02, 2003, 09:04:15 AM »
Reply with quote

i didn't know them thx.

the php coded interface is mutch faster then that of webmin it uses cgi.

but like you probably already guessed, i uses webmin for more then only my mysql stuff.
Logged


Termite
Jr. Member
**
Posts: 54


Re:[BETA]Database Back-Up/Restore
« Reply #12 on: January 07, 2003, 01:54:27 PM »
Reply with quote

I installed this mod and I get an error when I try to backup.

QuoteAn Error Has Occurred!

2: fopen("/home/site/public_html/yabbse/backup/backup.sql", "w") - Permission denied
(/home/site/public_html/yabbse/Sources/mysqlbackup.h ln 24
Logged

Specs: FreeBSD 5.0-RELEASE #3, PHP Version 4.2.3, Apache/1.3.27, Mysql 3.23.54, YaBBSE 1.5.4
Termite
Jr. Member
**
Posts: 54


Re:[BETA]Database Back-Up/Restore
« Reply #13 on: January 07, 2003, 02:04:44 PM »
Reply with quote

i uploaded a blank file called backup.sql to the backup dir and that fixed the problem. backuping up the database was successful.

---

oh yeah. i think it would be a good idea if you implemented a function that gzips the backup.sql file :)
« Last Edit: January 07, 2003, 02:07:17 PM by Metal Termite » Logged

Specs: FreeBSD 5.0-RELEASE #3, PHP Version 4.2.3, Apache/1.3.27, Mysql 3.23.54, YaBBSE 1.5.4
Thunderace
Full Member
***
Posts: 211


I'm a llama!

Re:[BETA]Database Back-Up/Restore
« Reply #14 on: January 08, 2003, 11:52:33 AM »
Reply with quote

You might want to edit that post, it shows your path m8
Logged
Pages: [1] 2 Reply Ignore Print 
YaBB SE Community  |  Development  |  Completed mods  |  [BETA]Database Back-Up/Restore « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.032 seconds with 16 queries.