Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I've managed to create SVN server that works on localhost (I used this tutorial).

Checkout and all other commands work locally (when I use the adress https://localhost/svn/repository-name)

I own a domain which points at my IP adress.

ping mydomain.com 

returns my IP adress.

That IP adress leads to a router, which is configured to forward ports 80 and 443 to my server machine.

Unfortunatelly checkout https://mydomain.com/svn/repository-name is not working (Connection Timed out).

Why? Please help.

My server machine is running Apache2 @ Ubuntu 10.10.

share|improve this question
add comment

3 Answers

up vote 2 down vote accepted

Are you sure that your router forwards connections made on the internal interface back into the internal network? It is very common that cheap routers only do the port forwarding on traffic that comes in on the external interface.

Try testing from outside your network and see if it works better.

share|improve this answer
    
+1 - this is a good possibility, do try it. –  Eduardo Ivanec May 10 '11 at 18:08
    
@pehrs how can I check this? My Router is D-Link DIR-100 –  loostro May 10 '11 at 18:45
1  
Test it from the internet, perhaps via VNC or rdesktop to your home? Or use some website like this one: yougetsignal.com/tools/open-ports –  Eduardo Ivanec May 10 '11 at 18:50
    
@Eduardo this website sais that my 80 and 443 ports are closed.. i guess thats the problem.. how do i open them? –  loostro May 10 '11 at 18:54
1  
Double check your router config. This site may come handy: portforward.com/english/routers/port_forwarding/Dlink/DIR-100/… –  Eduardo Ivanec May 10 '11 at 18:59
show 6 more comments

You either have problems with the port forwarding (that is: the packets arriving at your router are not reaching your server) or 443 is closed in the interface you're forwarding the packets to.

Try https://ip.being.forwarded.to/svn/repository-name locally (that is, in the server) with the IP you configured on your router. Does it work that way?

Also check for INPUT filtering (iptables -nvL INPUT). And post netstat -ntlp if possible.

share|improve this answer
    
https:// 192.168.0.109/svn/testPage/ returns my repository (just like https:// localhost/svn/testPage/) –  loostro May 10 '11 at 18:43
    
netstat -ntlp returns Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 6601/apache2 tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 1113/cupsd tcp 0 0 0.0.0.0:443 0.0.0.0:* LISTEN 6601/apache2 tcp6 0 0 ::1:631 :::* LISTEN 1113/cupsd –  loostro May 10 '11 at 18:48
    
Can you test the same from some other server in the LAN? You can access it via a browser if you haven't got a SVN client handy. If it works then you know the issue is with the router/port forwarding. –  Eduardo Ivanec May 10 '11 at 18:49
    
iptables -nvL INPUT returns Chain INPUT (policy ACCEPT 30 packets, 4974 bytes) pkts bytes target prot opt in out source destination –  loostro May 10 '11 at 18:50
    
I've tested it from another machine (plugged into the same router/in the same Local Area Network) and it works –  loostro May 10 '11 at 18:52
add comment

The problem was closed ports.

Port forwarding options did not work on my router. I had to reset it to factory settings and set it up again. Now it works fine.

Why did my router fail to forward ports? No idea. But resetting router fixed the problem.

I'd like to thank @Eduardo and @pehrs for help!!

share|improve this answer
add comment

Your Answer

 
discard

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.