Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Distributed worker manager doesn't use socket connection to infer worker ip #85

Open
Moelf opened this issue Oct 1, 2022 · 2 comments

Comments

@Moelf
Copy link

Moelf commented Oct 1, 2022

https://github.com/JuliaLang/julia/blob/0d00660a38f4d4049e12a97399e4ef613bf0d7dc/stdlib/Distributed/src/managers.jl#L568

for some reason we don't use the fact that we can call Sockets.getpeername() here, instead we read the stdout of the worker process.

This is problemmatic mainly because:

  1. the worker nodes always report the first IPv4 interface's address no matter if that's actually the interface it used to contact main node:
    https://github.com/JuliaLang/julia/blob/0d00660a38f4d4049e12a97399e4ef613bf0d7dc/stdlib/Sockets/src/addrinfo.jl#L272-L276

  2. the worker node may be running inside container (or whatever reason has virtual interface before everything else)

my questions: can we add a specialization for read_worker_host_port when config.io :: Sockets.TCPSocket?

@Moelf
Copy link
Author

Moelf commented Oct 1, 2022

bash-4.2$ route | grep '^default' | grep -o '[^ ]*$'
ens1f0.3604

shows that we should be using:

192.170.240.0

but the first IP address libuv came up with is 192.168.240.0;

I couldn't find how to look for the default interface in libuv

@Moelf
Copy link
Author

Moelf commented Oct 1, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant