Setting up Athena connection in VSCode

0

I am trying to set-up Athena connection in VSCode.

When I do Test Connection, I get this error

Error opening connection Inaccessible host: `athena.us-east-1.amazonaws.com'. This service may not be available in the `us-east-1' region.

I tried this successfully

nc -v athena.us-east-1.amazonaws.com 443 Connection to athena.us-east-1.amazonaws.com port 443 [tcp/https] succeeded!

How can I fix this error

Athena-in-VSCode

adbdkb
질문됨 일 년 전1561회 조회
1개 답변
0

Hello,

I understand that you are getting Error opening connection Inaccessible host: athena.us-east-1.amazonaws.com'. This service may not be available in the us-east-1' region. When you perform a test connection while Setting up Athena connection in VSCode.

Usually this error is more related to networking but as mentioned, you are succeeded to check the connectivity with the Athena endpoint. So, here the networking aspect does not seem to be causing the problem. It is also possible for endpoints to be inaccessible once in a while.

I tried replicating in my test environment and I was successfully able to connect with Athena from VSCode in us-east-1 region without any issue. So, I believe that it can be the intermittent issue for you.

Further you can also check with these:

  1. Try with disconnecting the VPN if you are connected with any.
  2. Try with latest version of VSCode.

Also, please open a support ticket, if you are facing this issue frequently/continously.

Enter image description here

Below is the JSON for the successful connection: { "connectionMethod": "Profile", "previewLimit": 50, "driver": "driver.athena", "name": "Test", "workgroup": "primary", "region": "us-east-1", "outputLocation": "s3://bucket_name/ ", "profile": "default", "group": "Test" }

AWS
지원 엔지니어
답변함 일 년 전
  • I do have the latest version of VSCode - it was 1.78. updated today to Version: 1.78.1. Also, after your suggestion, I did try disconnecting from VPN and it worked. But, I have to be connected to VPN to do my other tasks. Is there a way to set-up that I can still connect even though I am connected to VPN? Thanks

  • One other test I did was to run this script from terminal on my Mac - from this link https://stackoverflow.com/questions/43338442/command-line-tool-to-access-amazon-athena and it runs without any issues even when I am connected to VPN. So, is there a set-up I can do in VSCode that will allow me to connect to Athena even when I am connected to VPN?

  • One other observation - And when I tried to set-up a connection from dBeaver to Athena, I had to add these extra user parameters when looking at the driver settings - AwsCredentialsProviderArguments, AwsCredentialsProviderClass, UseResultsetStreaming, Workgroup, ageforResultReuse, enableResultReuse. Do we need to do something similar on VSCode, and how would we define those in VSCode. Of these the Workgroup is part of the connection definition, but do we need to add any other and where?

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인