PDA

View Full Version : Cron Job - Problem With Backup.php, An error message from the root deamon


skeddy
January 3rd, 2005, 03:41 AM
Hi there,

I'm new to using Cron Jobs on my website, which is hosted by One and One.

I have done some research, and have come up with a backup.php script that backs up my Mysql database when ever it is run.

I have also tried to set-up a Cron Job that will run it every 12 hours (currently set for every 1 min, testing only!!), but I am getting an error message.

The Cron job is set up as follows:
MAILTO=rob@skeddy.net
*/1 * * * * /usr/local/bin/php -f /kunden/homepages/33/d85254132/htdocs/SQLBackup.php

The backup.php page runs the following:

#!/usr/local/bin/php
<?php
$file = "Databasebackup-".Date("m-d-y-H-i-s");
@exec("mysqldump -h DBHOST -u DBUSERNAME -pDBPASSWRD DB | gzip > /homepages/33/d85254132/htdocs/mysql_backup/".$file.".txt.gz");
echo "Back up job complete"
?>

The backup.php page dumps the database into a zip file, and I can run that from a browser, mobile phone, anywhere, and it does the job.

But when I use the above Cron job, I get the following message from the Cron Deamon:

X-Cron-Env: <MAILTO=rob@skeddy.net>
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env: <HOME=/kunden/homepages/33/d85254132/htdocs>
X-Cron-Env: <PATH=/usr/bin:/bin>
X-Cron-Env: <LOGNAME=*********>
Message-Id: <E1ClAHl-0007AH-00@mrvnet.kundenserver.de>
X-Provags-ID: kundenserver.de abuse@kundenserver.de sender-info:85254132@infong255

No input file specified.

I can run /usr/local/bin/php /kunden/homepages/33/d85254132/htdocs/backupjob2.php directly from puTTy and it does the back up fine.

Does anyone have any thoughts ? (Apologies if the layout above is awful !!)

MrBored
January 3rd, 2005, 01:03 PM
hehehehe, look at the pretty letters and colours! Weeeee.

Chimera[NL]
January 3rd, 2005, 02:07 PM
I'm sorry dude, I think you're trying the wrong forum. I don't think anyone here knows enough about your problem.

skeddy
January 3rd, 2005, 03:17 PM
It was worth a try !

pixelater
January 3rd, 2005, 07:32 PM
See ya. (Waves "bye-bye")

Chimera[NL]
January 4th, 2005, 04:02 AM
Originally posted by skeddy
It was worth a try !

Good luck anyway.

HerrZanthr
January 5th, 2005, 08:14 AM
Chimera, what DO you learn at school? Except from NOTHING?

Cron Jobs, what is that actually? Is it just a type of PHP?

MrBored
January 5th, 2005, 08:52 AM
Originally posted by HerrZanthr
Chimera, what DO you learn at school? Except from NOTHING?

Cron Jobs, what is that actually? Is it just a type of PHP?
I hate you, please go away.

Chimera[NL]
January 5th, 2005, 08:55 AM
Originally posted by MrBored
I hate you, please go away.

It's ok dude. I know him. He's a bit......different. But deep down he's a good guy. :D

MrBored
January 5th, 2005, 08:59 AM
Originally posted by Chimera[NL]
It's ok dude. I know him. He's a bit......different. But deep down he's a good guy. :D
K

Chimera[NL]
January 5th, 2005, 09:02 AM
Originally posted by MrBored
K

But, it was very sweet of you to protect me like that. I'll let you have some of my "special sauce" tonight. ;)

MrBored
January 5th, 2005, 09:17 AM
Originally posted by Chimera[NL]
But, it was very sweet of you to protect me like that. I'll let you have some of my "special sauce" tonight. ;)
mmmmm, a nice facial of it would be good.

Chimera[NL]
January 5th, 2005, 10:16 AM
Originally posted by MrBored
mmmmm, a nice facial of it would be good.

Consider it done.

skeddy
January 5th, 2005, 10:31 AM
My god, it's gone from Techy to Porno in about 12 posts . . . . .

I feel so ashamed !!

Chimera[NL]
January 5th, 2005, 10:39 AM
Originally posted by skeddy
My god, it's gone from Techy to Porno in about 12 posts . . . . .

I feel so ashamed !!

Hahaha, I see you're new here.

skeddy
January 5th, 2005, 10:57 AM
It's cheaper than buying videos from that fella down the road !

Chimera[NL]
January 5th, 2005, 02:35 PM
Originally posted by skeddy
It's cheaper than buying videos from that fella down the road !

And more entertaining

MrBored
January 5th, 2005, 03:22 PM
Originally posted by Chimera[NL]
And more entertaining
especially with the action facial shots.

skeddy
January 5th, 2005, 03:25 PM
Originally posted by MrBored
especially with the action facial shots.

SpunkSpecs are required though.:cool:
That stuff gets in your eyes and it stings !

MrBored
January 5th, 2005, 03:26 PM
Originally posted by skeddy
SpunkSpecs are required though.:cool:
That stuff gets in your eyes and it stings !
You'd know, what a fag.

skeddy
January 5th, 2005, 03:28 PM
cough cough.
So I've been told . .

MrBored
January 5th, 2005, 03:39 PM
greasy

skeddy
January 5th, 2005, 03:42 PM
Originally posted by MrBored
greasy

Now that, I don't know . . .

MrBored
January 5th, 2005, 04:22 PM
Originally posted by skeddy
Now that, I don't know . . .
Lies, we went through 37 bottles of vegetable oil.

skeddy
January 6th, 2005, 01:40 AM
Originally posted by MrBored
Lies, we went through 37 bottles of vegetable oil.

I have no recollection of the said event.

Chimera[NL]
January 6th, 2005, 09:23 AM
Originally posted by skeddy
I have no recollection of the said event.

Yeah I advised Bored to use GHB aka "The Lovedrug" It does wonders to little girls/boys who use the words 'No I don't want to" too often.

skeddy
January 6th, 2005, 10:31 AM
Originally posted by Chimera[NL]
Yeah I advised Bored to use GHB aka "The Lovedrug" It does wonders to little girls/boys who use the words 'No I don't want to" too often.

No wonder my behind is so sore.

Chimera[NL]
January 6th, 2005, 10:35 AM
Originally posted by skeddy
No wonder my behind is so sore.

We prefer to call it experienced.