1 gr8dude Sep 06, 2010 15:18
3 gr8dude Sep 06, 2010 21:20
Hmmm.. Ok, you've confirmed that this feature doesn't work out of the box.
I don't have SSH access to the server, so I won't be able to rely on that approach. As a workaround, I will use the following Python script (it just opens the needed URL to cause the task to be executed)
import urllib
site = "http://railean.net" #change this to your site, no trailing slash
a = urllib.urlopen(site + "/cron/cron_exec.php")
a.read()
I will add it as a scheduled task and have it ran every hour. Those who use Linux can call wget and pass it the right URL.
In this context, I think it it reasonable to add a remark to the UI itself and state that the scheduled tasks only work IF ... (list of conditions). Otherwise the perceived model is different from the real one.
4 edb Sep 07, 2010 02:40
FYI unless something has changed, hourly checks on antispam is silly. The way that works is an actual human takes the time to look at what's been reported and either publishes or doesn't new keywords. That means MAYBE once a day you'll see updates. It is possible to get the update right while someone is busy publishing new keywords, which would mean you can get more right after getting some, but that'd be the exception.
Daily is probably more than you will ever need. Weekly is probably more realistic.
5 gr8dude Sep 07, 2010 09:04
Aha, thank you for pointing that out, I will adjust my cron-jobs accordingly.
This is pretty valuable information, I am sure that most people will set it to a value that is 'as frequent as possible', thinking they would get less spam; but that will simply cause unwanted extra-load on the servers.
The lack of documentation for anything related to "Scheduled Tasks" has always pissed me off to no end. >:-<
Basically, if you don't have root ssh (or cPanel/Plesk) access to your server, you're going to have a hard time getting anything "Automated" to work. You can create Scheduled Tasks out the ying-yang in b2evo and they will just happily sit there doing nothing whatsoever--whether it's hitlog pruning, asynchronous pings, or anti-spam updates.
The sorely missing (and apparently super-secret squirrel) info is that you have to set up a cronjob on your server to execute the 'cron_exec.php' file that resides in the 'cron' folder of your b2evo installation.
If you know how to set up cron jobs then it's no big deal. You just set one up to execute that script every couple of minutes and it will check to see if b2evo has any scheduled tasks that are due to run. You have to know where your php binary is located and the full path to the 'cron_exec.php' file, but a crontab entry something like:
*/5 * * * * /usr/bin/php /full/path/to/b2evo-cron-folder/cron_exec.php > /dev/null 2>&1
will look for scheduled tasks every 5 minutes.
If you don't know how to set up cron jobs, then your work is cut out for you. Buried deep in the super secret archives of the b2evo documentation is [url=http://manual.b2evolution.net/Set_up_a_Linux_cron_job]this tidbit[/url] that may help. [url=http://www.pantz.org/software/cron/croninfo.html]This page[/url] may help you with the crontab syntax.
Good luck!
I won't use b2evo's antispam database so I can't help you with your other questions.