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 got a machine configured to run a webserver on port 8080. That's all the machine is required to do, but it is possible that the website will be visited by the machine it's self (inside the routers LAN). If i try to visit the routers external IP:8080 I can't access the webserver.

If I connect from the internet it works fine. Likewise if I connect locally to the machine by it's internal IP or 127.0.0.1 It works fine aswell.

I appreciate some routers won't forward ports internally. But what alternatives have I got? I can't set a hosts entry as it's just IPs, no names. But I could assign a domain if required.

Alternatively, is there a way to force a machine to respond to requests for a particular IP without appearing as that IP on the subnet (Don't want to confuse routers etc...)

Win 2k8 server, IIS. Unknown router

share|improve this question
    
Do you have an internal DNS server? Or any chance to install one? –  Gabriel Talavera Jan 25 at 17:57
    
You can access the site externally using the external ip address. You can access the site internally using the internal ip address. What is the actual problem then? –  joeqwerty Jan 25 at 18:04
    
The website contains a flash application that is configured to use services from a particular IP address. I don't see what good an internal DNS server would be? I could assign a subdomain to the ip address and add the same domain in the machine's host file. Or do you mean for other machines on the same subnet accessing it? In which case... yes an internal DNS server would be needed. –  Ben Ford Jan 25 at 18:33

1 Answer 1

you setup your DNS server to send different reply based on the ip issuing the request.

so your DNS would send a private ip of the request chimes from your look an, and the public ip address otherwise. with bind name server you can ascetics this using views:

http://www.cyberciti.biz/faq/linux-unix-bind9-named-configure-views/

http://www.zytrax.com/books/dns/ch7/view.html

share|improve this answer

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.