We've just recently set up a new apache box to test with (for simplicity we'll call it internalIp). We have two produciton apache servers that we duplicated the setup from, and made the appropriate changes.

Everything was working fine execpt when we hit the root of the box (http://internalIp) it redirects to http://internalIp/ourCompany/sub/index.jsp which we're sure came from the regular apache boxes.

So we found the index.html at /usr/local/apache2/html that had a redirect in it and removed it. However it's still redirecting to that url, even though there doesn't look to be anywhere it could be happening. We searched every file in etc, usr, and var for "ourCompany/sub/index.jsp" but couldn't find it anywhere.

I've checked all the html files at usr/local/apache2/html, and the sites-enabled config file. I can't find anywhere else that might be causing the redirect to happen.

Any ideas on how we can diagnose or fix this problem would be greatly appreciated. I can provide further information if needed.

  • Stupid question here, but did you try to restart apache? Probably right? Are you sure you got the right index.html? – Ryan Babchishin Oct 8 '15 at 19:39
  • Is there a /usr/local/apache2/html/.htaccess? – Mark Wagner Oct 8 '15 at 19:40
  • @RyanBabchishin I've done a service apache2 restart and yes there is an .htaccess but the only thing in it is the wordpress redirect rules (to allow post name URLs) – Eric B Oct 9 '15 at 13:24

Browsers can keep a redirect cache, try to browse your website with chrome incognito or ie private browsing. Got this error a lot of time when using redirect 301 and remove them later.

  • Oh my god. that was the problem. I feel like such a moron. Thank you!! – Eric B Oct 9 '15 at 16:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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