Remote SSH Connection fails for SFTP

I’m using the Remote SSH Connection node to connect to an SFTP server using username/password authentication on standard port 22. Using identical credentials & port information I am able to connect and browse the file hierarchy using the CyberDuck and WinSCP SFTP clients; however KNIME can’t connect and instead gives a “No such file or directory” error when testing the connection in the config dialog. The log information is below. Anyone else ever run across this?

2019-01-18 17:23:25,041 : WARN : SwingWorker-pool-4-thread-9 : TestConnectionDialog$TestWorker : SSH Connection : 0:937 : Couldn’t connect
2019-01-18 17:23:25,042 : DEBUG : SwingWorker-pool-4-thread-9 : TestConnectionDialog$TestWorker : SSH Connection : 0:937 : Couldn’t connect
2: No such file or directory
at com.jcraft.jsch.ChannelSftp.throwStatusError(ChannelSftp.java:2873)
at com.jcraft.jsch.ChannelSftp._stat(ChannelSftp.java:2225)
at com.jcraft.jsch.ChannelSftp._stat(ChannelSftp.java:2242)
at com.jcraft.jsch.ChannelSftp.ls(ChannelSftp.java:1592)
at com.jcraft.jsch.ChannelSftp.ls(ChannelSftp.java:1553)
at org.knime.base.filehandling.remote.files.SFTPRemoteFile.getLsEntry(SFTPRemoteFile.java:677)
at org.knime.base.filehandling.remote.files.SFTPRemoteFile.internalExists(SFTPRemoteFile.java:282)
at org.knime.base.filehandling.remote.files.SFTPRemoteFile.exists(SFTPRemoteFile.java:270)
at org.knime.base.filehandling.remote.connectioninformation.node.TestConnectionDialog$TestWorker.doInBackgroundWithContext(TestConnectionDialog.java:238)
at org.knime.base.filehandling.remote.connectioninformation.node.TestConnectionDialog$TestWorker.doInBackgroundWithContext(TestConnectionDialog.java:1)
at org.knime.core.util.SwingWorkerWithContext.doInBackground(SwingWorkerWithContext.java:106)
at javax.swing.SwingWorker$1.call(SwingWorker.java:295)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at javax.swing.SwingWorker.run(SwingWorker.java:334)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

Hi there!

couldn’t reproduce it. What kind of server is it?

Br,
Ivan

It is a Egnyte file server (Egnyte.com).

Thanks.

Cool. Will give it a try, investigate a bit and get back to you.
Br,
Ivan

I wonder if it has anything to do with the way permissions are set by Egnyte. The root ftp directory of an Egnyte domain contains only folders (no files allowed) all with ‘400’ permissions. Thus when you look at the root directory in CyberDuck you see the little red badge on all of the sub-directories.
image

Does the KNIME node freak out when it looks in the root directory and sees nothing with write permission?

Hi!

I have tested this a bit and here is what I managed:

  • to get the same error message as you (which is a start :slight_smile: )
  • connect to egnyte with FTP Connection node
  • create directory with Create Directory node which required me to allow non-secure FTP…

Will check some other things and get back to you.

Br,
Ivan

Cool. Thanks for looking into this.

I can confirm that the regular FTP connection does work if you turn on non-secure FTP in Egnyte config. This is useful to test a few things out, but I am not able to leave the non-secure option enabled (for obvious security reasons) – so still looking for a way to use the secure connection node…

After quite a bit of further digging I can now confirm that sftp does work with Egnyte. The problem was the connection was being reset by a Cisco Firewall unit between my client and the ftp server.Turning off FTP packet inspection on the firewall fixed the issue.

4 Likes

Hi there!

Glad it works now :slight_smile:

Br,
Ivan

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.