Super User is a question and answer site for computer enthusiasts and power users. 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've encountered some network behaviour that confuses me while trying to get Java RMI working.

I use netcat to connect to a local machine:

[my_machine]$ nc -w 1 60000 && echo success

I try to do the same to my server:

[my_machine]$ nc -w 1 my-servers-ip 60000 && echo success

This doesn't work, unless I explicitly listen on the server socket:

[amazon_ec2]$ nc -l 60000 

[my_machine]$ nc -w 1 my-servers-ip 60000 && echo success

For the version that fails, the SYN packet receives a RST, ACK in response.

I'm not too knowledgable about this stuff, at this point I only have wild theories such as the one in the question. Any ideas?

Potentially useful details:

Local Machine ( - Macbook

Remote Machine (Amazon EC2) - Amazon Linux AMI 2012.03 
    Security Group Settings:
        22 (SSH)
    "iptables -L" shows no rules set 
share|improve this question
up vote 1 down vote accepted

No, TCP connections work the same way for local or remote (routed) servers. The three-way handshake is the same.

You can check

  • some service is actially listening on port 60000 (netstat)
  • the service is not configured to reject non-local clients in some way
  • no firewall is blocking traffic
share|improve this answer
And this is why we go to bed and try again in the morning. Thanks. – Dean Oct 5 '12 at 15:58

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.