Hi all,

I'm terribly sorry if this is kind of obvious to you boffins out there, but this has had me stumped for way to long now (I'd say 2 weeks is too long).

My website gives an error ("Too many redirects" or something like it) when I browse to the "user/login" page. All the other URLs seem to be working fin, though.

What I've done so far:

  • Replaced the .htaccess file with stock one from installation.
  • Replaced the core files with core files from installation (except settings.php)
  • Specified and removed again the $base_url in settings.php

The URL for the website is https://webify-it.co.za and the login is available at https://webify-it.co.za/user/login (obviously).

It seem to have started doing thing on it's own. I don't really have access to the log files, so I can't go that route.

Any help fixing this would be greatly appreciated.

Most helpful answers

The latest update to Backdrop 1.9.0 includes some changes to the user/login page that require a menu rebuild. If you have recently upgraded and have not run the database updates (or otherwise rebuilt your menu) you could be hitting this problem. Or, it could be that you have a redirect (via Redirect module) that is causing the problem. (The menu rebuild problem has been fixed in https://github.com/backdrop/backdrop-issues/issues/2943)

For the easiest way to resolve either of these issues, however, you'll need to be logged in. If you are able to use the password reset functionality at user/password, that should allow you to log in without needing to use the user/login page.

Once logged in, check if database updates need to be run, or navigate to admin/config/urls/redirect and search for user/login.I hope that one of these solutions will clear up your problem!

Comments

I can confirm that when trying to access

http://www.webify-it.co.za/user/login

My browser gives the message:

The page isn't redirecting properly

Firefox has detected that the server is redirecting the request for this address in a way that will never complete.

I would discuss such problem first with my hosting provider.

You are using Let's encrypt for https. Have a look at this discussion:

https://magento.stackexchange.com/questions/141041/my-securehttps-pages-...

Thank you amilenkov,

I just heard back from them, and it seems the problem is not on their side, although I've told them that I doubt it and gave my reasons as to why.

I am using Let's Encrypt, yes, but it worked fine a few days ago, and taking the https out, so that it only uses normal http, makes no difference.

Any other idea what it could possibly be?

drop's picture

The latest update to Backdrop 1.9.0 includes some changes to the user/login page that require a menu rebuild. If you have recently upgraded and have not run the database updates (or otherwise rebuilt your menu) you could be hitting this problem. Or, it could be that you have a redirect (via Redirect module) that is causing the problem. (The menu rebuild problem has been fixed in https://github.com/backdrop/backdrop-issues/issues/2943)

For the easiest way to resolve either of these issues, however, you'll need to be logged in. If you are able to use the password reset functionality at user/password, that should allow you to log in without needing to use the user/login page.

Once logged in, check if database updates need to be run, or navigate to admin/config/urls/redirect and search for user/login.I hope that one of these solutions will clear up your problem!

Thank you drop!

Following the steps to reset my password allowed me to get into the back-end, where I saw and fixed the problem in 10 minutes.

From what I could see (and I don't know if this is correct or not) it was caused by a database upgrade that I somehow missed and consequently failed to apply.

drop's picture

From what I could see (and I don't know if this is correct or not) it was caused by a database upgrade that I somehow missed and consequently failed to apply.

I think you may have just run into another recent bug where updates are not triggering the alert icon, or an error on the status report anymore. You can follow https://github.com/backdrop/backdrop-issues/issues/2976 for a resolution on that one if you are interested.

That DOES seem to be the case, yes. Thank you!

Interesting and useful!

But if there is no access also to the user/password page (e.g. one more redirect) or changed user's e-mail, is there any possibility to access the site with administrative rights by editing the settings. php file or another record in the files from the installation at the hosting account.

I've read about similar techniques with Drupal 7, where every visitor to the site automatically enters in to the site and receives User1 rights on a temporary basis.

I know that the user e-mail can be replaced by a direct edit of the record in the database, just ask for other useful options to enter in a corrupted or hacked site.

 

I really don't know. It would have been much quicker as it would have been one of the first things I would have attempted (not on my live site, though, on dev environment). I'm sure a method for Drupal 7 would have worked though. After all, they're basically the same thing.

Thanks. I'm keeping that!

drop's picture

...is there any possibility to access the site with administrative rights by editing the settings. php file...?

Not by editing the settings.php file, no. But you can get access by using the drush user-login command, which will generate a one-time log-in link for user 1 and deliver it via command line instead of by email. That's my favorite way to get complete access to a site temporarily!