OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



Installing OJS: Any task to add to crontab?

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

Installing OJS: Any task to add to crontab?

Postby mbria » Mon Oct 01, 2007 1:56 am

Hi,

Brief and fast question: Is there any OJS' task to be added to the crontab?

I installed OJS some times before, but now I'm unable to remember if a I need to add something to my crontab to perform indexing and so on... or OJS is implementing it due "poor man's cron" technique.

Thanks for your help,

m.
mbria
 
Posts: 292
Joined: Wed Dec 14, 2005 4:15 am

Re: Installing OJS: Any task to add to crontab?

Postby asmecher » Mon Oct 01, 2007 7:54 am

Hi mbria,

See docs/README:
Scheduled Tasks
---------------
OJS supports a mechanism to execute a variety of tasks at scheduled times
(such as automatic sending of reminder notification emails).

To enable support for using scheduled tasks, edit your config.inc.php and
set the scheduled_tasks setting to On, and set up your operating system to
periodically execute (as the same user your webserver is running under) the
PHP script found at tools/runScheduledTasks.php in your OJS directory:

On *nix operating systems, this can be done by adding a simple cron task:
# crontab -e www
0 * * * * php /path/to/ojs2/tools/runScheduledTasks.php
In this example the script would be executed every hour.

On Windows XP systems, this can be done by using the Windows Task Scheduler:
1) From the Control Panel, double-click on Scheduled Tasks.
2) Right-click within the Scheduled Tasks window and choose:
New > Scheduled Task
3) Under the Task tab, in the Run field, enter:
php c:\path\to\ojs2\tools\runScheduledTasks.php
4) You will also be asked to specify the folder to start this task in
(which will usually be the folder that PHP was installed into) and
the user under which the task will be executed as.
5) Under Schedule tab and the Settings tab, you can more specifically
configure the task. For example, you can choose start and end dates
for this scheduled task and also how often to execute this task.

If using the scheduled tasks script, it is recommended that the script be
set up to execute at least once per day.

Note that using the script also requires you to have the PHP command-line
interpreter installed on your server.
Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8445
Joined: Wed Aug 10, 2005 12:56 pm

Re: Installing OJS: Any task to add to crontab?

Postby mbria » Mon Oct 01, 2007 11:01 am

I'm ashamed... sorry to ask. :oops:

Thanks a lot for your answer,

m.
mbria
 
Posts: 292
Joined: Wed Dec 14, 2005 4:15 am

Re: Installing OJS: Any task to add to crontab?

Postby asmecher » Mon Oct 01, 2007 1:06 pm

Hi mbria,

No problem!

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8445
Joined: Wed Aug 10, 2005 12:56 pm


Return to OJS Technical Support

Who is online

Users browsing this forum: Google [Bot] and 3 guests