On Tue, May 21, 2013 at 1:51 PM, Saravanan Devasagayam
<[email protected]> wrote:
> I'm running Ubuntu 12.04 (32-bit) and have the following script in crontab
>
> SHELL=/bin/sh
> PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
>
> 40 13 * * * root mysqldump -u root -pxxxxxxxx Database | gzip >
> /back-up/DB_name_`date '+%d-%m-%Y'`.sql.gz
> 00 1 * * 0 root mysql -u root -pxxxxxxxx -e 'ANALYZE TABLE
> tbl_name;' DB_name
> 10 1 * * 0 root mysql -u root -pxxxxxxxx -e 'OPTIMIZE TABLE
> tbl_name;' DB_name
> 20 1 * * 0 root mysql -u root -pxxxxxxxx -e 'CHECK TABLE tbl_name;'
> DB_name
>
>
>
> What am I doing wrong? it's not work !!
What you are doing wrong:
1. You posted a similar query earlier and did not reveal much in
that discussion.
ref: <http://www.ae.iitm.ac.in/pipermail/ilugc/2013-May/076486.html>
2. In the above discussion you did not read the replies to your
questions very carefully [a]
3. People asked you to post specifics in that discussion but you did not.
[a] Read my response posted earlier
<http://www.ae.iitm.ac.in/pipermail/ilugc/2013-May/076497.html>
Notice I mention the '%' character in crontab entries. You also have
'%' char entries in your crontab they need to be escaped like so \%.
(man 5 crontab)
Had you shared the crontab entries in your first discussion and also
read the replies more carefully, your problem would have been solved
much sooner.
--
Arun Khan
Sent from my non-iphone/non-android device
(অরুণ খান্/अरुण खान)
_______________________________________________
ILUGC Mailing List:
http://www.ae.iitm.ac.in/mailman/listinfo/ilugc