Suitecrm log:
Mon Jul 25 19:40:16 2022 [224603][1][FATAL] SugarBean::populateDefaultValues $field_defs should be an array
Mon Jul 25 19:55:52 2022 [235127][-none-][FATAL] cron.php: running as root is not allowed in allowed_cron_users in config.php. Exiting.
Mon Jul 25 19:55:52 2022 [235127][-none-][FATAL] cron.php: root’s crontab should not be used for cron.php. Use your web server user’s crontab instead.
If I manually execute php -f php in suitecrm directory then:
cron.php running with user that is not in allowed_cron_users in config.phpPHP Fatal error: Uncaught Exception: cron.php running with user that is not in allowed_cron_users in config.php in /var/www/suitecrm/include/utils.php:1898
Stack trace:
#0 /var/www/suitecrm/cron.php(70): sugar_die()
#1 {main}
thrown in /var/www/suitecrm/include/utils.php on line 1898
In the apache2 error log:
[Tue Jul 26 00:00:03.250646 2022] [mpm_prefork:notice] [pid 195443] AH00163: Apache/2.4.41 (Ubuntu) OpenSSL/1.1.1f configured – resuming normal operations
[Tue Jul 26 00:00:03.250700 2022] [core:notice] [pid 195443] AH00094: Command line: ‘/usr/sbin/apache2’
My system details:
Using digital ocean droplet with ubuntu 20.4
two php’s installed 7.4 and 8.1
I ensured 7.4 running
suitecrm version 7.11.18
The command doesn’t appear in:
crontab -l -u root
It appears in
crontab -l -u www-data
I see the code link shared by you is similar to cron.php
What do I need to do with it? Is it ok to edit it to add
CronAllowedUser($cronUser);
As suggested by abhishek07456 in this
Or should I simply add root in the allowed_cron_users in the config.php as I am not running on siteground?