Jump to content

CronJob Backup to Email


albinoazn

Recommended Posts

I am a complete noob when it comes to php. I'm also a complete noob when it comes to MySQL. I do know a little of the basics, just enough to piss me off. [img src=\"style_emoticons/[#EMO_DIR#]/laugh.gif\" style=\"vertical-align:middle\" emoid=\":laugh:\" border=\"0\" alt=\"laugh.gif\" /] .

What I'm wanting to do is make a script that makes a backup of an entire database once every week, and then the script automatically sends it to my email address. I have been told to use cronjobs, but then never got any support. I have no idea what cronjobs is, and would love to have someone help me out.

Sorry if this is in the wrong place, but I wasn't sure.

Thank you,
Jake Moore / albinoAZN
Link to comment
Share on other sites

[!--quoteo(post=373778:date=May 14 2006, 12:58 PM:name=albinoAZN)--][div class=\'quotetop\']QUOTE(albinoAZN @ May 14 2006, 12:58 PM) [snapback]373778[/snapback][/div][div class=\'quotemain\'][!--quotec--]
I am a complete noob when it comes to php. I'm also a complete noob when it comes to MySQL. I do know a little of the basics, just enough to piss me off. [img src=\"style_emoticons/[#EMO_DIR#]/laugh.gif\" style=\"vertical-align:middle\" emoid=\":laugh:\" border=\"0\" alt=\"laugh.gif\" /] .

What I'm wanting to do is make a script that makes a backup of an entire database once every week, and then the script automatically sends it to my email address. I have been told to use cronjobs, but then never got any support. I have no idea what cronjobs is, and would love to have someone help me out.

Sorry if this is in the wrong place, but I wasn't sure.

Thank you,
Jake Moore / albinoAZN
[/quote]

cron is the scheduling demon in *nix. Using cron, you can execute shell commands at different intervals throughout the day. To do your backup, you could write a script, or program for that matter, and have the cron demon execute it every friday night if you wanted it to. [a href=\"http://www.htmlcenter.com/tutorials/tutorials.cfm/155/PHP/\" target=\"_blank\"]This link[/a] (htmlcenter.com) gives examples on how to create cron jobs. Most website control panels have plugins that allow you to create cron jobs. If you have shell access, you can create cronjobs from the shell.
Link to comment
Share on other sites

Yea, The cPanel has an a CronJob section, but at the moment, I am unable to get to my cPanel, My host is talking to the guys who own his server.

I was wondering if there was anyway to just have a script/program that can do it on it's own.
Link to comment
Share on other sites

In terms of having a script execute itsself at a certain time, your probably better off to wait and setup the cronjob. Have you thought about scheduling a task on your PC to execute the script on your server?
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.