If an explicitly mapped port is occupied, dstack will fail only after provisioning has been completed. We should acquire known ports (excluding dynamic mapping for the local backend) before creating instance and keep it till opening the ssh tunnel.