2

My settings: Server OS ‪Debian 9.6‬ Plesk 17.8.11 Magento 1.9.4.0 PHP 7.2

When I run schedule task cron.sh I get this:

Task "/httpdocs/cron.sh" successfully completed in 0 seconds, output: /httpdocs/cron.sh: 1: /httpdocs/cron.sh: which: not found /httpdocs/cron.sh: 1: /httpdocs/cron.sh: sed: not found /httpdocs/cron.sh: 1: /httpdocs/cron.sh: expr: not found /httpdocs/cron.sh: 50: /httpdocs/cron.sh: ps: not found /httpdocs/cron.sh: 51: /httpdocs/cron.sh: cron.php: not found

Cron doesn't work. Where is the problem? Could you help, please

I think that the problem is with Plesk...

I setup crontab using SSH

crontab -e
*/5 * * * * sh /path/to/y

1 Answer 1

0

ok try to this first access your cron.php on url

https://domain.com/cron.php your should not get error 404

second check if you have correct file permission on cron.sh and cron.php

I suggest to you use this for your cronjob

https://github.com/AOEpeople/Aoe_Scheduler

Do you have SSH Access for your hosting account?

If you don't, you may need to edit the cron.php file and look for the following line of codes:-

$isShellDisabled = (stripos(PHP_OS, ‘win’) === false) ? $isShellDisabled : true;

Add the following codes in a new line exactly after the above line of codes:-

$isShellDisabled = true;```

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.