Solved

www redirects to non www on any browser

Posted on 2016-09-12
4
39 Views
Last Modified: 2016-09-16
Windows Server 2008 SP2
DC - DNS Server
DNS Manager has A record for www to point to an external IP
DNS Manager has A record for non www to point to internal IP
DOMAIN.COM is also the domain used for AD ( i know it shouldnt have been, we will look to change in the future)
WWW.domain.com is a external host, works when your outside the office.
IIS 7 is installed, already uninstalled and reinstalled
Host File is empty. Have tried adding external ip  www.domain.com but still didnt work.
Ping to www.domain.com shows the external IP. Nslookup www.domain.com shows the public IP.
3 Browsers, cleared history

When you type http://www.domain.com, the address bar redirects and shows http://domain.com and opens the IIS homepage. Cant figure out where on the server setting is making the http://www.domain.com redirect to http://domain.com.
0
Comment
Question by:rolando montalvo
  • 2
4 Comments
 
LVL 39

Accepted Solution

by:
footech earned 500 total points
Comment Utility
It would be on the webpage.  If your site is redirecting www.domain.com to domain.com, there's nothing you can do with DNS to change this.  Only a site redesign can fix this (I don't use it, but I believe I've heard that this is the way WordPress sites behave).
0
 

Author Comment

by:rolando montalvo
Comment Utility
Wow. I didnt even realize it when I was testing it externally. Thank you.
0
 
LVL 25

Expert Comment

by:DrDave242
Comment Utility
Footech is right; it has to be changed on the site.

Specifically, there's an HTTP redirect present on that site. When a browser hits http://www.domain.com, the site returns a response with a status code beginning with a 3. Code 301 is probably the most common, as it represent a permanent redirection. The response also includes the target of the redirection - i.e., where the site resides now. In your case, that target is http://domain.com.

The browser then sends a new request to the redirection target. That's why you can see the URL change in the address bar, and that's why it doesn't work from inside a domain that's named domain.com, because that name will (by design) resolve to the IP addresses of the domain controllers.

Depending on the web host, it might be very easy to get them to remove the HTTP redirect, or it might be a big pain. Unfortunately, there's no other way to get it to work, aside from renaming the AD domain.
1
 
LVL 39

Expert Comment

by:footech
Comment Utility
@rolando - Thanks for closing the question.  Personally I would have split points with DrDave242 as I think he added enough extra useful info.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

I wrote this article to explain some important DNS concepts that should be known to avoid some typical configuration errors I often see in forums. I assume that what is described here is the typical behavior of Microsoft DNS client. I don't know …
Resolve DNS query failed errors for Exchange
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now