Hide Forgot
Description of problem: Set the loglevel argument to 2, which is supposed to mean Warnings (https://access.redhat.com/solutions/2216951). [root@osdev-master2 ~]# ps -ef | grep opensh root 4549 1 0 Sep15 ? 01:01:11 /usr/bin/openshift start master api --config=/etc/origin/master/master-config.yaml --loglevel=2 --listen=https://0.0.0.0:8443 --master=https://osdev-master2.dev.ambientia.fi:8443 root 5328 1 0 Sep15 ? 00:01:22 /usr/bin/openshift start master controllers --config=/etc/origin/master/master-config.yaml --loglevel=2 --listen=https://0.0.0.0:8444 root 5334 1 0 Sep15 ? 00:32:25 /usr/bin/openshift start node --config=/etc/origin/node/node-config.yaml --loglevel=2 However, We see a lot of Info level messages in the syslog. This causes problems for us, because we have a logging system where we have to pay for the license depending on the logging volume. Sep 21 09:48:55 osdev-master2 atomic-openshift-node: I0921 09:48:55.062826 5334 node_auth.go:142] Node request attributes: namespace=, user=system:serviceaccount:openshift-infra:heapster, groups=[system:serviceaccounts system:serviceaccounts:openshift-infra system:authenticated], attrs=authorizer.DefaultAuthorizationAttributes{Verb:"create", APIVersion:"v1", APIGroup:"", Resource:"nodes/stats", ResourceName:"master.example.com", RequestAttributes:interface {}(nil), NonResourceURL:false, URL:"/stats/container/"} Sep 21 09:48:55 osdev-master2 atomic-openshift-node: I0921 09:48:55.065459 5334 server.go:1100] POST /stats/container/: (2.772329ms) 200 [[Go 1.1 package http] 10.20.14.16:42648] Sep 21 09:49:00 osdev-master2 atomic-openshift-node: I0921 09:49:00.015869 5334 node_auth.go:142] Node request attributes: namespace=, user=system:serviceaccount:openshift-infra:heapster, groups=[system:serviceaccounts system:serviceaccounts:openshift-infra system:authenticated], attrs=authorizer.DefaultAuthorizationAttributes{Verb:"create", APIVersion:"v1", APIGroup:"", Resource:"nodes/stats", ResourceName:"master.example.com", RequestAttributes:interface {}(nil), NonResourceURL:false, URL:"/stats/container/"} Sep 21 09:49:00 osdev-master2 atomic-openshift-node: I0921 09:49:00.016791 5334 server.go:1100] POST /stats/container/: (1.031727ms) 200 [[Go 1.1 package http] 10.20.14.16:42648] Actual results: We see info messages in the log Expected results: This should honour the levels that are set for logging Additional info:
I suspect that the article is incorrect about the exact meanings of the loglevels, as I believe 0 is "Error" and so forth, but it is rather moot because I observe no appreciable difference whether level is set to 0, 1, or 2. Setting a better component for moving this forward.
Seth - can you track this down?
glog, the golang logging library that openshift uses has two orthogonal logging patterns. Messages are logged by either severity OR verbosity. Log severities are FATAL, ERROR, WARNING, and INFO. These don't relate to the loglevel in any way. For example: glog.Warningln("This is an warning message") will print to the warning and info log files regardless of the loglevel. Log verbosity is a number 0-5. Verbosity is not meant to convey severity but is meant more to control log growth. In fact, it is probably best thought of as debug levels (below INFO in severity) glog.Infoln("This is an information message") glog.V(0).Infoln("This is a important debug message") Any log level > 0 should really only ever been used when debugging an issue. Under normal operating conditions, loglevel should not be set as it does lead to large logs.
I have submitted a change to the incorrect documentation.