vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Administrative and Maintenance Tools - vB Database Backup (https://vborg.vbsupport.ru/showthread.php?t=167276)

Paul M 02-17-2008 10:44 AM

If you have put /public_html/backups/ then it will be trying to look for that at the root of your server. Its usually best to use a relative path, like ../backups/

bollie 02-17-2008 11:31 AM

Automatic Database Backup for vB 3.7

An error occured during the Backup : Could not open Destination SQL file for writing.

Jase2 02-17-2008 12:54 PM

Thanks paul, that worked.

I clicked run now, and it's created the folder with .sql files for each table :):)

Although it didn't close my board when I opened it in a new tab.

Thank you very much!!!

Regards Jason :)

inteller2k7 02-17-2008 01:01 PM

Quote:

Originally Posted by bollie (Post 1445100)
Automatic Database Backup for vB 3.7

An error occured during the Backup : Could not open Destination SQL file for writing.

Provided the config file's destination path is correct, did you ch mod the backup folder to 777?

Jase2 02-17-2008 01:29 PM

H Paul, one more question:

What would I set the cron job to, so that it starts the backup, 4am every night (UK time)?

Regards Jason :)

bollie 02-17-2008 02:00 PM

Quote:

Originally Posted by inteller2k7 (Post 1445147)
Provided the config file's destination path is correct, did you ch mod the backup folder to 777?

Path is correct $backup['DUMP_PATH'] = '/var/www/vhosts/xxxxxxx/httpdocs/backupdat';

Folder mod to 777

Paul M 02-17-2008 06:21 PM

As I told the other member, try using a relative path, not the full path.

Jase2 02-17-2008 06:41 PM

What would I set the cron job to, so that it starts the backup, 4am every night (UK time)?

Regards Jason :)

Paul M 02-17-2008 07:12 PM

I dont understand what you mean, besides the obvious answer that you set it to run daily at 4am ....

Jase2 02-17-2008 07:15 PM

I edit "Automatic Database Backup for vB 3.7" under "scheduled Task Manger". Day of the week is set to *

Day of the month: *

Then do I set hour to 4 and minute to 0, so that it does it 4am UK time?

Regards Jason :)

maxicep 02-17-2008 07:20 PM

this support large databases tables ? because i tried some auto backup scripts but they didnt complete backup the database. My tables are so long .

SSH rlz :)

p.s: my database about 1gigabyte .

Jase2 02-17-2008 07:26 PM

If I remember rightly - it does.

Quote:

(Note: If you have an extremely large database, make sure to use the mysqldump binary option that is selected by default.)
Regards Jason :)

abroad 02-17-2008 07:52 PM

Get this error:
An error occured during the Backup : Could not open Destination SQL file for writing.

and tried it with

../backups/

and with

/home/xxx/yyy/backups/ (provided by filepath.php)

always the same error message

Paul M 02-17-2008 07:57 PM

Quote:

Originally Posted by Jase2 (Post 1445419)
I edit "Automatic Database Backup for vB 3.7" under "scheduled Task Manger". Day of the week is set to *

Day of the month: *

Then do I set hour to 4 and minute to 0, so that it does it 4am UK time?

Regards Jason :)

Yes.

Jase2 02-20-2008 04:05 PM

Hi Paul,

Is it a good idea to have it in a web accessible area? I have mine at public_html/backups ... and I don't think this is a good idea, as anyone can then download your backups .sql.

Where is it best to have it, and what path would it have?

Regards Jason :)

abroad 02-20-2008 04:13 PM

any idea why I get this:

An error occured during the Backup : Could not open Destination SQL file for writing.

and tried it with

../backups/

and with

/home/xxx/yyy/backups/ (provided by filepath.php)

always the same error message

Paul M 02-20-2008 06:21 PM

Quote:

Originally Posted by Jase2 (Post 1447446)
Is it a good idea to have it in a web accessible area? I have mine at public_html/backups ... and I don't think this is a good idea, as anyone can then download your backups .sql.

No, its not a very good idea and should be avoided if possible.

If you cant then at the very least you should use an htaccess file to stop people accessing the folder via the web.

Jase2 02-20-2008 08:29 PM

Yes, I've changed it too: /home/user/backups ... all looking good.

Once again, thanks for this great hack ;)

Regards Jason :)

avsunforum 02-24-2008 08:11 PM

thanks

gertoo 02-24-2008 08:23 PM

