The netopeer2-server didn't re call home when I changed the ietf-netconf-server configuration
I set two Opendaylight apps as the NETCONF Client. One is 10.120.81.73, Another is 10.120.81.91. I used sysrepocfg to set the ietf-netconf-server configuration:
<netconf-server xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-server">
<call-home>
<netconf-client>
<name>default-client</name>
<endpoints>
<endpoint>
<name>default-ssh</name>
<ssh>
<tcp-client-parameters>
<remote-address>10.120.81.91</remote-address>
<remote-port>6666</remote-port>
<keepalives>
<idle-time>1</idle-time>
<max-probes>10</max-probes>
<probe-interval>5</probe-interval>
</keepalives>
</tcp-client-parameters>
<ssh-server-parameters>
<server-identity>
<host-key>
<name>default-key</name>
<public-key>
<keystore-reference>genkey</keystore-reference>
</public-key>
</host-key>
</server-identity>
<client-authentication>
<supported-authentication-methods>
<publickey/>
<passsword/>
<other>interactive</other>
</supported-authentication-methods>
<users/>
</client-authentication>
</ssh-server-parameters>
</ssh>
</endpoint>
</endpoints>
<connection-type>
<persistent/>
</connection-type>
</netconf-client>
</call-home>
</netconf-server>
The netopeer2-server have call home successfully. Then I modified the IP to 10.120.81.73, the netopeer2-server did not re-call home till the 10.120.81.91 was disconnected.
How can I change the call home configuration and make it work immediately. Is there any possible to close the session of the old session at the netopeer2-server side
How can I change the call home configuration and make it work immediately. Is there any possible to close the session of the old session at the netopeer2-server side
No, established NETCONF session should never be terminated from server-side.
Does this mean that NETCONF Server needs to listen for changes in callhome settings. Then break the past session according to the change, and then the NETCONF Client uses the new IP for callhome
That is how you would want it to work but like I said, generally, NETCONF sessions should never be terminated from the server side so netopeer2 does not disconnect the session when the Call Home configuration changes.