Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

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 a broadband internet connection. I have an wireless modem (Airtel India). I don't have a static ip address. I want to host a ssh/web/ftp server to be visible to the outside world just for testing and learning purpose so I can ask my friend to connect to my current ip address and test. My modem has an admin interface which allows to port forward and open ports. modem Configuration

I set up ssh server as shown and checked if port 22 is open using this website , Port Scan

And port 22 is open. I have an openssh server running and it works if i do, ssh balki@ which is my local ip address but doesn't work if i do ssh balki@122.xx.xx.xx where 122.xx.xx.xx is my external ip address of my modem which i checked from Since it looks like the port is open, I wonder if there is some setting I need to change in my server config to expose my server. How should I go about solving this?

share|improve this question
up vote 2 down vote accepted

It can be that your router does not support you connecting from your internal network to your external IP address, unfortunately some routers cannot route that.

You can try visiting this website: it will perform a portscan on the IP address you're coming from, so given that you come from the same IP address as your server, then you should be able to see whether or not port 22 is open to the world.

The scan might take a few mins to complete.

share|improve this answer
Thanks, my ssh server works from outside but not for me. – balki Feb 13 '11 at 13:02

When doing ssh @WAN_IP it will not work from within the LAN. It is a routing issue and I do not want to get into the details of that. You can use tcpdump to figure out the problem.

Secondly, if you want to host a website/ssh/ftp server on a dynamic Ip it is possible. I host mine using Airtel. If you have your own domain you can use Otherwise Dyndns provides an option of creating a subdomain for the number of domains listed.

There are a couple of ways you can do this.
a. you can use your router in bridge mode and have your linux box make the PPOE connection so that the public IP is directly assigned to the Linux box. Then you can use the Linux box for doing NAT.
b. (Easier than the first0Telnet into the modem/router and you will have access to a host of other option which are not listed in the web interface. For telnetting do "telnet ROUTER_IP" username by default is usually admin and password is password. There you can use the DMZ option. in DMZ all ports are exposed to the internet (The password will be the same as the one you use to login to the web interface). You start a service and can access it from anywhere without making any other change.

share|improve this answer
thanks for the links. The wireless modem is shared by 3 laptops, now how will the DMZ option work? whose server is used?. one more question, is there a easy way to find my external ip? Currently I use to find out. – balki Feb 13 '11 at 17:22
For DMZ telnet into your router/modem. It has an option of configuring DMZ. – Sameer Apr 30 '12 at 17:30

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.