-
Notifications
You must be signed in to change notification settings - Fork 664
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
[show][config] Add new snmp commands #1347
Merged
tsvanduyn
merged 6 commits into
sonic-net:master
from
tsvanduyn:tsvanduyn/snmp_show_commands
May 5, 2021
Merged
[show][config] Add new snmp commands #1347
tsvanduyn
merged 6 commits into
sonic-net:master
from
tsvanduyn:tsvanduyn/snmp_show_commands
May 5, 2021
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tsvanduyn
force-pushed
the
tsvanduyn/snmp_show_commands
branch
from
March 31, 2021 00:09
9cc6a85
to
acc56ea
Compare
tsvanduyn
force-pushed
the
tsvanduyn/snmp_show_commands
branch
from
April 16, 2021 22:32
252fa1a
to
aca04cb
Compare
tsvanduyn
requested review from
jleveque,
yxieca,
qiluo-msft and
SuvarnaMeenakshi
April 16, 2021 22:43
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
qiluo-msft
reviewed
Apr 23, 2021
SuvarnaMeenakshi
requested changes
Apr 26, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As comments.
qiluo-msft
reviewed
Apr 27, 2021
qiluo-msft
reviewed
Apr 27, 2021
qiluo-msft
reviewed
Apr 27, 2021
qiluo-msft
reviewed
Apr 30, 2021
qiluo-msft
reviewed
Apr 30, 2021
qiluo-msft
approved these changes
May 4, 2021
SuvarnaMeenakshi
approved these changes
May 5, 2021
tsvanduyn
changed the title
Add new snmp show commands
[show][config] Add new snmp commands
May 5, 2021
gitsabari
pushed a commit
to gitsabari/sonic-utilities
that referenced
this pull request
Jun 15, 2021
Added new SNMP show and config commands using ConfigDB as well as unittests. show commands: show runningconfiguration snmp show runningconfiguration snmp contact [--json] show runningconfiguration snmp location [--json] show runningconfiguration snmp community [--json] show runningconfiguration snmp user [--json] config commands: sudo config snmp community add/del/replace sudo config snmp contact add/del/modify sudo config snmp location add/del/modify sudo config snmp user add/del
qiluo-msft
pushed a commit
that referenced
this pull request
Nov 15, 2021
Added new SNMP show and config commands using ConfigDB as well as unittests. show commands: show runningconfiguration snmp show runningconfiguration snmp contact [--json] show runningconfiguration snmp location [--json] show runningconfiguration snmp community [--json] show runningconfiguration snmp user [--json] config commands: sudo config snmp community add/del/replace sudo config snmp contact add/del/modify sudo config snmp location add/del/modify sudo config snmp user add/del
stepanblyschak
pushed a commit
to stepanblyschak/sonic-utilities
that referenced
this pull request
Apr 18, 2022
9dd3025 2021-05-11 | [Command-Reference.md] Document new SNMP show and config commands (sonic-net#1600) [Travis Van Duyn] be40767 2021-05-05 | [show][config] Add new snmp commands (sonic-net#1347) [Travis Van Duyn]
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
- What I did
I created these new show commands:
show runningconfiguration snmp
show runningconfiguration snmp contact
show runningconfiguration snmp location
show runningconfiguration snmp community
show runningconfiguration snmp user
show runningconfiguration snmp contact --json
show runningconfiguration snmp location --json
show runningconfiguration snmp community --json
show runningconfiguration snmp user --json
These commands will check in the REDIS ConfigDB and get the information.
- How I did it
I created a standard snmp schema that was approved here:
sonic-net/SONiC#731
I also moved from using only the snmp.yml file to using the ConfigDB for the device.
sonic-net/sonic-buildimage#6205
Jinja template update:
sonic-net/sonic-buildimage#6134
This way the REDIS ConfigDB will be the source of truth but we can still use the snmp.yml file.
Since it is setup whenever the snmp docker container is restarted to pull this info into the ConfigDB we are able to use the data in the configdb for the show commands.
- How to verify it
You can run the show commands:
show runningconfiguration snmp
show runningconfiguration snmp contact
show runningconfiguration snmp location
show runningconfiguration snmp community
show runningconfiguration snmp user
show runningconfiguration snmp contact --json
show runningconfiguration snmp location --json
show runningconfiguration snmp community --json
show runningconfiguration snmp user --json
and compare the output to what is in the REDIS ConfigDB.
- Previous command output (if the output of a command-line utility has changed)
N/A
- New command output (if the output of a command-line utility has changed)