Timeout error due to Error reading SSH protocol banner

Abhilasha Kumar 0 Reputation points
2024-11-04T13:32:47.8733333+00:00

Hi Team,

We are facing ‘Timeout error due to Error reading SSH protocol banner’ while trying to connect to sftp server through Azure Synapse Notebook. We are using python as source language and paramiko version 2.12.0 to connect to the server and download the data. This error is thrown randomly on Azure Notebook. Please see the below screenshot of error for your reference.

User's image

Can you please help for this.

Regards,

Abhilasha

Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
5,373 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Chandra Boorla 14,585 Reputation points Microsoft External Staff Moderator
    2024-11-05T02:48:16.2933333+00:00

    Hi @Abhilasha Kumar

    Greetings & Welcome to Microsoft Q&A forum! Thanks for posting your query!

    It seems that you are facing an error while working with Azure Synapse Notebook. The error message "paramiko.ssh_exception.SSHExeception: Error reading SSH protocol banner" usually occurs when the SSH banner is not being read correctly. This can happen due to various reasons such as network connectivity issues, incorrect SSH configuration, or firewall restrictions.

    Here are some troubleshooting steps that might help you in resolving your query.

    • Network Connectivity - Verify that you can reach the SSH server from your Azure Synapse environment. You can do this by using tools like ping or telnet to ensure that the server is reachable on the SSH port (default is port 22).
    • Firewall and Security Groups - Ensure that there are no firewalls or security groups blocking the SSH traffic. Check both the inbound and outbound rules to make sure that port 22 is open.
    • Server Configuration - Make sure that the SSH server is running and properly configured. You can check the SSH server logs for any errors or warnings that might provide more insight.
    • Update Paramiko - Ensure that you are using the latest version of Paramiko, as bugs and issues are fixed in newer releases. You can update Paramiko using pip:
    pip install --upgrade paramiko
    

    For your reference, the following links may provide some useful insights.

    https://stackoverflow.com/questions/65005579/error-reading-ssh-protocol-banner-when-connecting-to-port-443-with-paramiko-in

    https://dnmtechs.com/paramiko-error-reading-ssh-protocol-banner-in-python-3-programming/

    Disclaimer: This response contains a reference to a third-party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software or information found on these sites; therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.

    I hope this information helps. Please do let us know if you have any further queries.


    If this answers your query, do click Accept Answer and Yes for was this answer helpful. And, if you have any further query do let us know.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.