amansker Posted May 28, 2005 Posted May 28, 2005 I'm a newbie that needs to run a cron job on a reseller account. I read everything I can find in this forum and documents from Moodle. So far no luck with different emailed results like: (this is just a temporary setup until I move it to the real domain) 15 * * * * /usr/local/bin/php /home/andymansker/moodle/admin/cron.php /bin/sh: line 1: 15: command not found <****@server47> /home/andymansker/moodle/admin/cron.php /bin/sh: line 1: /home/andymansker/moodle/admin/cron.php: No such file or directory and perhaps the most successful: <****@server47> /usr/local/bin/php /home/andymansker/moodle/admin/cron.php Could not open input file: /home/andymansker/moodle/admin/cron.php. A direct URL to the file runs fine. The file is located as shown in the path above. Moodle info is here: http://moodle.org/doc/?file=install.html#cron It seems like this would work: 15 * * * * /usr/local/bin/php /home/andymansker/moodle/admin/cron.php Any help is appreciated! Quote
TweezerMan Posted May 28, 2005 Posted May 28, 2005 It looks to me like the server path to the cron.php isn't quite right - the public_html directory is missing from the path. I think your cron command should be the following: >php /home/andymansker/public_html/moodle/admin/cron.php Quote
amansker Posted May 29, 2005 Author Posted May 29, 2005 (edited) FIXED!Thanks David. I finally looked at an installation of Gallery and found the correct path is: /usr/local/bin/php /home/username/public_html/pathtocron/yourcron.php The actual domain name is not used. Edited May 29, 2005 by amansker Quote
amansker Posted May 29, 2005 Author Posted May 29, 2005 This info should go into a FAQ or tutorial since it is not available at this time and a Help Ticket resulted in: Please be advised that the help desk does not provide developer level support for the building of html code or web pages including third party scripts. Who can do that? Quote
TweezerMan Posted May 29, 2005 Posted May 29, 2005 Your problem was figuring out the correct server path to a particular file on your account. That question could have been answered by either the Help Desk or these forums. I don't know what you put in your Help Desk ticket, but if it looked like your first post in this thread (asking how to set up a cron job for Moodle), their response was the correct one. Quote
amansker Posted May 29, 2005 Author Posted May 29, 2005 Your problem was figuring out the correct server path to a particular file on your account. That question could have been answered by either the Help Desk or these forums. 1. I did post in this forum - I appreciate your response, but it was the incorrect path. 2. Before posting in this forum I did a thorough search of the forum, knowledge base and external sites. After clicking submit Help Ticket, I followed the suggested link to a Linux site and reviewed information, but could not find the answer. 3. The subject on the Help Ticket is "Cron Job Path." I simply asked for the path from cPanel and included my previous attempts and results. They kindly suggested it was a permissions problem. 4. I reviewed my original post and see your point - should have clarified the issue in subject. I just wasn't sure if my path was the problem or it was something else. I have invested two hours of my time to figure this out and it might save someone some time if it was documented in a FAQ/tutorial/knowledge base. Quote
TweezerMan Posted May 29, 2005 Posted May 29, 2005 1. I did post in this forum - I appreciate your response, but it was the incorrect path. <{POST_SNAPBACK}> I made my best guess based on the limited info you provided. You didn't provide the working URL to your cron.php, nor did I have any way of knowing that the "andymansker" you were including in the path was not your CPanel username - that you were guessing at that part of the directory path. 4. I reviewed my original post and see your point - should have clarified the issue in subject. I just wasn't sure if my path was the problem or it was something else. <{POST_SNAPBACK}> Taken all together, the error messages indicated to me that the path to cron.php was not correct, but not everyone sees the same things I do at the same time. I have invested two hours of my time to figure this out and it might save someone some time if it was documented in a FAQ/tutorial/knowledge base. <{POST_SNAPBACK}> I'm sorry you spent 2 hours on an issue that could have been resolved in 5 minutes, had the issue been framed correctly. Questions about the proper server path to a script or file are answered here in the forums all the time, so I don't know what else to tell you. Quote
amansker Posted May 29, 2005 Author Posted May 29, 2005 David, Are you an employee of TCH? or a volunteer? Andy Quote
TweezerMan Posted May 29, 2005 Posted May 29, 2005 I don't know what that has to do with this topic, but I volunteer my time to be a moderator in these forums. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.