SiteGround with WordPress - CRON "Could not open input file" error

22 Views Asked by At

I have a WordPress site on SiteGround and have set up a CRON job using SiteGround's Cron Jobs tool.

I need to execute this file twice every hour:

/home/*********/public_html/*****/mycoolfile.php

There is nothing wrong in the file and it works just fine if executed manually, so it's nothing in the actual code.

The CRON command is:

php -q /home/*********/public_html/*****/mycoolfile.php

I've tried it with and without the -q flag.

Every 30 minutes I get an email from the CRON system stating:

Could not open input file: /home/*********/public_html/*****/mycoolfile.php

File permissions are R/W/E for "Owner" which should be enough. Any ideas?

1

There are 1 best solutions below

0
enigma65.0 On

It turned out to be a flaw in their AI help bot that was recently introduced as the primary tool for getting assistance with issues.

The server segment of the path the bot kept suggesting was sometimes incorrect and other times correct but saying to swap out parts that weren’t meant to swap out.

The correct path was: php /home/customer/www/****/public_html//mycoolfile.php