Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

hive issue in hdp 2.1

avatar

I am using HDP 2.1. In this HDP was working fine, now getting error:-

hive -e "show databases;" Logging initialized using configuration in file:/etc/hive/conf.dist/hive-log4j.p roperties FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTa sk. MetaException(message:Got exception: org.apache.thrift.transport.TTransportE xception java.net.SocketException: Connection reset)

Please help on urgent bases.

Thanks in advance.

1 ACCEPTED SOLUTION

avatar

Thanks everyone. I have resolved this issue with following option.

1) Took hive database backup from mysql.

2) Removed the hive from that node.

3) Added new node and hive installed on new node.

4) Restore the hive database to mysql.

And it's works. 🙂

View solution in original post

9 REPLIES 9

avatar

After run the hive in debug mode got the error:-

ERROR hive.log: Converting exception to MetaException 16/11/15 09:44:25 [main]: ERROR exec.DDLTask: org.apache.hadoop.hive.ql.metadata.HiveException: MetaException(message:Got exception: org.apache.thrift.transport.TTransportException java.net.SocketException: Broken pipe

my databses is on same machine and I am able to access the mysql with hive user.

avatar
Explorer

@Ashnee Sharma Try restarting Hiveserver2. Also are you able to run Hive cli ?

avatar

I tried with hiveserver2 restart and hive cli in coming but command not working.

avatar
Contributor

from the above: connection reset / broken pipe - I would recommend to also check some basic things like:

* `netstat -npl` shows the metastore and hiveserver2 as running and listening on the port... also check that if you shutdown the hiveserver2 and metastore those ports are closed - i would guess that some other application have "hijacked" the hiveserver2 or the metastore port - and the application listening on that port doesn't speak the "hive" protocol 😉

* loopback device is up

* the network is working / hostnames

can you attach the hiveserver2 and/or metastore logs which could possibly cause this?

avatar

@zhaindrich

I have checked everything and working fine. I have checked the port also only the hive server application isusing the same port.

avatar

@zhaindrich

The logs says:-

p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 11.0px Monaco; color: #f5f5f5; background-color: #000000}

Unable to open a test connection to the given database. JDBC url = jdbc:mysql://ashnee2.datametica.com/hive?createDatabaseIfNotExist=true, username = hive. Terminating connection pool (set lazyInit to true if you expect to start your database after your app). Original Exception: ------

java.sql.SQLException: Access denied for user 'hive'@'ashnee2.datametica.com' (using password: YES)

I have checked this error but no luck.

I have tried to access the database and able to access.

avatar
Contributor

can you check that the database password in the xml file(javax.jdo.option.ConnectionPassword) - is it the correct password? (maybe: try to remove any whitespaces before/after the password if there are any)

avatar

@zhaindrich

I checked and already tried with this option. Not worked for me.

avatar

Thanks everyone. I have resolved this issue with following option.

1) Took hive database backup from mysql.

2) Removed the hive from that node.

3) Added new node and hive installed on new node.

4) Restore the hive database to mysql.

And it's works. 🙂