分布式计算框架

2023-06-28

Ray

官方文档:https://docs.ray.io/en/master/

快速安装

安装手册:https://docs.ray.io/en/master/ray-overview/installation.html

集群部署

Head节点 (m1):

ray start --head --port=6333 --dashboard-host=0.0.0.0 --node-ip-address=10.147.19.20 --num-cpus=3 --num-gpus=1

Slave节点

(bric):

ray start --address=10.147.19.20:6333 --node-ip-address=10.147.19.134 --num-cpus=3 --num-gpus=0

(m4):

ray start --address=10.147.19.20:6333 --node-ip-address=10.147.19.230 --num-cpus=8 --num-gpus=0

注意事项

1.ray 2.x版本与3.x版本不兼容,启动会报错,而且不同的python版本也不兼容!!!:

RuntimeError: Version mismatch: The cluster was started with:
    Ray: 2.4.0
    Python: 3.8.10
This process on node 10.147.19.20 was started with:
    Ray: 3.0.0.dev0
    Python: 3.8.10

2.遇到过一次WSL2下启动节点,但注册失败,检查环境日志无果,重启系统后成功。

可能是端口占用,或特定文件未被关闭。