subhra74 / snowflake

Graphical SFTP client and terminal emulator with helpful utilities
GNU General Public License v3.0
2.16k stars 231 forks source link

Cannot connect to Synology SSH #45

Closed Bass850 closed 4 years ago

Bass850 commented 4 years ago

Hi, I've been trying out Snowflake to connect to my ssh servers. On ubuntu hosts all is good.

I found however that connecting to Synology NAS SSH produces an error (Unable to connect to x.x.x.x Do you want to retry?)

I've tried lowing port from 20022 to 22. I also tried different encryption strength settings on Synology DSM (low/medium/high).

All to no avail.

SSH from command line of my PC running Ubuntu to same Synnology NAS works fine on all settings.

Is there any setting or logging i can try to solve this?

Thanks in advance

Bass850 commented 4 years ago

After running Snowflake from CLI I notices some errors while trying to connect to Synology NAS:

com.jcraft.jsch.JSchException: failed to send channel request at com.jcraft.jsch.Request.write(Request.java:65) at com.jcraft.jsch.RequestSftp.request(RequestSftp.java:47) at com.jcraft.jsch.ChannelSftp.start(ChannelSftp.java:237) at com.jcraft.jsch.Channel.connect(Channel.java:152) at com.jcraft.jsch.Channel.connect(Channel.java:145) at snowflake.common.ssh.SshClient.getSftpChannel(SshClient.java:113) at snowflake.common.ssh.files.SshFileSystem.connect(SshFileSystem.java:80) at snowflake.components.files.FileComponentHolder.getSshFileSystem(FileComponentHolder.java:306) at snowflake.components.files.browser.ssh.SshFileBrowserView.lambda$render$1(SshFileBrowserView.java:163) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.base/java.lang.Thread.run(Unknown Source) Exception caught in sftp file browser com.jcraft.jsch.JSchException: failed to send channel request at com.jcraft.jsch.Request.write(Request.java:65) at com.jcraft.jsch.RequestSftp.request(RequestSftp.java:47) at com.jcraft.jsch.ChannelSftp.start(ChannelSftp.java:237) at com.jcraft.jsch.Channel.connect(Channel.java:152) at com.jcraft.jsch.Channel.connect(Channel.java:145) at snowflake.common.ssh.SshClient.getSftpChannel(SshClient.java:113) at snowflake.common.ssh.files.SshFileSystem.connect(SshFileSystem.java:80) at snowflake.components.files.FileComponentHolder.getSshFileSystem(FileComponentHolder.java:306) at snowflake.components.files.browser.ssh.SshFileBrowserView.lambda$render$1(SshFileBrowserView.java:163) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.base/java.util.concurrent.FutureTask.run(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.base/java.lang.Thread.run(Unknown Source) log4j:WARN No appenders could be found for logger (com.jediterm.terminal.emulator.JediEmulator). log4j:WARN Please initialize the log4j system properly. log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.

Could it be that synology somehow doesnt allow file connection?

Bass850 commented 4 years ago

Just fixed it (may be handy for other users);

SFTP needs to be enabled on NAS using same port as SSH is configured on.

For more info see: https://unix.stackexchange.com/questions/272264/use-sshfs-to-mount-synology-nas

Now i can easily access NAS from ssh and transfer files too :-)