Reputation: 113
I am trying to connect AWS Glue to an Azure SQL Server via JDBC. I have tried different settings for the jdbc url without success. The URL's look as follows:
jdbc:sqlserver://domain.windows.net:1433/database
jdbc:sqlserver://domain.windows.net:1433;databaseName=database
In the documentation of AWS the SQL Server syntax is jdbc:sqlserver://host:port;databaseName=db_name
For test purposes I have used Squirrel SQL and made a succesful connection to my Azure SQL Server with it.
When I try to make a test connection within AWS Glue AWS CloudWatch gives me following log:
Attempting to connect with SSL: jdbc:sqlserver://domain.windows.net:1433;database={database}
SSL connection to data store failed. Retrying without SSL.
Check that your connection definition references your JDBC database with correct URL syntax, username, and password. The TCP/IP connection to the host domain.windows.net, port 1433 has failed. Error: "Connection timed out: no further information. Verify the connection properties. Make sure that an instance of SQL Server is running on the host and accepting TCP/IP connections at the port. Make sure that TCP connections to the port are not blocked by a firewall.".
What seems strange for me are the '{' brackets in the connection. Azure's Connection String tells me, that the connection itself should look like:
jdbc:sqlserver://domain.windows.net:1433;database=database
Maybe this is the issue but I am not sure how to solve it.
Upvotes: 1
Views: 1938
Reputation: 865
you have to set outbound and inbound rule of security group which you have defined during JDBC connection. set outbound rule to all trafic allowed. also allowed tcp traffic in your azure database.
Upvotes: 0
Reputation: 10876
As you could connect successfully to Azure SQL from squirrel; things are good on Azure end.
One issue can be SSL; But most probably it is not because it is retrying without SSL also which also failed.
On Glue end; please see if you have outbound connections allowed on that port.
Upvotes: 0