Contents
Overview of cron job
For JomSocial to run properly, you will need to set up a cron job to run periodically. By unloading some processing task to a scheduled job, JomSocial will be able to run faster and smoother.
The cron job is required to
avoid excessive processing during a normal page load to send out system emails. archive old activity stream log that are no longer relevant converting uploaded videos to standardized .swf files. perform optional administrative job such as remove old, unused photo album, which doesn't have any photos
Built-in cron job option
Use this option if you are not using JomSocial video upload feature. By enabling this, JomSocial will process cron on every page load, with an interval 5 minutes in between.
This option will only process email-related crons. It will not run any maintenance script, Amazon S3 transfer or video conversion. Avoid this option if your site is heavy with concurrent users (10+ users) at one time because it may have effect on performance Avoid this option if you enable video upload feature and rely on other cronjob methods instead.
Cron on Linux Systems
On most Linux system, you can simply run the command below. We would recommend to run the cron every 30 minutes of less. On a busy site, you might want to run it every 10 minutes. The more frequent you run it, the less load it will be on the server.
lynx -source "http://www.domain.com/index.php?option=com_community&task=cron" > /dev/null
lynx is a text based browser that is installed in most hosting environments. If you do not have lynx installed, you can use other alternatives such as wget as below:
wget -O /dev/null "http://www.domain.com/index.php?option=com_community&task=cron" > /dev/null
Don't worry, this operation actually runs very fast and has very little impact on the server, equivalent to a normal single page load.
NOTE: When setting up this command, make sure and put in your full valid domain name, 'localhost' will not suffice.
Setting up cronjob in CPanel 11
To add a new cronjob in CPanel 11 variants, logon to your CPanel and click on the "Cronjobs" link under the "Advanced" section as the screenshot below.
Upon clicking on the cronjobs, you will then be directed to a page similar as below. In this example, click on the "Standard" button to proceed.
Then on the screen below, enter the following command
lynx -source "http://www.yoursite.com/index.php?option=com_community&task=cron" > /dev/null
Select every 5 minutes, every hour, every day , every month and every weekdays so that the action above will be executed every 5 mins of the day, in any given month.
Note: In order for the emails to be sent and videos to be converted, the scheduled task must be executed correctly.
Cron Jobs at GoDaddy
GoDaddy doesn't support cronjobs from the panel. Using an online cron scheduler (look below) should solve the problem.
Free Online Cron Scheduler
If you are still having trouble with the above options, use any free online cronjob scheduler service available on the web. Do not worry on security because what these sites do is merely accessing index.php?option=com_community&task=cron at certain interval, which is open to anyone.
Popular services are: Set CronJob