Posted on: 09/09/03 08:03pm
By: ScurvyDawg
I went to the FAQ and found some great info on setting up the daily digest.
I did however have some issues using the info I was provided
here
You see after working with another fellow it was finally figured out by him not I that this is the string that needs to be entered
30 2 * * * php -q -f /home/pathto/emailgeeklogstories
Not 30 2 * * * /path/to/geeklog/emailgeeklogstories as given in the example.
I am not sure if this is specific to a Cpanel interface or not but the Daily Digest is working now and it ROCKS, thank you.
Re:Info on Cron for Geeklog within a Cpanel interface.
Posted on: 12/15/03 10:11pm
By: matthewcox
Most Cpanel installations put php in /usr/bin/php. If you look in the emailgeeklogstories script, you'll notice that the shabang line(line1) tells the system to use /usr/local/bin/php which doesn't exist. To be sure you have the right /path/to/php (or path to php) you can try one these methods (unix only sorry).
- login via ssh and type "which php" to get the path.
jailshell-2.05a$ which php
/usr/bin/php
jailshell-2.05a$
- since some systems don't have the which command, you could try
find / -name php -printf '%AY%Ad%AH%AMt%pt%Acn' 2>/dev/null|sort
Most likely, you will only see 2 entries(one bin and one lib).
jailshell-2.05a$ find / -name php -printf '%AY%Ad%AH%AMt%pt%Acn' 2>/dev/null|sort
2003160150 /usr/bin/php Tue Dec 16 01:50:54 2003
2003160249 /usr/lib/php Tue Dec 16 02:49:58 2003
jailshell-2.05a$
Choose the 'bin' entry for your path. If you have more than 2, the find statement above lists the php files in the order that they were last accessed. Most likely the most recently accessed bin/php is the one you're after.
- If all else fails, email your sysadmin for the /path/to/php
Once you get the correct path, change the shabang line to
#!/correct/path/to/php -q
Of course, my advice to you ScurvyDawg, is to leave yours alone if it works, but hopefully this will help someone else.
Also, if anyone knows any better ways to find the path to php, I'd love to hear.
Re:Info on Cron for Geeklog within a Cpanel interface.
Posted on: 12/15/03 10:18pm
By: ScurvyDawg
cool, I did not know that was why the basic documentation did not work for me.
Thanks