Hacker News new | ask | show | jobs
by maratc 1161 days ago
Pro tip: if you used ssh to get into host A and then another ssh to get from host A into host B, to break the A-B connection you need to issue `~~.`

("control up-arrow Q" song playing in the background.)

3 comments

Alternatively just use jump hosts: $(ssh -J bastion target)
Oh, I didn't know about the -J option. At $WORK, after ssh-ing onto the jump host, we've to do 'sudo -u special_user sudosh' (no password) before we ssh further. I don't suppose there's any way around that, is there?
And if you use host A like that enough you can also change the ssh escape key in your config.
Thanks.