0

I'm trying to execute a command from Server 1 through server 2 on a machine that's on the outside world is this possible via ssh tunnel forwarding? I made a little drawing as an example.

enter image description here

I've tried it with

ssh -L PORT:IP:PORT user@remotemachine "hostname" 

When i try this i get the wrong hostname back

1

1 Answer 1

0

ProxyJump function of SSH should be able to do what you need. Basically your server 2 would be the jump station to reach your server 3. You have a good article available on redhat's website : https://www.redhat.com/sysadmin/ssh-proxy-bastion-proxyjump

1
  • Thanks, this solved my issue! Commented Jul 27, 2022 at 12:12

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.