Add ability to specify worker and driver ports#7833
Add ability to specify worker and driver ports#7833edoakes merged 18 commits intoray-project:masterfrom
Conversation
|
Can one of the admins verify this patch? |
|
Test PASSed. |
|
Test FAILed. |
|
Test FAILed. |
|
Can we set this by default? Would be great to say you just need to allow this port range out of the box. |
src/ray/core_worker/core_worker.cc
Outdated
| task_execution_callback_(task_execution_callback), | ||
| resource_ids_(new ResourceMappingType()), | ||
| grpc_service_(io_service_, *this) { | ||
| RAY_LOG(ERROR) << "Starting worker on port: " << worker_port; |
There was a problem hiding this comment.
| RAY_LOG(ERROR) << "Starting worker on port: " << worker_port; | |
| RAY_LOG(DEBUG) << "Starting worker on port: " << worker_port; |
|
@clarkzinzow this will now handle allocating driver ports as well as worker ports, hope that works for you! |
|
Test FAILed. |
|
Test FAILed. |
|
Test PASSed. |
|
Test PASSed. |
|
Test FAILed. |
|
Test FAILed. |
|
Test FAILed. |
|
Test FAILed. |
|
Test PASSed. |
)" This reverts commit 9f751ff.
…roject#7833)" (ray-project#8069)" This reverts commit 90ef585.
|
@arsedler9 yes, I've been working on this intermittently. Unfortunately there are some very frustrating issues in our CI that I'm wrestling against. I will do my best to have it in this week. Sorry for the delay. |
Why are these changes needed?
Now that each worker and driver has its own gRPC server, this can cause problems for users running in environments with firewalls blocking some ports. This adds the ability to specify a range of ports that workers will bind on, as well as the port that the driver process binds on.
Worker ports can be specified as a range via:
ray start --min-worker-port=15000 --max-worker-port=16000. This is not surfaced inray.init().The raylet tracks which of the ports are used - when workers and drivers connect to it, it will provide a port that they should bind on.
By default, the range is set to
--min-worker-port=10000and--max-worker-port=10999.Related issue number
Closes #7632
Checks
scripts/format.shto lint the changes in this PR.