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.
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
[feature] Add support for SNMP credentials #471 #496
[feature] Add support for SNMP credentials #471 #496
Changes from all commits
682db12
000ed7f
d7da8b1
8b82ee5
ae7a789
791d656
d7d7bb9
8ae8402
1606f4a
44297e9
0b8c234
8ceb021
239ee70
7f23d54
85e036b
4dfd03b
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
we should not add a new DB column for this.
I think in OpenWISP Monitoring we should remove the field from being readonly, make it readonly with JS unless there's an SNMP check added, in that case we allow to change it.
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.
@nemesisdesign but we need some way to track that the user wants to change it, otherwise it will automatically update from the API requests (https://github.com/openwisp/openwisp-controller/pull/496/files#diff-47782e8d264d4907d7893cff2e77b42523d4fb90af8aaef26e78c7a34e996713R75). What do you think?
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.
should not be an issue.. openwrt devices will send the right management IP so we can keep it, non openwrt devices will not send management IP and will be empty.
Please verify the following:
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.
@nemesisdesign in that case, the management IP resets to an empty string.
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.
I confirm that the management IP changes after config restarts. I believe this is right. We should add a hint in the admin UI.
"IP address of the management interface configured on the device. The information received from the device will overwrite any changes done here"
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.
Ok thank you @purhan and @pandafy for double checking.
Here's my reasoning.
1. OpenWrt devices running openwisp-config and snmpd
In this case, we can assume the management IP will be set if
management_ip
is specified correctly in/etc/config/openwisp
.Hence we do not to add code that excludes the management IP update for this case.
2. AirOS devices running only snmp deamon, or OpenWrt running only SNMPd
Management IP will not be set at all, nor reset automatically because openwisp-config is not running.
Hence we do not to add code that excludes the management IP update for this case as well.
This code is not useful
For the reasons explained above I believe this code is not useful.
What should we look for? What would be useful?
I think we should strive for a solution which is general enough so that it can be flexibly used in different cases.
I believe a solution which can work reliably in many cases is the following:
This is the IP address used by OpenWISP to reach the device when performing any type of push operation or active check. The value of this field is generally sent by the device and hence does not need to be changed, but can be changed or cleared manually if needed.
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.
@nemesisdesign @pandafy Do you think perhaps a
clear ip
button is redundant? If the user wants to reset it, they can just edit it to be empty? This is how I have made it for now but I can change if you say so.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.
Will check and let you know.
This comment was marked as resolved.
Sorry, something went wrong.