Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

-vmodule should allow level -1 #107

Closed
michael-db opened this issue Nov 12, 2019 · 10 comments
Closed

-vmodule should allow level -1 #107

michael-db opened this issue Nov 12, 2019 · 10 comments
Labels
kind/bug Categorizes issue or PR as related to a bug. kind/feature Categorizes issue or PR as related to a new feature. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. priority/awaiting-more-evidence Lowest priority. Possibly useful, but not yet enough support to actually get it done.

Comments

@michael-db
Copy link

/kind bug

It is possible to pass the option -v -1 to disable level 0 logging, in which case only Errors are logged. However, it is not possible to pass a negative number for logging in a particular module, i.e., with the -vmodule option.

What steps did you take and what happened:

: logtest 114; go build && ./logtest -vmodule klogr=-1
invalid value "klogr=-1" for flag -vmodule: negative value for vmodule level

What did you expect to happen:

No error message, all log messages other than Errors for the specified module silenced.

Anything else you would like to add:

@k8s-ci-robot k8s-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Nov 12, 2019
@neolit123
Copy link
Member

disable level 0 logging

which is essentially disable logging completely?
isn't there a flag to do that already?

@neolit123
Copy link
Member

/remove-kind feature
/kind feature
/priority awaiting-more-evidence

@k8s-ci-robot
Copy link

@neolit123: Those labels are not set on the issue: kind/feature

In response to this:

/remove-kind feature
/kind feature
/priority awaiting-more-evidence

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added kind/feature Categorizes issue or PR as related to a new feature. priority/awaiting-more-evidence Lowest priority. Possibly useful, but not yet enough support to actually get it done. labels Nov 12, 2019
@michael-db
Copy link
Author

Is there? Level -1 applies only to Info, not Error, so it is not equivalent to disabling logging completely.

  -vmodule value
    	comma-separated list of pattern=N settings for file-filtered logging

If I have missed something then could you please indicate how to use -vmodule to disable all Info logging, but not Error logging, for a particular module.

@michael-db
Copy link
Author

: logtest 4;  go build && ./logtest -v -1
E1112 17:39:41.015022    1523 main.go:48]  "msg"="Error." "error"="oops"  

What is required is the equivalent with -vmodule to also work.

@neolit123
Copy link
Member

Level -1 applies only to Info, not Error, so it is not equivalent to disabling logging completely.

yes, i guess that's true.

If I have missed something then could you please indicate how to use -vmodule to disable all Info logging, but not Error logging, for a particular module.

ok, i think there is no way of doing that, currently.
the kind/feature label seems valid.

you can also try asking in #klog on the k8s slack if somebody has ideas.

@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Feb 10, 2020
@fejta-bot
Copy link

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Mar 11, 2020
@fejta-bot
Copy link

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

@k8s-ci-robot
Copy link

@fejta-bot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. kind/feature Categorizes issue or PR as related to a new feature. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. priority/awaiting-more-evidence Lowest priority. Possibly useful, but not yet enough support to actually get it done.
Projects
None yet
Development

No branches or pull requests

4 participants