Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Can I use ssh to connect to another computer and have root acess to it that is in another state on a seperate network then the one I am on? if not is there any way to to that?
Would it be any different if the computers I wanted to access were behind a router?
Some one else I asked said that I would need to have the router forward port 22 to one of the computers and use ssh from that computer to reach the other ones. What do u think?
It'd probably be a good idea to setup a DynDNS account.
What you'll need to do to the router on the other machines is forward 22 on one machine, and then setup the other client to use a different port and forward that one to that machine. Then when you connect to the second computer use user@hostname:port and it should work fine.
If there's a different way to do this, someone please say so, however this is the only way I've known how to do this thus far.
It'd probably be a good idea to setup a DynDNS account.
What you'll need to do to the router on the other machines is forward 22 on one machine, and then setup the other client to use a different port and forward that one to that machine. Then when you connect to the second computer use user@hostnameort and it should work fine.
If there's a different way to do this, someone please say so, however this is the only way I've known how to do this thus far.
So:
[MY COMPUTER] ssh blablabla --> <router> (forwards port 22) --> [one of 4 computers] ssh blablabla --> [any of the other 3 computers]
Well, if your ISP gives you a dynamic IP address and not static, it's going to be constantly changing.
With a DynDNS account, you can get a hostname for yourself (such as computername.homelinux.net) that will make it easier for you to connect to.
You can then try some of their tools to automatically update their server with your renewed IP when you get a new IP.
Remembering hostnames is just easier than remembering what my IP changed to every time, but if you're on a static IP, then no worries.
I also thought you were going to have a different layout. You are going to ssh to one computer in the network, and then connect to any of the other three from that one. What I've done it setup different ports per computer, and saved them in putty. I then have hostnames for all of the computers just to make things easier for myself.
Looks like you've got everything wrapped up now, though.
Good luck.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.