One fix for too many redirects for domain

Hi guys,
today I am giving something back that may help others from time to time.

it realtes to virtualmin>Server Configuration>Website Redirects

I actually think that the following solution highlights a small bug in virtualmin, because if one has a working website with this option enabled, then deletes the redirect, and re enables it again, quite often the website ceases to function until it is removed again…even though prior to deleting the virtualmin redirect the website was working with it enabled! (so something clearly isnt working properly in the delete process in virtualmin for this feature)

recently i struck this problem and i havent touched the website or virtual server where this problem arose for a long time, so why all of a sudden it produced this error i dont know.

The website on my primary virtual server/domain crashed with a “too many redirects error”

I tried disabling the htaccess file, adding a new index.html file (wordpress runs in a sub directory), all to no avail.

This morning i just happened to notice there is an option in Virtualmin to add its own redirects for websites. As soon as i disabled this redirect, problem solved!

Virtualmin> Server Configuration>Website Redirects.delete the redirect if one exists here!

I wonder if this redirect is automatically added by virtualmin when the following is enabled in Virtualmin>Edit Virtual Server>Enabled Features> Apache SSL Website Enabled = true

If so, then a recent update to either Virtualmin or Wordpress (one of the two) must have changed the way in which this all works because i have always enabled this option (apache ssl website enabled) when building websites, and the website which crashed with this error is 2 years old!

*anyway, i hope that this provides at least one solution for this problem to others here. It would be interesting to

  • better understand the relationship in Virtualmin between “Apache website enabled” and “Website redirects”*
  • understand the relationship in Virtualmin between apache website enabled, website redirects, Redirect all requests to SSL site, and obtaining an automated ssl for domain in virtualmin?

needless to say, if you are using the https redirect in .htaccess file, then it obviously is not also needed in Virtualmin!

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.