Where is logged cron activity?

Keith keithw at caramail.com
Fri May 30 13:41:26 UTC 2025


On 5/29/25 7:11 PM, Robert Moskowitz via ubuntu-users wrote:
> 
> 
> On 5/29/25 7:51 PM, Colin Watson wrote:
>> On Thu, May 29, 2025 at 06:06:59PM -0400, Robert Moskowitz via ubuntu- 
>> users wrote:
>>> I am a Centos/Fedora and I am use to seeing what cron is doing by 
>>> looking at /var/log/cron
>>>
>>> No such file on my Ubuntu 22 system and using locate, I can't find a 
>>> similar file.
>>
>> It should be in /var/log/syslog; if you don't have that, try 
>> installing the rsyslog package.
>>
>> You can also see just the logging output from cron and nothing else 
>> using "journalctl -u cron.service".  journalctl has many options for 
>> filtering the output; see its manual page.
>>
> I really got to read the journalctl manual yet again.  I am still too 
> much of a hack at using it.
> 
> Poor excuse is it been a few years since I was putting together 
> something new and needed to figure out why it was not going as I thought 
> it should!
> 
> 

Edit /etc/rsyslog.d/50-default.conf and uncomment the cron line? I guess 
it still works.

# First some standard log files.  Log by facility.
#
auth,authpriv.*                 /var/log/auth.log
*.*;auth,authpriv.none          -/var/log/syslog
#cron.*                         /var/log/cron.log
#daemon.*                       -/var/log/daemon.log
kern.*                          -/var/log/kern.log
#lpr.*                          -/var/log/lpr.log
mail.*                          -/var/log/mail.log
#user.*                         -/var/log/user.log

Edit the file, then restart the rsyslog service.

-- 
Keith




More information about the ubuntu-users mailing list