Skip to content

Nmap or gtfo


When setting up a new server for a Rails application, it is a good idea to see what ports are open in order to configure appropriate firewall rules.

An open source tool called ‘nmap‘ comes in real handy for just such a thing!

After installing nmap ($ sudo apt-get install nmap on Ubuntu,) running a basic scan against a remote host is simple:
$ nmap [ip of remote host]
$ nmap

The output looks like this:
Starting Nmap 5.00 ( ) at 2011-03-28 20:39 MDT
Interesting ports on (
Not shown: 993 closed ports
22/tcp open ssh
80/tcp open http
135/tcp filtered msrpc
... [more open ports]
Nmap done: 1 IP address (1 host up) scanned in 26.05 seconds

Now we can proceed to lock down the irrelevant ports.


  1. Ok, I tried all this, but the dishwasher still won’t start….

    • seeflanigan permalink

      Hahah try rebooting it three times 🙂

      Yeah this is the trouble with me only having 1 blog. Sometimes it gets real nerdy up in here.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: