Sorry for the late reply I did run guacd in debug mode, no more informative logs appear. As I said earlier, I traced the error to this function <https://www.libssh2.org/libssh2_sftp_open_ex.html>. The documentation says NULL is returned on error, although the logs don't print the actual error code. My next step is to patch guacd to print it, hoping it'll give me more information to find the source of the problem. Regarding network issues, that was my first guess as well. I reviewed the traffic and I see SSH-v2 keepalives transmitting and ack'ing successfully at the correct intervals (according to the connection configurations).
I very much doubt this is a guacamole bug, but If you have any other ideas I'd love to hear them! I'll update this thread when I find out anything new, hopefully it'll help someone someday :) Thank you. On Tue, Oct 12, 2021 at 6:30 PM Nick Couchman <[email protected]> wrote: > On Tue, Oct 12, 2021 at 10:30 AM Shai Roemi <[email protected]> wrote: > >> Thanks for the quick response! I apologize for the gray-on-white text, >> probably due to a browser extension >> I had a similar thought in mind, so I went ahead and set the "Server >> keepalive interval" to 10, in the "Session/Environment" configuration >> section. >> After about 10 minutes of idling I still experienced the same issue: all >> SFTP actions failed with errors such as: "Unable to read file", "Unable to >> open file" and "Unable to write to file" in guacd logs. >> In addition, I tried setting "ClientAliveInterval" to 10 on the SSH >> server's /etc/ssh/sshd_config file, still no luck. >> I took a quick look at the code in guacd doing the "keep-alive"-ing, and >> could not find anything off about it. >> >> The thing I find most weird about this, is as I mentioned, the SSH >> session remains fully functional after the idle duration (running shell >> commands, reading/writing files). It seems to be a problem with SFTP in >> particular >> > > It seems like there could be something network-wise interfering with > things, here. I'm not sure if you have any Application Firewalls or Deep > Packet Inspection going between guacd and the SSH/SFTP server, but it seems > feasible that something like that could be shutting down the inactive SFTP > connection. I don't think anything Guacamole-specific would be causing > this, but could be a network factor, or something on either the server > running guacd or the destination SSH/SFTP host. Have you looked at logs on > both those systems, and have you tried starting guacd in debug mode to see > if you get anything more useful out of it? > > -Nick >
