cron job command

Category: Cpanel

Jaron
Asked:
2012-07-14 4:31 pm EST

Hits: 1,138
Hi,

I'm trying to setup a cron job via cpanel. I'm a bit confused on which command to use. I found in the knowledge base that wget is blocked. Which of the following would be the best to use?

/usr/bin/lynx -source http://example.com/cron.php

curl --silent --compressed http://example.com/cron.php

It's for a drupal site to run cron.

Thanks.

You must login before you can ask a follow up question.

You must login before you can submit an answer.

OTHER ANSWERS

0

Scott
Staff
20,113 Points
2012-07-16 9:51 am EST
Hello Jaron,

In speaking with our Advanced Hosting support, they advised the below format for your cron. This one will be the most efficient and also run quietly with no output or emails.

/usr/bin/php -q <path_to_script> > /dev/null 2>&1

The simply needs to be the full path to the script as opposed to the URL.

I hope this answers your question. If you have any more questions or information specific to the issue please leave a comment below so we can further assist you.

Best Regards,
Scott M

You must login before you can post a comment about this answer.

Like this Question?

Related Articles

It looks like there are no related articles.
Would you like to ask a question about this page? If so, click the button below!
Ask a Question

Need more Help?

Search

Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail: support@InMotionHosting.com
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!