I have a script that backs up sql databases and runs as a cron job which I'd like to add to my NAS to back up a few of the databases I use / run regularly.
Is there a n00bs FAQ on adding cron jobs anywhere?
(or is there an alternative method for regularly backing up sql databases?)
Thanks-
Cron Job Script
-
- Posts: 79
- youtube meble na wymiar Warszawa
- Joined: Mon Nov 18, 2013 6:59 pm
-
- Posts: 476
- Joined: Wed Mar 13, 2013 5:38 am
Re: Cron Job Script
my scripts are in http://forum.asustor.com/viewtopic.php? ... ilit=mysql crontab works as normal when you ssh to the server and run crontab -e
for me i use
# backup prep
10 1 * * * /volume1/misc/mysqlbackup.sh
for me i use
# backup prep
10 1 * * * /volume1/misc/mysqlbackup.sh
608t
-
- Posts: 79
- Joined: Mon Nov 18, 2013 6:59 pm
Re: Cron Job Script
Thanks.
I'd really like to use the script that I currently have as I know it, what it does, and so on.
Backs up databases, weekly, keeping record of the prior backup, etc.
I guess my biggest issue is where to put the script to run as a cron job, and having it execute weekly.
Thanks again- Appreciate the help.
Here is the script I'm using:
http://sourceforge.net/projects/automysqlbackup/
I'd really like to use the script that I currently have as I know it, what it does, and so on.
Backs up databases, weekly, keeping record of the prior backup, etc.
I guess my biggest issue is where to put the script to run as a cron job, and having it execute weekly.
Thanks again- Appreciate the help.
Here is the script I'm using:
http://sourceforge.net/projects/automysqlbackup/
-
- Posts: 476
- Joined: Wed Mar 13, 2013 5:38 am
Re: Cron Job Script
I created a share for scripts and other odds and sods called misc, thats where I keep mine. Then its just a matter of reading up on crontab and how to use vi. When you call crontab -e it brings up the crontab in vi and you can change and add as you see fit.
There are loads of help pages out there with better hints and tips on editing crontab and adding tasks than I could give you.
There are loads of help pages out there with better hints and tips on editing crontab and adding tasks than I could give you.
608t
-
- Posts: 79
- Joined: Mon Nov 18, 2013 6:59 pm
Re: Cron Job Script
Thank you Sir. I appreciate it.
I'l read up on crontab, and editing it to my liking in nano or vi.
I had attempted to add the script to the crontab folder, and got a permission denied.
I'll read up on crontab.
Again, appreciate the direction pointing.
I'l read up on crontab, and editing it to my liking in nano or vi.
I had attempted to add the script to the crontab folder, and got a permission denied.
I'll read up on crontab.
Again, appreciate the direction pointing.