Support Questions

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

Cannot start Hiveserver2 - Python script has been killed due to timeout after waiting 900 secs

avatar
Rising Star

Hello,

I am trying to start Hiveserver2 but it is timing out with the error:

"Python script has been killed due to timeout after waiting 900 secs"

Tried to find something in the log file but there was no error.

Attaching the log file for reference.

Best Regards,

Rinku Singh.

1 ACCEPTED SOLUTION

avatar
Rising Star

Hello,

From the logs, I found that it was stuck updating the hdfs location.

So, I updated the hdfs location manually by running the command metatool -updateLocation

After that I was able to bring up the Hiveserver2 service.

Best Regards,

Rinku Singh.

View solution in original post

4 REPLIES 4

avatar

Just tweak the timeout number and see if error persist...

sed -e 's/\(agent.task.timeout=\).*/\12700/' \
        -e 's/\(agent.package.install.task.timeout=\).*/\12700/' \
        -i /etc/ambari-server/conf/ambari.properties

avatar
Rising Star

Hello @Mukesh Kumar

I don't think increasing the timeout number will help here. There must be something that is stopping it from start.

From the ambari-ui, I could see the below error:

Connection failed on host ip-172-31-31-251.us-west-2.compute.internal:10000 (Traceback (most recent call last):
  File "/var/lib/ambari-agent/cache/common-services/HIVE/0.12.0.2.0/package/alerts/alert_hive_thrift_port.py", line 200, in execute
    check_command_timeout=int(check_command_timeout))
  File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/hive_check.py", line 74, in check_thrift_port_sasl
    timeout=check_command_timeout)
  File "/usr/lib/python2.6/site-packages/resource_management/core/base.py", line 154, in __init__
    self.env.run()
  File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 160, in run
    self.run_action(resource, action)
  File "/usr/lib/python2.6/site-packages/resource_management/core/environment.py", line 124, in run_action
    provider_action()
  File "/usr/lib/python2.6/site-packages/resource_management/core/providers/system.py", line 238, in action_run
    tries=self.resource.tries, try_sleep=self.resource.try_sleep)
  File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 70, in inner
    result = function(command, **kwargs)
  File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 92, in checked_call
    tries=tries, try_sleep=try_sleep)
  File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 140, in _call_wrapper
    result = _call(command, **kwargs_copy)
  File "/usr/lib/python2.6/site-packages/resource_management/core/shell.py", line 291, in _call
    raise Fail(err_msg)
Fail: Execution of '! beeline -u 'jdbc:hive2://ip-172-31-31-251.us-west-2.compute.internal:10000/;transportMode=binary' -e '' 2>&1| awk '{print}'|grep -i -e 'Connection refused' -e 'Invalid URL'' returned 1. Error: Could not open client transport with JDBC Uri: jdbc:hive2://ip-172-31-31-251.us-west-2.compute.internal:10000/;transportMode=binary: java.net.ConnectException: Connection refused (state=08S01,code=0)
Error: Could not open client transport with JDBC Uri: jdbc:hive2://ip-172-31-31-251.us-west-2.compute.internal:10000/;transportMode=binary: java.net.ConnectException: Connection refused (state=08S01,code=0)
)

avatar

avatar
Rising Star

Hello,

From the logs, I found that it was stuck updating the hdfs location.

So, I updated the hdfs location manually by running the command metatool -updateLocation

After that I was able to bring up the Hiveserver2 service.

Best Regards,

Rinku Singh.