Jump to content
We've recently updated our Privacy Statement, available here ×
  • Unable to connect to SFTP server while scheduling the report.


    Prasad B
    • Features: JasperReports Server Version: v9.0.0 Product: JasperReports® Server

    Question: We are able to connect to our remote SFTP server from the WinSCP client but are unable to get through the same connection from the Jasper server report schedule (output options tab) and are facing the below error on the Jasper server:
    ===
    2024-04-23T12:51:07,978 ERROR SecureExceptionHandlerImpl,http-nio-8088-exec-1:125 - There was an error on the server. Try again or contact site administrators. (Error UID: 665c5c52-ec2a-43a5-98dd-98b1be23942d) com.jcraft.jsch.JSchException: Algorithm negotiation fail
    at com.jcraft.jsch.Session.receive_kexinit(Session.java:590)
    at com.jcraft.jsch.Session.connect(Session.java:320)
    at com.jcraft.jsch.Session.connect(Session.java:183)
    ===

    How do I resolve this issue?

    Answer: The error generated from the SFTP is this:

    2024-04-23T12:51:07,978 ERROR SecureExceptionHandlerImpl,http-nio-8088-exec-1:125 - There was an error on the server. Try again or contact site administrators. (Error UID: 665c5c52-ec2a-43a5-98dd-98b1be23942d) com.jcraft.jsch.JSchException: Algorithm negotiation fail
    at com.jcraft.jsch.Session.receive_kexinit(Session.java:590)
    at com.jcraft.jsch.Session.connect(Session.java:320)
    at com.jcraft.jsch.Session.connect(Session.java:183)

    In JR Server version 8.1.1, we bundle in jsch-0.1.54.jar in the WEB-INF/lib, which is the external  library used for the connection.

    As the error states, the problem is due to "Algorithm negotiation fail" and this error is not specific to the Jaspersoft product as it can occur with any application making a sftp connection over ssh.

    Hence, I am providing you with an external link where you can find solutions to this problem:

    https://stackoverflow.com/questions/6263630/jschexception-algorithm-negotiation-fail

    I would suggest the following action first, which is one of the solutions provided in the above article:

    - Install the oracle unlimited JCE and install in JRE_HOME/lib/security.

    If you are running on Java 8, then you can download this from:

    https://www.oracle.com/au/java/technologies/javase-jce8-downloads.html

    Make sure you back up the existing files before you copy the contents of jce_policy-8.zip into: /usr/java/jdk1.8.x_xx/jre/lib/security

    After performing the above, restart the JR Server and test again.


    User Feedback

    Recommended Comments

    There are no comments to display.



    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now

×
×
  • Create New...