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

Add swss-common log level support to GNMI service #330

Merged
merged 1 commit into from
Nov 22, 2024

Conversation

liuh-80
Copy link
Contributor

@liuh-80 liuh-80 commented Nov 22, 2024

Add swss-common log level support to GNMI service

Why I did it

Improve GNMI debug experience

How I did it

Initialize swss-common log level thread when GNMI start.

How to verify it

Manually test:

admin@vlab-01:$ swssloglevel -l NOTICE -c telemetry
admin@vlab-01:
$ sudo tail -f /var/log/syslog
2024 Nov 22 05:30:03.876827 vlab-01 DEBUG gnmi#telemetry: :> select: enter
2024 Nov 22 05:30:04.734015 vlab-01 INFO systemd[1]: Starting sysstat-collect.service - system activity accounting tool...
2024 Nov 22 05:30:04.740683 vlab-01 INFO systemd[1]: Starting logrotate.service - Rotate log files...
2024 Nov 22 05:30:04.750069 vlab-01 DEBUG gnmi#telemetry: :< select: exit
2024 Nov 22 05:30:04.754189 vlab-01 DEBUG gnmi#telemetry: :- swssPrioNotify: Changing logger minPrio to NOTICE

Add new UT.

Work item tracking

Microsoft ADO (number only): 30298614

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111

Description for the changelog

Add swss-common log level support to GNMI service

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

@liuh-80 liuh-80 requested a review from ganglyu November 22, 2024 06:28
@liuh-80 liuh-80 merged commit 2c4b9c8 into sonic-net:master Nov 22, 2024
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants