Client('127.0.0.1:8786') fails ConnectionRefusedError
See original GitHub issuedask = 2.8.1 distributed = 2.8.1 os = ManjaroLinux 18.1.3 python = 3.7.3 (conda-forge)
from dask.distributed import Client
Client('127.0.0.1:8786')
fails with
Traceback (most recent call last):
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/comm/core.py", line 222, in connect
_raise(error)
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/comm/core.py", line 205, in _raise
raise IOError(msg)
OSError: Timed out trying to connect to 'tcp://127.0.0.1:8786' after 10 s: in <distributed.comm.tcp.TCPConnector object at 0x7f87b55c0b70>: ConnectionRefusedError: [Errno 111] Connection refused
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/client.py", line 726, in __init__
self.start(timeout=timeout)
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/client.py", line 891, in start
sync(self.loop, self._start, **kwargs)
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/utils.py", line 334, in sync
raise exc.with_traceback(tb)
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/utils.py", line 318, in f
result[0] = yield future
File "/.../miniconda3/.../lib/python3.7/site-packages/tornado/gen.py", line 735, in run
value = future.result()
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/client.py", line 984, in _start
await self._ensure_connected(timeout=timeout)
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/client.py", line 1041, in _ensure_connected
connection_args=self.connection_args,
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/comm/core.py", line 231, in connect
_raise(error)
File "/.../miniconda3/.../lib/python3.7/site-packages/distributed/comm/core.py", line 205, in _raise
raise IOError(msg)
OSError: Timed out trying to connect to 'tcp://127.0.0.1:8786' after 10 s: Timed out trying to connect to 'tcp://127.0.0.1:8786' after 10 s: in <distributed.comm.tcp.TCPConnector object at 0x7f87b55c0b70>: ConnectionRefusedError: [Errno 111] Connection refused
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Python socket ConnectionRefusedError but only when not on ...
The problem is: When I run server as on ip 127.0.0.1 it's everything alright. I can send message from client to server and...
Read more >How to Fix the SSH "Connection Refused" Error - Kinsta
Are you experiecing the "Connection refused" error when connecting via SSH? Learn what's causing the issue and follow these steps to get it ......
Read more >How to Fix ECONNREFUSED – connection refused by server ...
Learn how to fix the SSH Connection Refused error using three simple methods in this video tutorial.
Read more >insync@groups.io | Cannot connect to gateway
Can someone give me some pointers to diagnose this? I cannot connect to the gateway. It is inside a Docker container running on...
Read more >What is ConnectionRefusedError Errno 111 Connection ...
The ConnectionRefusedError errno 111 connection refused is a socket error that results when there is a failure in the establishment of ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ahh. Now I see. I meant this: https://distributed.dask.org/en/latest/client.html
And now reading better I see that:
After we setup a cluster, we initialize a Client
. My bad.I was using
LocalCluster()
in the beginning but then I started to get some weird problems and noticed thatClient()
was callingLocalCluster
with some arguments, hence started to useClient
.This was never an issue, sorry for the entropy.
Could you share the documentation page that mention this? If you specify the address of the cluster the assumption is that you are connecting to an existing cluster.
If you want to create your own cluster with your own settings I recommend looking at
LocalCluster
.