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.
I run Red Hat 7.3 box. I use LinkSys DSL router MODEL: BEFSR41.
So I want to enable the ssh connection to the box using port 22.
In order to do that, I need to make changes to the FORWARDING option in LinkSYS
So I did:
#1 htp://192.168.1.1 // login
#2 click Advance
#3 click Forwarding
#4 Enter Port 22 on Service Port Range, looks Like
Service Port Rande 0 ~ 22 IP Address 192.168.1.1
#5 Click APPLY
However, when I try connect remotely to the box it can't connect..
I typed the command to connect: ssh -l my_Ip_address
You're not indicating that you forwarded ports 0 through 22 are you? That won't keep SSH from working but it's more ports than you need, you can do just 22 - 22. On newer Linksys firmware make sure there is a checkmark in the "enable" box at the right. Also make sure you've chosen protocol TCP, not UDP. Last but not least, a -l parameter specifies what username to ssh as in case it's different than what you're logged in as now.
Firewall rule blocking you? Try "ipchains -L" and "iptables -L" to list current rules.
Originally posted by wdingus You're not indicating that you forwarded ports 0 through 22 are you? That won't keep SSH from working but it's more ports than you need, you can do just 22 - 22. On newer Linksys firmware make sure there is a checkmark in the "enable" box at the right. Also make sure you've chosen protocol TCP, not UDP. Last but not least, a -l parameter specifies what username to ssh as in case it's different than what you're logged in as now.
Firewall rule blocking you? Try "ipchains -L" and "iptables -L" to list current rules.
Good luck!
I don't have firewall ..
So in order to connect remotely to the server I need to do the following:
Not sure I understand.. If someone else knows the password for that account, sure they can login. If you forward the port int he Linksys then anyone can connect to it. The thing to do is to keep the password secure and keep the version of SSH up to date (security patches, etc...).
Originally posted by mikeshn I don't have firewall ..
So in order to connect remotely to the server I need to do the following:
ssh -l username remote_IP_number
Correct?
Thanks
Most likely this didn't work for you cause you would want to put that in this format:
ssh username@host_or_ipnumber
When you made a space between the username and remote IP number, ssh thought most likely it was trying to connect to your username like if it was a host computer.
mikeshn, your forwarding that to 192.168.1.1, which is the router's default IP. You have to forward it to the IP of the computer on your network that you want SSH to connect to.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.