Connecting over a mobile network using SSH tunnel

Forum / General Discussions / Connecting over a mobile network using SSH tunnel


  • This topic has 1 reply, 2 voices, and was last updated 2 years ago by kroy.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #36131

    Hi guys, I would like to connect over a mobile network.

    My problem is basically the one described here:


    I’ve been reading that there is a workaround: SSH Tunnel.

    Can you please describe all the steps that I have to follow to connect 2 machines (with Ubuntu), one of them over a mobile network.

    Thanks in advance



    You have two Ubuntu: ubuntu-mobile (not available for connections from other network) and ubuntu-home (it’s in local network and it’s available for connections from your mobile phone and over internet). On ubuntu-home needs to be installed ssh server (sudo apt install openssh-server).

    Open terminal on ubuntu-mobile machine and create reverse tunnel:
    ssh -fN -R ubuntu-mobile-IP:14000:localhost:4000 username-ubuntu-home@ubuntu-home-IP
    ssh -fN -R *:14000:localhost:4000 username-ubuntu-home@ubuntu-home-IP

    The first command allows you to connect through SSH tunnel from ubuntu-home machine, the second – form any address on the Internet. To connect open NoMachine Player set as IP ubuntu-home-IP and 14000 as Port (where 14000 is any unused port before ssh tunneling on ubuntu-home machine).

Viewing 2 posts - 1 through 2 (of 2 total)

This topic was marked as solved, you can't post.