60MB database it didnt backup even 50% of the table. Yes i Did try with the "mysqldump binary option"

Paul M 02-24-2008 11:00 PM

Sorry but if it failed then the problem is local to you. My database is 10 times that size, and Ive tested on even bigger.

abroad 02-25-2008 03:36 AM

Does this work now or not? I was never able to make an update and upload the data to a new Database since I have this vbulletin. I always get SQL errors when I try to upload the database to a new one. I have also tried it according to the vbulletin manual. Anbody has some ideas?

Paul M 02-25-2008 01:08 PM

Quote:

Originally Posted by abroad (Post 1450441)
Does this work now or not?

Not really sure what you mean by that. This has worked since the day it was released - and runs my backups every night (and has done for a few years now).

abroad 02-25-2008 01:15 PM

cool...does the normal backup which comes with vbulletin work for big tables? It never worked for me even if I do it according to the manual...

Paul M 02-25-2008 01:29 PM

I cannot comment on the vb system, never used it.

snakeair 03-01-2008 02:13 AM

Very nice simple mod that work's great. "Clicks Installed"

connkid25 03-27-2008 12:50 AM

Just a quick question. I have this set to save as one file but when I save directly through the vbulletin backup that file is larger than the one this generates. I have run them both at the same time.

For instance.. On my test installation I get the following:

Directly through vbulletin: 6.20M

Through this script: 6.13M

What exactly is this leaving out? Just curious and wanted to make sure this is a true backup. This is pretty cool and very useful for those of us who always forget to backup!

TomJames 03-27-2008 01:26 AM

Quote:

Originally Posted by connkid25 (Post 1475502)
Just a quick question. I have this set to save as one file but when I save directly through the vbulletin backup that file is larger than the one this generates. I have run them both at the same time.

For instance.. On my test installation I get the following:

Directly through vbulletin: 6.20M

Through this script: 6.13M

What exactly is this leaving out? Just curious and wanted to make sure this is a true backup. This is pretty cool and very useful for those of us who always forget to backup!


I don't know for sure but my guess is that this might only be backing up vBulletin tables whilst the method built in will (by default) backup everything that has a table (plug-ins etc)

connkid25 03-27-2008 09:58 AM

Quote:

Originally Posted by TomJames (Post 1475519)
I don't know for sure but my guess is that this might only be backing up vBulletin tables whilst the method built in will (by default) backup everything that has a table (plug-ins etc)

I just installed a few mods from .org onto the test board and those tables were saved. The sql file sizes are still different though. I imported the sql from this mod into a new database and ran from that. Everything seems to be working so im not complaining! :)

Paul M 03-27-2008 03:11 PM

Different methods will produce files of different sizes, it depends on what comments are added and what method exactly is used.

connkid25 03-27-2008 03:30 PM

Thanks Paul. So as for the forum data, there is no data loss? I just get paranoid with this stuff so thats why im asking! =) I nominated this as MOTM since this can save all of us major headaches down the road. I never remember to backup!

Paradigm 03-27-2008 04:03 PM

How would I create a htaccess file to prevent people from accessing the backups from the web?

connkid25 03-27-2008 04:32 PM

Quote:

Originally Posted by Paradigm (Post 1475977)
How would I create a htaccess file to prevent people from accessing the backups from the web?

You should really save the backups outside of the web directory.

Jase2 03-27-2008 08:27 PM

Yes, you should.

I have mine at:

/home/user/backups

Regards Jason :)

Michael Biddle 03-28-2008 04:53 AM

Thanks Paul, will be installing this in the next few days.

Shawn Yue 03-29-2008 05:45 AM

This Is A Better Version

Thank Paul

Paradigm 03-31-2008 11:47 AM

Quote:

Originally Posted by connkid25 (Post 1475997)
You should really save the backups outside of the web directory.

I would love too but I couldn't get it working if it wasn't in the public_html directory. I'm not sure what the path name should be.

Paradigm 03-31-2008 11:59 AM

erm, nevermind. I figured it out. Working great now.

Jase2 04-01-2008 04:15 PM

Can you get this run every two nights at 4am? If so, what settings do you use?

Regards Jason :)

Paul M 04-01-2008 06:41 PM

It uses the VB cron system so you can [only] do anything that is capable of.


All times are GMT. The time now is 01:05 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01813 seconds
  • Memory Usage 1,813KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (10)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete