ray icon indicating copy to clipboard operation
ray copied to clipboard

Incorrect port forwarding in `ray dashboard`

Open rohitrawat opened this issue 4 years ago • 3 comments

https://github.com/ray-project/ray/blob/6a227ae50132639552b7d3601cc828c28143e2cb/python/ray/autoscaler/_private/command_runner.py#L530

^ incorrectly forwards the remote dashboard port. This bug is not visible if we are trying to forward the same remote port to the same local port. The correct port forward syntax is: ssh -L local_port:destination_server_ip:remote_port ssh_server_hostname

I've verified that this currently doesn't work:

ray dashboard -p 9999 --remote-port 8265 ~/raygit/python/ray/autoscaler/gcp/example-full.yaml snip 2020-09-22 23:00:17,283 VVINFO command_runner.py:552 -- Full command is ssh -tt -L 8265:localhost:9999 -i /root/.ssh/ray-autoscaler_gcp_us-west1_lowsodium-214622_ubuntu_0.pem -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o IdentitiesOnly=yes -o ExitOnForwardFailure=yes -o ServerAliveInterval=5 -o ServerAliveCountMax=3 -o ControlMaster=auto -o ControlPath=/tmp/ray_ssh_63a9f0ea7b/c21f969b5f/%C -o ControlPersist=10s -o ConnectTimeout=120s ubuntu@ip while true; do sleep 86400; done

rohitrawat avatar Sep 22 '20 23:09 rohitrawat

cc @wuisawesome

rkooo567 avatar Sep 23 '20 05:09 rkooo567

cc @mfitton

wuisawesome avatar Sep 23 '20 06:09 wuisawesome

cc: @alanwguo

scottsun94 avatar Oct 25 '22 05:10 scottsun94

I think this is fixed in main: https://github.com/ray-project/ray/blob/master/python/ray/autoscaler/_private/command_runner.py#L352

omrishiv avatar Jun 19 '24 20:06 omrishiv

I agree

Closed by #44973

wuisawesome avatar Jun 19 '24 22:06 wuisawesome