- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Using ListSFTP results in an exception: Failed to obtain connection to remote host due to com.jcraft.jsch.JSCHException: Session.connect: java.net.SocketException: Connection reset: {}
- Labels:
-
Apache NiFi
Created on ‎12-06-2017 01:07 AM - edited ‎08-17-2019 07:43 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Using ListSFTP processor in Nifi 1.3.0 to list contents of a SFTP directory. Getting exception message:
Failed to obtain connection to remote host due to com.jcraft.jsch.JSCHException: Session.connect: java.net.SocketException: Connection reset: {}
Here's a screenshot from the nifi-app.log on the NIFI Node
Created ‎12-06-2017 04:18 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @Mayan Nath,
Can you please ensure to set "Strict Host Key Checking to False "
and also remove the known_hosts entries for the target host (under the directory ~/.ssh/knon_hosts or nifi user)
the best thing is to do the sftp manually from the command line and test once thats working incorporate to the NiFi cluster.( please ensure that you have performed the same across all he hosts)
Hope this helps !!
Created ‎12-06-2017 04:18 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @Mayan Nath,
Can you please ensure to set "Strict Host Key Checking to False "
and also remove the known_hosts entries for the target host (under the directory ~/.ssh/knon_hosts or nifi user)
the best thing is to do the sftp manually from the command line and test once thats working incorporate to the NiFi cluster.( please ensure that you have performed the same across all he hosts)
Hope this helps !!
Created ‎12-06-2017 06:29 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks @bkosaraju
Strict Host Key Checking is set to False.
If with target hosts, you mean, the SFTP server (our destination) then it is not in the list of /.ssh/known_hosts)
Just tried manual SFTP again and this time received, Connection Reset by Peer. Checking SFTP side in case our Node IP is blacklisted (possibly due to Max Failure condition.)
Update -- 12-07-2017 -- The IP for the NIFI Node was blacklisted on the SFTP Side. We've whitelisted the IP and the processor is now functional. Thanks.
Created ‎12-06-2017 12:50 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did OpenSSL version change at server?
https://superuser.com/questions/972996/create-a-sftp-connection-in-netbeans
Did directory permissions change on FTP server? Try a different directory.
Did NiFi user change?
Increase timeout
Definitely try command line sftp from a nifi node.
Did any IPs change?
Created ‎12-06-2017 05:21 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks @Timothy Spann
This is a new user but also the existing users are not working to reach the SFTP to any location.
Directory permissions on SFTP have not changed.
Timeout is currently set to 30sec on the processor. That should be sufficient but please advise if that needs to be increased.
IPs have not changed.
RE - command line SFTP -- Just tried manual SFTP again and this time received, Connection Reset by Peer. Checking SFTP side in case our Node IP is blacklisted (possibly due to Max Failure condition.)
Update -- 12-07-2017 -- The IP for the NIFI Node was blacklisted on the SFTP Side. We've whitelisted the IP and the processor is now functional. Thanks.
