3
votes

I just installed h2o module on python 3.6.1... (Java version 8 Update 74 (build 1.8.0_74-b02) windows version 10 pro )

When I am giving the command h2o init() , it causing me connection error.

import h2o

h2o.init()

Checking whether there is an H2O instance running at http://localhost:54321..... not found. Attempting to start a local H2O server... Traceback (most recent call last): File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\site-packages\h2o\h2o.py", line 252, in init "connected.", "not found.")) File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\site-packages\h2o\backend\connection.py", line 318, in open conn._cluster = conn._test_connection(retries, messages=_msgs) File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\site-packages\h2o\backend\connection.py", line 588, in _test_connection % (self._base_url, max_retries, "\n".join(errors))) h2o.exceptions.H2OConnectionError: Could not establish link to the H2O cloud http://localhost:54321 after 5 retries [08:43.85] H2OConnectionError: Unexpected HTTP error: HTTPConnectionPool(host='localhost', port=54321): Max retries exceeded with url: /3/Cloud (Caused by NewConnectionError(': Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it',)) [08:46.12] H2OConnectionError: Unexpected HTTP error: HTTPConnectionPool(host='localhost', port=54321): Max retries exceeded with url: /3/Cloud (Caused by NewConnectionError(': Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it',)) [08:48.44] H2OConnectionError: Unexpected HTTP error: HTTPConnectionPool(host='localhost', port=54321): Max retries exceeded with url: /3/Cloud (Caused by NewConnectionError(': Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it',)) [08:50.75] H2OConnectionError: Unexpected HTTP error: HTTPConnectionPool(host='localhost', port=54321): Max retries exceeded with url: /3/Cloud (Caused by NewConnectionError(': Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it',)) [08:53.03] H2OConnectionError: Unexpected HTTP error: HTTPConnectionPool(host='localhost', port=54321): Max retries exceeded with url: /3/Cloud (Caused by NewConnectionError(': Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it',))

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "", line 1, in h2o.init() File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\site-packages\h2o\h2o.py", line 261, in init min_mem_size=mmin, ice_root=ice_root, port=port, extra_classpath=extra_classpath) File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\site-packages\h2o\backend\server.py", line 121, in start mmax=max_mem_size, mmin=min_mem_size) File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\site-packages\h2o\backend\server.py", line 250, in _launch_server jver_bytes = subprocess.check_output([java, "-version"], stderr=subprocess.STDOUT) File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\subprocess.py", line 336, in check_output **kwargs).stdout File "C:\Users\nshirsat\AppData\Local\Programs\Python\Python36\lib\subprocess.py", line 418, in run output=stdout, stderr=stderr) subprocess.CalledProcessError: Command '['C:\WINDOWS\system32\java.exe', '-version']' returned non-zero exit status 2.

===============================

I am using office laptop and I am not getting how to resolve the error. I search on internet with no luck.

I really appreciate your help in this.

Thanks & Regards,

Naresh

1
Hi Team, Please let me know any more info you need from my side.Naresh

1 Answers

0
votes

I had a similar problem.
Fixed it by uninstalling Java version 12 and installing Java version 8.
Then it worked perfectly.
Apparently Java 12 is not supported.