01-15-2020 05:41 AM - edited 04-18-2023 11:27 AM
This article walks through troubleshooting options that can be used to help diagnose why a user is getting a "Could not Connect!" error such as the ones below when setting up an Apache Spark on Databricks connection through the In-DB Connections Manager (Options > Advanced Options > Manage In-DB Connections).
Could not connect! Databricks returned HTTP code 403 Could not connect! Response body is empty Could not connect! Invalid response while retrieving Databricks clusters
Check to make sure that credentials are entered correctly.
Do the same credentials work outside of Alteryx?
If an HTTP Code is returned with the error, use the code as a guide to determine what may be incorrect. For example, the error "Databricks returned HTTP code 403" indicates an incorrect token.
An incorrect Account ID will return an empty response body.
Use theHow To: Configure a Databricks ConnectionKnowledge base article as a guide for finding the correct information.
Use curl for further troubleshooting.
Note: This may require assistance from an admin on the computer and/or IT.
When clicking on the "Connect" button, we make a call to retrieve the cluster names. That call is:
GET https://accountid.cloud.databricks.com/api/2.0/clusters/list
with accountid being the value entered in the Account ID field. The token is being sent for authorization.
machine login token password
curl -n https:///api/2.0/clusters/list or curl --netrc-file "netrc file" https:///api/2.0/clusters/list
Use --netrc-file instead of -n to point directly to the file.
Replace"netrc file" with the path to the netrc file containing the authentication information and with the .cloud.databricks.com domain name of the user's Databricks deployment.
Check to see if a proxy is interfering with the connection.
TRACERT www.google.com TRACERT
Replacing with the .cloud.databricks.com domain name of the user's Databricks deployment.
This will return the hops it takes to reach the destination. There will be some noise but you should be able to spot any proxies.