Support Questions

Find answers, ask questions, and share your expertise

Cannot connect to Impala via JDBC: Connection timeout

avatar
Explorer

I've followed the Getting Started Guide, everything OK, and now I need to connect to Impala cluster via JDBC.

I have the following configuration:

Manager Node (cloudera1)54.175.35.127 
Worker Node 1 (cloudera2)54.175.22.26 
Worker Node 2 (cloudera3)54.175.19.19 
Worker Node 3 (cloudera4)54.175.18.49

I have the following connection string:

jdbc:impala://54.175.22.26:21050/default;user=my_user;password=my_psw

 

What's the right pair IP address -TCP port that I should use to connect?

 

Thank you

cghersi

1 ACCEPTED SOLUTION

avatar
Guru
There's a firewall set up that may be your problem. The Live clusters only
expose ports that are considered secure and are required for the tutorials.
If you go beyond that, you may need to open some ports in the firewall, and
then you need to make sure you configure the services to be secure enough
to meet your needs. The authentication configuration with Hive and Impala
is the default, so the firewall blocks access to those ports by default.

The firewall in question is the Network ACL. You can find the ID of the
specific ACL in the Resources Tab in CloudFormation, and then edit the
configuration of the Network ACL from the EC2 Management Console. Remember
the Network ACL is stateless, meaning it is unaware of established
connections, etc. and filters individual packets based on their ports.

The EC2 security group and any operating-system-level firewall should not
be getting in the way here, but keep those in mind as other options if you
need to change the networking configuration. Remember that EC2 security
groups are stateful, but they apply to traffic even between the nodes of
your cluster.

I'd also make sure you've confirmed the credentials and other details of
your connection string by connecting from a node in the cluster, so you can
differentiate between the firewall blocking the connection and any other
potential problems.



View solution in original post

5 REPLIES 5

avatar
Explorer

Update,

I have tried also with Hive, setting this connection string:

jdbc:hive://54.175.22.26:10000/default;user=my_user;password=my_psw

 

Again, no luck.

 

Thank you

cghersi

avatar
Guru
There's a firewall set up that may be your problem. The Live clusters only
expose ports that are considered secure and are required for the tutorials.
If you go beyond that, you may need to open some ports in the firewall, and
then you need to make sure you configure the services to be secure enough
to meet your needs. The authentication configuration with Hive and Impala
is the default, so the firewall blocks access to those ports by default.

The firewall in question is the Network ACL. You can find the ID of the
specific ACL in the Resources Tab in CloudFormation, and then edit the
configuration of the Network ACL from the EC2 Management Console. Remember
the Network ACL is stateless, meaning it is unaware of established
connections, etc. and filters individual packets based on their ports.

The EC2 security group and any operating-system-level firewall should not
be getting in the way here, but keep those in mind as other options if you
need to change the networking configuration. Remember that EC2 security
groups are stateful, but they apply to traffic even between the nodes of
your cluster.

I'd also make sure you've confirmed the credentials and other details of
your connection string by connecting from a node in the cluster, so you can
differentiate between the firewall blocking the connection and any other
potential problems.



avatar
Explorer

Hi Sean, than kyou for your reply: it worked with Impala, but with Hive I'm still encountering the same issue, on port 10000.

Moreover, just as user feedback, it is extremely difficult to find which are the right ports to connect to from an external client: could you please provide some reference where I can find such information on Cloudera Manager or similar UI?

Thank you!

cghersi

avatar
Explorer

Hi Sean,

with respect to the ports used to connect to Hive/Impala etc., I found this document very useful: http://www.cloudera.com/content/cloudera/en/documentation/archives/cloudera-manager-4/v4-5-4/Configu...

 

I still have problems anyway with the connection to Hive.

Could you help me please?

Thank you

cghersi

avatar
Explorer

Hi Sean,

I'm still facing the same problem with Hive connection on port 10000.

Any other clue or advice?

Thank you very much!

cghersi