Hello all.
I have ownclud well running but when I try to put in cron the occ system:cron this is not executed.
I have followed the tutorial and the syntax is looks correct:
This is what I get when I put the job in www-data cron:
root@debian:~# systemctl status cron
â—Ź cron.service - Regular background program processing daemon
Loaded: loaded (/lib/systemd/system/cron.service; enabled; vendor preset: enabled)
Active: active (running) since Wed 2022-05-04 08:32:00 CEST; 2h 29min ago
Docs: man:cron(8)
Main PID: 512 (cron)
CPU: 2min 42.327s
CGroup: /system.slice/cron.service
└─512 /usr/sbin/cron -f
May 04 10:30:01 debian CRON[5790]: Authentication failure
May 04 10:30:01 debian CRON[5791]: (root) CMD ([ -x /etc/init.d/anacron ] && if [ ! -d /run/systemd/system ]; then /usr/sbin/invoke-rc.d anacron start >/dev/null; fi)
May 04 10:30:01 debian CRON[5792]: (root) CMD (/usr/sbin/omv-mkrrdgraph >/dev/null 2>&1)
May 04 10:39:01 debian CRON[6023]: (root) CMD ( [ -x /usr/lib/php/sessionclean ] && if [ ! -d /run/systemd/system ]; then /usr/lib/php/sessionclean; fi)
May 04 10:45:01 debian cron[6193]: Authentication failure
May 04 10:45:01 debian CRON[6193]: Authentication failure
May 04 10:45:01 debian CRON[6194]: (root) CMD (/usr/sbin/omv-mkrrdgraph >/dev/null 2>&1)
May 04 11:00:01 debian cron[6520]: Authentication failure
May 04 11:00:01 debian CRON[6520]: Authentication failure
May 04 11:00:01 debian CRON[6521]: (root) CMD (/usr/sbin/omv-mkrrdgraph >/dev/null 2>&1)
If I remove (comment) the job in the www-data cron the status is OK:
root@debian:~# systemctl status cron
â—Ź cron.service - Regular background program processing daemon
Loaded: loaded (/lib/systemd/system/cron.service; enabled; vendor preset: enabled)
Active: active (running) since Wed 2022-05-04 11:03:44 CEST; 10s ago
Docs: man:cron(8)
Main PID: 6722 (cron)
CPU: 34ms
CGroup: /system.slice/cron.service
└─6722 /usr/sbin/cron -f
May 04 11:03:44 debian systemd[1]: cron.service: Consumed 2min 42.329s CPU time.
May 04 11:03:44 debian systemd[1]: Started Regular background program processing daemon.
May 04 11:03:44 debian cron[6722]: (CRON) INFO (pidfile fd = 3)
May 04 11:03:44 debian cron[6722]: (CRON) INFO (Skipping @reboot jobs -- not system startup)
cron is up and running, and the command line appears to be correct.
I’d rather investigate, why cron-jobs from www-data are failing. This is working on many other systems, but not here.
I then investigated the cron for www-data and it seems this is not within the allowed in the PAM.
Finally i do not like to mess up the PAM security so I will remain with this workarond.