How to turn off logging?

How can logging be turned off for lucee? I dont want to have to manage logs. Rather have the ability to turn on if needed. How would i do this in lucee and if im running commandbox?

Without questioning the motive of wanting to turn off logging… I’m not 100% sure you can turn off logging entirely… however here’s a couple of suggestions:

  1. Under server admin → Settings → Logging there is a list of current log files. I don’t know what selecting those log files and clicking ‘delete’ would do as I’ve never tried it (probably just delete the current log file itself, but leave the logging utility available to rewrite that log file later, I’m guessing - but it may remove the logging functionality altogether)

  2. Editing each individual log file under Server admin → Settings → Logging gives you an option to adjust the log level for each log - from ‘FATAL’, the least verbose (producing the least log entries) to ‘TRACE’. the most verbose (producing the most log entries). You may be able to set them all to ‘FATAL’ and achieve, effectively, the same result as removing them as they will then only log fatal level errors (which should be rare to none if your code is solid to begin with).

HTH

– Denny

Thank you for this info. I really appreciate the comments.

Deleting doesn’t do anything, after you submit the change they still area all there. So I did set them all to fatal per you suggestion so that will help a lot.

If I cant delete/disable logging are there any log rotate package that works well, have you used anything like that for lucee?

If you click on a log it show max files and max size. When it reaches max size it starts a new one. I think default is 10MB and 10 files. Max files tells it how many archived for history.

2 Likes