0

Alright, I've been trying to find an answer for a long time now. I found documentations on how to access a webserver internaly and externaly, but here's my problem.

By the way, all websites names and IP adress are not real ;)

I've got a webserver hosting a website, let's say portal.com. I've got a website on a webhosting website too, called school.com. On school.com, there's a link to access portal.com, but the link looks like that :

For local access : 192.168.X.X/portal/... For public access : 201.43.X.X/portal/...

the domain name school.com is registered with the web hosting company, and they programmed something so that when people write portal.school.com, they access portal.com, whether they are on our network or at home.

It worked fine on web browsers, but we started using an app to access portal.com and the way it was configured does'nt work. I'm not sure how they configured it, but I can recall they wrote a command line that would do this : if IP_adress is similar for 192.168.X.X, do that and if it's something like 201.45.X.X, do that).

With everything I read, I'm now more lost than I was before. I saw documentation about DNS split or NAT reflection and other stuff like that...

I really need help.

Thanks!

Max

2
  • 2
    Can you explain more about the links with IP addresses in them? I would never recommend linking to the IP address rather than the host name. It seems like the most straightforward solution might be to always link with the host name. Commented Jun 7, 2016 at 15:38
  • 1
    Please allow me to ask questions: Is there a Proxy server involved? > It worked fine on web browsers, but we started using an app to access portal This would lead me to suspect a Proxy definition in the browser config. Due to the complexity of your question more details are necessary for me to understand your situation to properly help you. Commented Jun 7, 2016 at 20:59

1 Answer 1

1

Easiest way to achieve what you are wanting to achieve is to run your own DNS server on your network and have a zone file for your domain name in it. In that way...

domain.com (public dns) www - A - 201.45.X.X

domain.com (internal dns) www - A - 192.168.X.X

I have set this up numerous times in the past and not just with web servers but also with Microsoft exchange servers and application servers so that regardless of if you connected from the local network or from the internet you would be connected to the same server. This is by far the easiest way to manage, especially if you run a Windows network, in which case you can use the DNS server role built into Windows Server 2003+ and if you run a Linux network you can use BIND.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.