Applicable to:
- Plesk for Linux
Symptoms
-
In an attempt to run the PHP script via Plesk > Domains > example.com > Scheduled Tasks > click Run now near the name of the task, the following error appears:
PLESK_ERROR: Task "/usr/bin/php /var/www/vhosts/example.com/httpdocs/bin/magento cron:run" completed with error in 1 seconds, output:
Could not open input file: /usr/bin/php /var/www/vhosts/example.com/httpdocs/bin/magento cron:run -
The field Script path in the task is set to
/usr/bin/php /var/www/vhosts/example.com/httpdocs/bin/magento cron:run
: -
The files
/usr/bin/php
and/var/www/vhosts/example.com/httpdocs/bin/magento
exist on the server:# ls -al /usr/bin/php
-rwxr-xr-x 1 root root 4618048 Nov 6 2016 /usr/bin/php
# ls -la /var/www/vhosts/example.com/httpdocs/bin/magento
-rw-r--r-- 1 user psacln 799 Sep 20 14:46 /var/www/vhosts/example.com/httpdocs/bin/magento
Cause
The syntaxis of the filled fields is incorrect.
Resolution
- Log into Plesk.
- Go to Domains > example.com > Scheduled Tasks.
- Check that fields are filled correctly using this guide.
In the example above the following should be adjusted:
-
Script path in the task should be set to
httpdocs/bin/magento
. -
with arguments field should be filled as
cron:run
. -
/usr/bin/php
should not be presented in Script path field due to the fact that PHP is defined by the Use PHP version field:
Comments
0 comments
Please sign in to leave a comment.