Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

A windows host machine (which dynamically has the address 192.168.227.1) runs

  • (i) an ssh tunnel with port forwarding (forwards the port localhost:5432 with the following command: autossh.exe -M 2000 -L 5432:localhost:5432 server
  • (ii) vmware linux machine (ubuntu)

How can I access the 5432 port of the host machine from linux? The port forwarding binds 5432 port with the localhost (127.0.0.1) and not with the dynamically assigned ip address (192.168.227.1). This makes it impossible to access the port with 192.168.227.1:5432

Unfortunatelly I cannot do the port forwarding directly from the linux VM.

Comments?

share|improve this question

migrated from serverfault.com Sep 16 '13 at 22:24

This question came from our site for professional system and network administrators.

1 Answer 1

=) This are some easy easy points... If you look closer to your port forward -L you are using [nothing]:5432:localhost:5432 just replace nothing with the ip address that you want to have the port listening or, just add 0.0.0.0:5432:localhost:5432 server and you will have in all interfaces that port listening.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.