netopeer2
netopeer2 copied to clipboard
Netopeer2 not opening the port:10830 after deleting the startup config
Hi Team,
We have brought up the netopeer2 along with sysrepo and 10830 port is being open and we are able to connect to that port via netopeer2-cli.
Trace observed in netopeer2:
[INF]: LN: Listening on 0.0.0.0:10830 for SSH connections.
We have pushed a few configurations and copied the configuration from running to startup DB using "copy-config --target startup --source running" command via netopeer2-cli.
After that, We have deleted the "startup database" using "delete-config --target startup" command via netopeer2-cli. Now, we have brought down the netopeer2 followed by the cleanup (rm -rf /dev/shm/sr*) and brought it up again. But the port 10830 is not opened (could not observe port open trace in netopeer2 console) and we could not connect from netopeer2-cli.
Could you please let us know if we are missing anything?
Thank you.
netopeer2-server configuration itself is stored in sysrepo so if you delete startup configuration, it includes the configuration of the interfaces to listen on, among any other server options.
Hi Michal, Thanks for your response.
Is it possible for you to share the list of yang files in which the neteopper2-server init configuration is stored? Also, As per netconf standard, there is no restriction in deleting the startup datastore. But in the case of netopeer2-server, if a user deletes the startup database, then neteopper2-server will not listen on any port. Is this a limitation or Is there any default setting that the netopeer server will start to listen when there is no startup database?
Is it possible for you to share the list of yang files in which the neteopper2-server init configuration is stored?
The only module containing actual data is ietf-netconf-server, others are imports. But data from ietf-keystore are also referenced and hence needed.
Also, As per netconf standard, there is no restriction in deleting the startup datastore. But in the case of netopeer2-server, if a user deletes the startup database, then neteopper2-server will not listen on any port.
You are interpreting the situation incorrectly, there is no restriction and you can delete whatever you want. netopeer2-server not listening on any port is the consequence of you deleting the configuration but the server continues to work (and any NETCONF sessions already established, for example).
Is this a limitation or Is there any default setting that the netopeer server will start to listen when there is no startup database?
There is no limitation and it works exactly as it should according to the specification. ietf-netconf-server does not define any default settings (because it would be a security risk among other possible problems) so if you delete the configuration, the empty configuration is applied, that is all. I understand it may be unexpected for you but the problem is your incorrect understanding of the expected behavior and not a faulty implementation.