Comments (13)
So what exactly is happening? I would guess the server disconnected the client because of idle-timeout and once the client sends any RPC, this will be discovered, the client closes the socket, and the connection is properly terminated.
from netopeer2.
I got a log(attached) from which I can see that the client actively disconnected and will repeatedly connect and then disconnect. Tracking "Session 10" further reveals that the client creates one ssh session and open multiple channel
netopeer2-server-log.txt
from netopeer2.
Whatever the case, based on what I understand, this TCP state occurs when the connection is closed by one end and not by the other. And unless you can provide more information, I will assume it is the client not closing the connections, which is not something I can help with.
from netopeer2.
According to the TCP state diagram below, we can know netopeer2-server receive the FIN but not send FIN to the remote.
I also noticed that this function(nc_session_free_transport), when dealing with multiple NETCONF session, will not immediately close socket. According to the previous log, we know that the client has created multiple NETCONF session in one SSH session. then close SSH session directly. Does this matter?
from netopeer2.
Okay, then I would suggest you use the current latest release in the master
branch (or even the devel
) of the projects, I seem to remember some changes in how sockets were handled recently. As for freeing multi-channel SSH sessions, you cannot close the socket unless all the channels (NETCONF sessions) were closed because they all use the same SSH session (the same socket).
from netopeer2.
Has the latest devel branch fixed the above scenario?
So for the client, if the connection netopeer2-server uses multi-channel SSH, does it have to be close channel before closing the SSH session connection?
from netopeer2.
Has the latest devel branch fixed the above scenario?
I cannot guarantee it but it is possible.
So for the client, if the connection netopeer2-server uses multi-channel SSH, does it have to be close channel before closing the SSH session connection?
The NETCONF client is supposed to close all the NETCONF sessions, whatever way they were created. And netopeer2 will internally close the socket (SSH session) once there are no NETCONF sessions using it.
from netopeer2.
New discoveries:
netopeer2-server work threads stuck at "nc_session_free_transport"
from netopeer2.
I am not able to learn more because no libnetconf2 version I have looked at session.c:762
had any code there that could cause a hang. Please specify the version you are using, I thought you have updated to current devel
.
from netopeer2.
I use the version of libnetconf2 is v2.1.37. It hangs in the while loop, please see following code
I noticed that the above code has been removed in the new release, so I want to do a patch to remove those code from the current version, but I don't know if it will have any other impact.
from netopeer2.
You are free to apply only a patch but please do not ask for more support. We support only current master
and devel
versions.
from netopeer2.
Okay, got it. Since updating to the latest devel involves updates to other components, such as openssl, I want to temporarily fix it before updating
from netopeer2.
Then the OpenSSL version you are using is no longer supported, which is a significant security risk.
from netopeer2.
Related Issues (20)
- Configuration Modification Not Successful HOT 15
- Callback event "rpc" with ID 1 processing timed out. HOT 2
- subscription of "ietf-netconf-notifications" failed HOT 5
- revision in xmlns support HOT 6
- How command searchpath works HOT 15
- How to use an IPv6 address to connect to netopeer2-server HOT 4
- netopeer2-server crash after SSH socket error: connection timed out. HOT 5
- Error with get-schema format not supported when connecting to netopeer2 server HOT 5
- cert-to-name algo is picking rfc822-name from client.crt instead of ca.crt HOT 4
- Unable to connect using TLS in netopeer2-2.2.28 HOT 4
- Unknown element HOT 4
- netopeer2-cli cmd_establishpush() cannot be called multiple times for serving multiple notifications through separate callbacks HOT 7
- edit-config usage HOT 1
- Failed to establish remote TLS connection using self-signed certificate HOT 1
- common.sh uses iana*.yang files. Where are they coming from?
- netopeer2.conf and pam_nologin.so does not exist in Yocto Scarthgap HOT 3
- netopeer2-server: /home/ubuntn/libyang-2.0.112/src/parser_xml.c:696: lydxml_subtree_r: Assertion `xmlctx->status == LYXML_ELEM_CLOSE' failed. Aborted (core dumped) HOT 1
- TLS server cipher regarding HOT 1
- Complete example for callback mechanism e.g when changing/reading some field via netopeer2-server HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from netopeer2.