Skip to content

Commit

Permalink
support for slurm
Browse files Browse the repository at this point in the history
  • Loading branch information
ahs authored and ahs committed Sep 24, 2023
1 parent 612b468 commit 098b2b0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/xorbits/cluster/slurm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ port=16380
web_port=16379
echo "Starting SUPERVISOR at ${head_node}"
srun --nodes=1 --ntasks=1 -w "${head_node}" \
xorbits-supervisor -H "${head_node}" -p "${port}" -w "${web_port}" --log-dir /home/nfsdir/xiaoyu/ &
xorbits-supervisor -H "${head_node}" -p "${port}" -w "${web_port}" &
sleep 10
worker_num=$((SLURM_JOB_NUM_NODES - 1))
for ((i = 1; i <= worker_num; i++)); do
node_i=${nodes_array[$i]}
port_i=$((port + i))
echo "Starting WORKER $i at ${node_i}"
srun --nodes=1 --ntasks=1 -w "${node_i}" \
xorbits-worker -H "${node_i}" -p "${port_i}" -s "${head_node}":"${port}" --log-dir /home/nfsdir/xiaoyu/ &
xorbits-worker -H "${node_i}" -p "${port_i}" -s "${head_node}":"${port}" &
done
sleep 5
address=http://"${head_node}":"${web_port}"

0 comments on commit 098b2b0

Please sign in to comment.