Solved

Scheduled Task (Cron Job) - Plesk 11, UnlimitedWebHosting

Posted on 2013-06-10
6
805 Views
Last Modified: 2013-06-11
Hi guys,

I'm using UnlimtedWebHosting for a site and trying to set up a scheduled task to run a PHP script.

After a few weeks of messing around with their support team, we've finally managed to get the command right to run a PHP script, which is as follows:

/usr/bin/php -q /var/www/vhosts/(sitename)/httpdocs/Code/testmail.php


Now, this works correctly if it's set by someone at their end, but if I try to make a change (or even open and close the job through Plesk), it breaks and the php page isn't called. Instead I get the following error:

-: /usr/bin/php: No such file or directory

If someone from the hosts support team go it and set it again, it starts working with the same command.

I've logged onto the Plesk Control Desk with an account that has all of the permissions set that I can give it, but still no luck. Whenever I set the job myself, it fails. Whenever they set it, it works.

UnlimitedWebHosting's support team don't seem to know what the issue is, and I don't have access to SSH.

Any ideas?
0
Comment
Question by:gesmuk
  • 3
  • 3
6 Comments
 
LVL 7

Expert Comment

by:Milind Koyande
ID: 39234165
Is it possible to see the screenshot of the plesk schedule task screen?
0
 

Author Comment

by:gesmuk
ID: 39234172
Sure, here you go.

Although, as I say, this works fine if it is set by the guys at the host, but not when I set it, so I know that the command is correct.

PLESK
0
 
LVL 7

Accepted Solution

by:
Milind Koyande earned 500 total points
ID: 39234178
Thanks for the Screenshot.

Please check following URL as it seems similar issue

==
http://shaun.net/2011/09/solving-plesk-10-3-1-cron-issues/
http://forum.parallels.com/pda/index.php/t-257668.html
==

The issue is related to shell, you will have to ask your provider to make the required changes on the server.
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 

Author Comment

by:gesmuk
ID: 39234585
Thanks for the advice, I forwarded it over to the support team and the problem now seems resolved.

Cheers,
0
 

Author Closing Comment

by:gesmuk
ID: 39234588
Thanks for the advice, I forwarded it over to the support team and the problem now seems resolved.

CHeers,
0
 
LVL 7

Expert Comment

by:Milind Koyande
ID: 39237031
You are most welcome and glad its fixed now :)
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Learn by example how to specify CSS selectors for Selenium WebDriver test automation software.
Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now