Click to See Complete Forum and Search --> : Problem with cron


joelmon
10-20-2001, 02:29 AM
Hello, I created a file 'cron.file'
and I uploaded it and I tried to get it to work daily

but it returned an email saying permission was denied. Do I have to chmod the cron.file to specific permissions to get it to execute?

Actually, I just want to active an asp script
/home/sites/site7/web/script.asp
(for example)

but when I created the file and uploaded it to the server and point to it in the cron file and telnet to the directory it is located in and type:
crontab cron.file

it will not active that script (script.asp)

What is wrong? Do I need to chmod the cron.file?

or am I totally blowing this? Does it not trigger .asp scripts? Just perl or .sh?

Thanks,I am just experimenting and figured I should ask.

X_console
10-20-2001, 02:31 AM
More likely you need to chmod the script you're trying to run and make it executable.

joelmon
10-20-2001, 02:33 AM
right. TO what do I do it? Just for user ?

700? 400? 200? lol

I am so eager to find out lol

I will try, but I want to make sure I do it right (I know *how* to do this, not sure what to chmod to)

thanks a TON, wow, this board rocks, fast reply, your time is appreciated, as I am new to this

Syngin
10-20-2001, 07:13 AM
Yes, I agree completely with you. THese people here have been fantastic in helping me out too. :D

As to your chmod question, 777 would open it wide for everything but I'm not sure that's exactly what you want. Apart from that, I don't know the 3's offhand.

I usually use the chmod console in CuteFTP when dealing with our web servers through my Win box. Chmod is a right click option in there and it shows you the chmod number it uses when you click the appropriate check boxs for the permissions you need.

Not the best way to do it but then again, I'm not the most efficient person around ;)

Syngin
10-20-2001, 07:14 AM
oops. 3's = #'s or numbers.

X_console
10-20-2001, 10:57 AM
You want to chmod it to 755.

7 = owner has read/write/execute
5 = group/other has read/execute

The manual page for chmod goes in detail about this. You don't have to use numbers too. chmod a+x does the same thing.

joelmon
10-20-2001, 06:34 PM
Still not working

I have a file
cron.file

I uploaded it in ascii
chmod to 755

the contents of file are:
31 15 * * * /home/sites/site7/web/autoasp/emaildb.asp

(one line)

that is cron.file chmod at 755
but it didn't execute the script at 3:31 pm
as intended

do I have to
crontab cron.file via telnet every time I edit it?

Why wouldn't it work? This sucks

thanks

X_console
10-20-2001, 07:40 PM
You need to chmod the script you're trying to run from cron. Not the cron script. In your case, you need to chmod 755 home/sites/site7/web/autoasp/emaildb.asp