Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Hive-Server2

Highlighted

Hive-Server2

New Contributor

I have a CDH 5.3 instance. 

I start the hive-server2 by first starting the hive-metastore and then the hive-server from command line. 

After this I use beeline to connect to my hive-server2 but apparently it is not able to so. 

Could not open connection to jdbc:hive2://localhost:10000: java.net.ConnectException: Connection refused (state=08S01,code=0)

 

Another issue, I tried to see if the hive-server2 was listening on port 10000. 

I did " sudo netstat -tulpn | grep :10000" but none of the applications came up. 

 

Any help will be appreciated. 

 

5 REPLIES 5
Highlighted

Re: Hive-Server2

Master Collaborator
You mentioned you were starting "hive-server" from the command-line, but
that is the original Hive server. "hive-server2" is a separate service.

Highlighted

Re: Hive-Server2

New Contributor

What I meant was I start the hive-server2. 

 

Step 1: Starting the hive-metastore : sudo service hive-metastore start 

Status: Started [OK] 

 

Step2: Starting hiverserver2 :  sudo service hive-server2 start 

Status: Started [OK] 

Highlighted

Re: Hive-Server2

New Contributor

I have the same issue, any ideas why when hive-server2 is started up it doesn't listen on port 10000, I can see the java process running but just not listening on port 10000

Re: Hive-Server2

Please try to execute this command 

 

# /sbin/iptables -A INPUT -m state --state NEW -m tcp -p tcp --dport 1000 -j ACCEPT


# service iptables save

 

Latter check whether this port is listening or not, if so then execute 

 

#beeline

beeline > ! connect xxxx

 

Thanks

Kishore

Highlighted

Re: Hive-Server2

New Contributor

Thanks for your reply Kishore. I eventually worked it out, it was to do with metastore not being able to log into mysql and I failed to initially look at the metastore logs to make sure it started up correctly. Thanks for your help!

Don't have an account?
Coming from Hortonworks? Activate your account here