Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

super_kev

macrumors 6502
Original poster
Jan 12, 2005
356
2
USofA
I'm curious if there is an app (or terminal commands) out there that will respond to certain port to let the other side know that the port is active?

For example, I'm having a tough time trying to figure out if the router I'm using is at fault, or if there is some quirk in the system that's not allowing the data through. If I can have an application on Mac #1 (behind the router in question) that I can dial in a port to force the computer to respond to (even if there is no service that is asking for that port), that would be great. Then I can telnet the IP and port of Mac #1 from outside the network on Mac #2 to see if the router is forwarding the port correctly. It's doing other ports except this one (3306) so I'm trying to figure out what's going on.

Thanks.
 

belvdr

macrumors 603
Aug 15, 2005
5,945
1,372
If it's TCP 3306, then do a:
Code:
telnet <IP> 3306

using the internal IP on the internal network, then do the same with the external IP from the external network. If it works on the internal, but doesn't connect from the external, your port forwarding setup is not working.

If it is UDP 3306, use nmap to scan for that port:
Code:
nmap -p 3306 -u <IP>
using both the internal IP and external IP as in the TCP test above.
 

super_kev

macrumors 6502
Original poster
Jan 12, 2005
356
2
USofA
Thanks.

Does OS X normally block outside network IP address from connecting to port 3306 (MySQL)?
 

belvdr

macrumors 603
Aug 15, 2005
5,945
1,372
It would only block the port entirely, not based on source address.
 

lentife

macrumors member
Dec 27, 2007
32
0
Rome, Italy
If it's TCP 3306, then do a:
Code:
telnet <IP> 3306

using the internal IP on the internal network, then do the same with the external IP from the external network. If it works on the internal, but doesn't connect from the external, your port forwarding setup is not working.

If it is UDP 3306, use nmap to scan for that port:
Code:
nmap -p 3306 -u <IP>
using both the internal IP and external IP as in the TCP test above.

Hi!
I tried the nmap command in terminal and it said:
-bash: nmap: command not found

What can I do if I want to test some TCP ports of my router? I tried on some websites but somehow had not success. On my router, I opened the desired ports...
thanks
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.