Web Hosting Forum | Lunarpages
News: October 6, 2008 - Submit Your Site for the October 2008 Site of the Month!
 
*
Welcome, Guest. Please login or register.
Did you miss your activation email?
October 16, 2008, 02:07:12 PM


Login with username, password and session length


Pages: [1]   Go Down
  Print  
Author Topic: can't run cron job properly (no such file or directory error)  (Read 110 times)
altoidboy
Spacescooter Operator
*****
Offline Offline

Posts: 40


« on: July 07, 2008, 10:50:28 AM »

i set up dadamail + the dadabridge on my domain so i can run a small discussion mailing list.

dadabridge instructions (http://dadamailproject.com/support/documentation-dada-3_0_0/dada_bridge.pl.html#configurating_the_cronjob_to_automatically_run_dada_bridge) say to use the url of the plug-in as my command to run. so that's how i configured it in cpanel's cron manager.

i went to the front end of my site and tested the url by going to the url of the plug-in (which works fine):

http://www.mydomain.com/clients/tribe/cgi-bin/dada/plugins/dada_bridge.pl

and that is exactly what i typed into cpanel's cron manager, and i told it to run once a minute.

however, once a minute, i'm getting e-mails that have just one line:

/bin/sh: http://www.mydomain.com/clients/tribe/cgi-bin/dada/plugins/dada_bridge.pl: No such file or directory

i don't know what to do...what did i do wrong here?
Logged
altoidboy
Spacescooter Operator
*****
Offline Offline

Posts: 40


« Reply #1 on: July 07, 2008, 02:12:27 PM »

never mind; i solved it. now i learned that the address of the plug-in should be written in relative terms, like this:

/home/altoid/public_html/clients/tribe/cgi-bin/dada/plugins/dada_bridge.pl

(it would be nice if cpanel had spelled this out for me. i entered the absolute address and assumed it would work.)

i'm posting it here just in case anyone has the same problem and searches for a solution.
Logged
MrPhil
Quantum Encyclopedia Writer
*****
Offline Offline

Posts: 3407



« Reply #2 on: July 17, 2008, 05:08:11 PM »

That's not relative; it's absolute. Relative  would be something like dada/plugins/data_bridge.pl.

"Cron" is a command line interface that doesn't have any idea that a server exists. It does not understand URLs such as http://www.mydomain.com/clients/tribe/... It only understands Unix/Linux paths. If you want to use a URL on a command line (such as in a cron job), check out "cURL". It may do what you want to do (at the cost of extra CPU cycles).

By the way, is this bridge something that needs to be run every minute, or less often, or even just once to configure the bridge? You run it too much and you could get your site suspended for using too many resources!
Logged

Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.6 | SMF © 2006-2008, Simple Machines LLC

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM