Bug 1924764 - OLM default log level is set to INFO
Summary: OLM default log level is set to INFO
Keywords:
Status: CLOSED DUPLICATE of bug 1903034
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: OLM
Version: 4.6
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
: ---
Assignee: Evan Cordell
QA Contact: Jian Zhang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-02-03 15:02 UTC by Felipe M
Modified: 2024-03-25 18:06 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-02-09 18:57:12 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Felipe M 2021-02-03 15:02:22 UTC
Description of problem:
The default loglevel for the OLM operator is INFO instead of WARN.

Logrus (the underneath logging package used) has a default of Info [0] when creating a new instance, and that may give too much output in this case.

Moreover, the OLM have the `-debug` flag that sets the log level to `Debug` for troubleshooting, so having a default of Info seems too much for a default value.

Version-Release number of selected component (if applicable):
4.6.15

How reproducible:
View logs for OLM 

Steps to Reproduce:
--

Actual results:
Verbose output (due to info logs every few seconds)

Expected results:
Less verbose logs

Additional info:
Logrus (the underneath logging package used) have a default of Info [0] when creating a new instance, and that may give too much output in this case.
Moreover, the OLM have the `-debug` flag that sets the log level to `Debug` for troubleshooting, so having a default of Info seems too much for a default value.

[0]: https://github.com/sirupsen/logrus/blob/master/logger.go#L89
[1]: https://github.com/operator-framework/operator-lifecycle-manager/blob/master/cmd/olm/main.go#L107-L111

Comment 2 Anik 2021-02-09 18:57:12 UTC
Hi Felipe, 

We get a lot of valuable information by keeping the default log level of info and do not plan on changing that. There was already an effort as part of https://bugzilla.redhat.com/show_bug.cgi?id=1903034 to trim the logs coming from the underlying controller implementations in OLM which significantly reduced the volume of logs being produced. We could audit the code base and try to narrow down what is logged, but I do not believe that will have any real impact on the volume of logs produced any further.

*** This bug has been marked as a duplicate of bug 1903034 ***


Note You need to log in before you can comment on or make changes to this bug.