Daily cron is a process that runs at midnight and does very important things for eramba, is a process that must run well or the system wont work well. Until some months ago this process was triggered with a http:// request (www crons) from the crontab - we changed that to CLI crons because in that way the process runs in a more contained way (not subject to network time outs, proxys, etc).
There are still too many people using www crons, we’ll be contacting them one by one to migrate them to CLI. This post will be expanded with clear instructions on how to do that, we will setup Zoom calls with those that need help.
The daily process does many things and can take a long while to run, it should not take longer than 10 minutes … we were looking at the statistics and saw this:
We will be contacting those customers with daily runs > 5 minutes to verify their systems, it could be that they have an unusually large database (rare) or that the infrastructure where eramaba runs is not optimized (in our experience, the most usual, very easy to resolve, cause)
Make sure there are no pending updates (Settings/Updates)
Make sure that php.ini file is the same for apache and cli cp /etc/php/7.x/apache2/php.ini cp /etc/php/7.x/cli/.
Go to Settings/Crontab
Switch Crontab from Web to CLI
Save settings
Open crontab again and copy test commands
Run these commands as a root
System health and test command should have all items OK
Copy crontab commands
Open crontab file crontab -e
Comment old cronjobs commands and insert new one
Save
Done, you are now running CLI crons
RHEL/Centos:
There is only one php.ini file you can skip step 2
These linux distributions have more options to define cron job
- master file in /etc/crontab, along with crontab files for the users in /var/spool/cron/
- specific /etc/cron.hourly, /etc/cron.daily etc.
Make sure you are editing the right cron file!
There is no CLI directory .There in ubuntu we have only /etc/php/7.X/apacha2 directory it has php.ini file , so do i have to create in manually ,
I’m using ubuntu 22.04 LTS
It might be more helpful to send a single email to our support rather than relying on multiple five-year-old discussions.
These threads are mostly no longer relevant since we have switched to a Docker-based infrastructure.