Users
Search
Help
Sign Up
Sign In
Communities
Writing
Codidact Meta
The Great Outdoors
Photography & Video
Scientific Speculation
Cooking
Electrical Engineering
Judaism
Languages & Linguistics
Software Development
Mathematics
Christianity
Code Golf
Music
Physics
Linux Systems
Power Users
Tabletop RPGs
Community Proposals
tag:snake
search within a tag
answers:0
unanswered questions
user:xxxx
search by author id
score:0.5
posts with 0.5+ score
"snake oil"
exact phrase
votes:4
posts with 4+ votes
created:<1w
created < 1 week ago
post_type:xxxx
type of post
Search help
Notifications
Mark all as read
See all your notifications »
Users
Search
Help
Dashboard
Sign In
Sign Up
Q&A
Meta
Review Suggested Edit
You can't approve or reject suggested edits because you haven't yet earned the
Edit Posts
ability.
Return to post
Pending.
This suggested edit is pending review.
Suggested edit summary:
79 / 255
@
Canina's answer contains a good solution if you only want to reach a small number of hosts.
But requiring a port
(
local
though, not on the jumphost, so many users don't compete for resources)
for each host you want to reach doesn't scale to many hosts. It also requires you set the tunnel up before you need it
, t
hat's not good if you don't know which hosts you'll need to connect to.
In an earlier setup at the company I work for, we had a bunch of hosts
(and it constantly grew)
I could only reach through a jumphost,
t
o reach them I had a line like the following in my `.ssh/config` for a wildcard entry matching the hosts I couldn't reach directly:
ProxyCommand ssh <myuser>@<jumphost> nc -w1 %h %p
This made
ssh (I am - and also was back then - on a linux machine, using the
openssh
implementation)
connect to the jumphost and
on that
run `nc` which then proxied everything to the host I really wanted to connect to. I don't remember, but this probably required me to run an SSH-agent with forwarding enabled.
[
Canina's answer
][canina]
contains a good solution if you only want to reach a small number of hosts.
But requiring a port
[^
local
port]
for each host you want to reach doesn't scale to many hosts. It also requires you set the tunnel up before you need it
. T
hat's not good if you don't know which hosts you'll need to connect to.
In an earlier setup at the company I work for, we had a bunch of hosts I could only reach through a jumphost,
and the list constantly grew. T
o reach them
,
I had a line like the following in my `.ssh/config` for a wildcard entry matching the hosts I couldn't reach directly:
ProxyCommand ssh <myuser>@<jumphost> nc -w1 %h %p
This made
SSH[^
openssh
]
connect to the jumphost and run `nc`
on it,
which then proxied everything to the host I really wanted to connect to. I don't remember, but this probably required me to run an SSH-agent with forwarding enabled.
[^localport]: A local port, not one on the jumphost, so many users don't compete for resources.
[^openssh]: I am—and also was back then—on a Linux machine, using the OpenSSH implementation.
[canina]: https://linux.codidact.com/posts/282493/282494#answer-282494
Suggested
28 days ago
by
Michaelâ€