Skip to content
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

Create Channel From Session fails #60

Open
Clio75 opened this issue Apr 26, 2023 · 3 comments
Open

Create Channel From Session fails #60

Clio75 opened this issue Apr 26, 2023 · 3 comments
Assignees
Labels
question Further information is requested

Comments

@Clio75
Copy link

Clio75 commented Apr 26, 2023

Hi and thanx for this grate lib.

I have used it some time now, and I don't know what may have changed. But now I get error in the Create channel from session

image
image

when I get into this VI everything seams to be in order(44)
image

Even the Path to the dll seams to be correct(46)
image

But out of the Call Liberian function I get error -12, witch give me error :
image

let me know if you need more from me to locate this unwanted feature.

PS: From my experience, It can be dangerous to remove information from the wire. I see that if there are an error in this VI all session information is removed from the wire. Please consider to leave the session information on the wire to ensure correct close/disconnect at the end :)

@volks73 volks73 added the question Further information is requested label Apr 28, 2023
@volks73
Copy link
Member

volks73 commented Apr 28, 2023

Thank you for your usage and interest in the project and toolkit.

I have pushed a new release or modified the main branch of this toolkit for little over a year. I do not think there are any changes that would have suddenly made the toolkit fail.

However, the timeout error seems to indicate that a response from the remote host was not received in time. Was the SSH server on the remote host possibly updated recently? An incompatibility between the version of libssh2 used in this toolkit and the remote SSH server software could have arisen.

Are you able to use PuTTY or Git Bash or Windows 10 OpenSSH client to connect to the remote SSH server without error?

@Clio75
Copy link
Author

Clio75 commented May 2, 2023

Hi,
SSH server is on a new product we are developing. And the software on this is in constant development, so it can happen that it have been updated without anyone have told me :)
Yes I can always login to the unit with putty, and I have never seen timeout error problems before.

I have made a "workaround"
image

It always connect in second or Third attempt, never on the first attempt.
Let me know if there are more I can add

@volks73
Copy link
Member

volks73 commented May 4, 2023

I am happy to hear you have found a workaround.

Have you tried the https://github.com/fieldrndservices/libssh2-labview/blob/main/src/Toolkit/Session/Write%20Timeout.vi VI for the session object before using the Create Channel VI? From the documentation:

Sets the timeout in milliseconds (ms) for reading and writing during the communication with a remote SSH/SFTP server.

The default read/write timeout might be to short and your network latency/bandwidth has changed recently due to more devices added to the network, packet shaping from IT department, cable degradation/change (Cat5e or Cat6?), other parts of the code/system "spamming" packets on the network, solar flare (kidding), etc. Increasing the timeout may negate the need for your workaround. Given it works on the second or third attempt, this seams like a reasonable source for the new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants