Installing gitosis and closed port? [duplicate]

I'm trying to install gitosis on a Server (hosted by OVH and running Ubuntu server 11.04). I've done it a few times and never had any problems.

But this time I have something very wired when I simply try to clone gitosis.

[root@ovks-1:~/]#git clone git://eagain.net/gitosis.git
Cloning into gitosis...
eagain.net[0: 208.78.102.120]: errno=Connection refused
fatal: unable to connect a socket (Connection refused)
zsh: exit 128   git clone git://eagain.net/gitosis.git

Based on my searches it looks like the port 9418 is closed.

But I don't understand, a server by definition shouldn't have any closed port and I can't find a way to see if they are.

So how can I check is a port is open and how can I open it if closed?

Thank you for your help.


Requested by WesleyDavid: iptables -L result

[root@odeoos-vks-1:~/]#iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination         

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination         

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination   

I have no idea what it means... Thanks :)


Update:

I finally cloned gitosis from github using https://github.com/res0nat0r/gitosis.git and it worked.

My guess is that eagain.net has an actual connection problem and that there isn't much I could do about it...


But I don't understand, a server by definition shouldn't have any closed port and I can't find a way to see if they are.

I think you are slightly mistaken. A server, by definition, serves. What it serves is chosen by the server administrator. Technically, a server can have all of its ports closed, although that wouldn't be a very useful server... unless it was serving things internally between services.

So how can I check is a port is open and how can I open it if closed?

The classic way of determining if a port is open is to telnet to that port and see what banner, if any, you receive. I just tried to telnet to the server you listed and the connection was immediately refused:

[wesley@Fedora1530 ~]$ telnet eagain.net 9418
Trying 208.78.102.120...
telnet: connect to address 208.78.102.120: Connection refused

A more robust way is to use a port scanning and fingerprinting tool like nmap. You can use a GUI front-end if you want it to be friendlier (example: zenmap). I'd scan that server, except it's not mine and that can be construed as hostile, so I'll leave that as an exercise for you, the original poster. =)

From where I sit, it does indeed look like there is some blockage of port 9418 between you and the git server at eagain.net - and between me and eagen.net for that matter. Contact the server/site operator and ask him "What the dilly, yo?!"


I'm a little slow on the draw tonight, and just realized that you are the server operator. So... "What the dilly, yo?!"

Anyway, you need to check iptables for any rules that would be blocking git traffic. Run iptables -L and post the results in your answer.