Skip to content

Can't connect to remote nodes via SSH tunnel #173

@StormBytePP

Description

@StormBytePP

I am learning and currently trying erlyberly in my local network server and I am facing currently an issue that I can't connect to node despite it is being listed correctly.

For achieving this, I have a little ssh tunnel to the machine created with the command

ssh -N -L 9001:localhost:9001 -L 4369:localhost:4369 -L 4000:localhost:4000 -L 45437:localhost:45437 my_user@my_host

Then, on server I have a little phoenix test run by

iex --name bench_test@127.0.0.1 --cookie 123 --erl "-kernel inet_dist_listen_min 9001 inet_dist_listen_max 9001" -S mix phx.server

I can see the node with

epmd -names
epmd: up and running on port 4369 with data:
name bench_test at port 9001

and I can run the :observer on the tunnel as well as loading the page via localhost:4000 (which is redirected to the tunnel)

But when I execute java -jar target/*runnable.jar despide I see the node in the list (with the correct Cookie), I get "Cannot connect to peer node".

Am I missing a port redirect or something else?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions