SSH tunnel with different ssh port

Netorica

I am trying to make a ssh tunnel connection to a remote server that has different SSH port.

My PC

hostname: fooserver.com

IP address: 10.25.0.186

SSH port: 63354

My Remote PC

hostname: barserver.com

IP address: 10.26.0.183

SSH port: 63354

Now I want to connect in my Remote PC's MySQL server by using "localhost" by doing the SSH tunnel command below.

ssh -L 3306:localhost:3306 [email protected]

But after issuing the command above it show an error after few moments.

connect to host barserver.com port 22: Network is unreachable

It's very obvious that my PC tries to connect to SSH standard port but remote PC is running its SSH port to 63354. How can set the ssh port in the ssh tunnel command

I tried the following below.

ssh -L 3306:localhost:3306 [email protected]:63354

but it says its an invalid hostname.

MadHatter

Try ssh -L 3306:localhost:3306 -p 63354 [email protected]

이 기사는 인터넷에서 수집됩니다. 재 인쇄 할 때 출처를 알려주십시오.

침해가 발생한 경우 연락 주시기 바랍니다[email protected] 삭제

에서 수정
0

몇 마디 만하겠습니다

0리뷰
로그인참여 후 검토

관련 기사

분류에서Dev

ssh-copy-id different port

분류에서Dev

SSH reverse tunnel into Docker container

분류에서Dev

Notepad++ NppFTP SSH Tunnel

분류에서Dev

SSH port not working

분류에서Dev

forward all mysql traffic to a ssh tunnel

분류에서Dev

How to make an SSH tunnel publicly accessible?

분류에서Dev

Destroy ssh tunnel if exists and create new one

분류에서Dev

Expose a mysql server over an ssh tunnel

분류에서Dev

Login with SSH authorized key with changed SSH port

분류에서Dev

Restrict access to port forwarding in ssh

분류에서Dev

How do I route my internet through a SSH tunnel?

분류에서Dev

SSH fails to connect on private interface over IPSec tunnel

분류에서Dev

RDP over SSH Tunnel through intermediate Linux server

분류에서Dev

Tunnel all remote ports through SSH to local hostname

분류에서Dev

Force SSH server to always and only tunnel to telnet server

분류에서Dev

How to release ports on the SSH server when a reverse ssh tunnel disconnects abruptly/uncleanly?

분류에서Dev

Windows Subsystem for Linux & SSH Port Forwarding

분류에서Dev

How do I remove an SSH forwarded port

분류에서Dev

Forward SSH port - Connect from other place

분류에서Dev

$SSH_CONNECTION Does not display the IP addresses or port port numbers of ssh cnnections

분류에서Dev

ssh tunnel-bind : 이미 사용중인 주소

분류에서Dev

연결 후 tunnel-ssh에서 오류가 발생 함

분류에서Dev

How to create SSH tunnel with PuTTY to connect Neo4j database

분류에서Dev

How do to bind x11vnc to localhost only and tunnel through SSH?

분류에서Dev

How to configure ssh to use different key?

분류에서Dev

ssh-copy-id to different remote hosts

분류에서Dev

aws ec2 ssh 오류 :`ssh : connect to host x port 22 : Operation timed out`

분류에서Dev

SSH into server on network - and then access a web interface (ip only, no port)

분류에서Dev

How to redirect all traffic except SSH to one local port with iptables

Related 관련 기사

  1. 1

    ssh-copy-id different port

  2. 2

    SSH reverse tunnel into Docker container

  3. 3

    Notepad++ NppFTP SSH Tunnel

  4. 4

    SSH port not working

  5. 5

    forward all mysql traffic to a ssh tunnel

  6. 6

    How to make an SSH tunnel publicly accessible?

  7. 7

    Destroy ssh tunnel if exists and create new one

  8. 8

    Expose a mysql server over an ssh tunnel

  9. 9

    Login with SSH authorized key with changed SSH port

  10. 10

    Restrict access to port forwarding in ssh

  11. 11

    How do I route my internet through a SSH tunnel?

  12. 12

    SSH fails to connect on private interface over IPSec tunnel

  13. 13

    RDP over SSH Tunnel through intermediate Linux server

  14. 14

    Tunnel all remote ports through SSH to local hostname

  15. 15

    Force SSH server to always and only tunnel to telnet server

  16. 16

    How to release ports on the SSH server when a reverse ssh tunnel disconnects abruptly/uncleanly?

  17. 17

    Windows Subsystem for Linux & SSH Port Forwarding

  18. 18

    How do I remove an SSH forwarded port

  19. 19

    Forward SSH port - Connect from other place

  20. 20

    $SSH_CONNECTION Does not display the IP addresses or port port numbers of ssh cnnections

  21. 21

    ssh tunnel-bind : 이미 사용중인 주소

  22. 22

    연결 후 tunnel-ssh에서 오류가 발생 함

  23. 23

    How to create SSH tunnel with PuTTY to connect Neo4j database

  24. 24

    How do to bind x11vnc to localhost only and tunnel through SSH?

  25. 25

    How to configure ssh to use different key?

  26. 26

    ssh-copy-id to different remote hosts

  27. 27

    aws ec2 ssh 오류 :`ssh : connect to host x port 22 : Operation timed out`

  28. 28

    SSH into server on network - and then access a web interface (ip only, no port)

  29. 29

    How to redirect all traffic except SSH to one local port with iptables

뜨겁다태그

보관