Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

-I have opened port 8080 and I can access it with and also no-ip domain -Installed vsftpd -Opened port 80,8080,20,21,22 and 11000-11100

However I can't ssh to it. I have another sever listening on 80 and with same settings ssh works fine.

I appreciate your help.

Edit: I have not touched port 22 for ssh, httpd is listening on port 8080

share|improve this question
up vote 1 down vote accepted

You will have to use another port for ssh on the second server as well. Pick one and forward that. Like if you choose port 23 then you forward port 23 to the second server and connect to

ssh -p23

share|improve this answer
I open port 23 by editing sshd_config, restarted sshd, add 23 to iptables, forwarded port 23 on router and still no luck :( – john206 Mar 20 '12 at 23:14
Can you access it from your LAN? – Andreas Hagen Mar 21 '12 at 23:12
No unfortunately I can't, I'm able to access via ftp tho. I changed the port in sshd config and restarted it, still I get the message, connection was refused from port 23 – john206 Mar 22 '12 at 2:16
Have you disabled your firewall, or opened port 23 in it? – Andreas Hagen Mar 22 '12 at 7:48
yes I have opened port 23, I edited iptables like this:-A INPUT -m state --state NEW -m tcp -p tcp --dport 23 -j ACCEPT and restart iptables – john206 Mar 22 '12 at 16:47

What is listening on 8080? That's typically some sort of httpd. For ssh, you'll need to use port 22.

share|improve this answer
yes httpd is listening on 8080, i used ssh user@ it doesnt work – john206 Mar 20 '12 at 22:38
You don't ssh to an httpd. You ssh to an sshd. I believe you're quite confused here. What exactly are you trying to do? – EEAA Mar 20 '12 at 22:40
well may be i said it in a confusing way. On my first server, i forwarded my port 80 and linked it to no-ip dns. so i can access my site from and i can ssh to it using ssh On my second server, since I can't forward port 80 to other ip address, I opened port 8080. so in httpd.conf, i have Listen:8080, so now I can access website two like . Then I want to ssh to second server using ssh but I don't know how. – john206 Mar 20 '12 at 22:44
Well, you'll need to forward another port to 22 on the second server, say 2222 for example. Then from outside, you'd ssh via $ ssh -p2222 – EEAA Mar 20 '12 at 22:49
could you please tell me how to forward port 2222 to 22? Which file should I modify? Vsftpd and iptables? If you also have link that puts me on the right path would be great. Thanks for your patience ErikA – john206 Mar 20 '12 at 22:53

Your Answer


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.