0

I am new to the EE community. I came across a situation today that myself and my co-workers could not figure out. I am running a site locally on docker containers (Ubuntu, PHP 5.4, Apache 2.2.22, MYSQL 5.5.44). The site was on EE 2.6.1 and I followed the guide to upgrade it to EE 3.5.17. The upgrade seemed to go through. I can see the frontend of my site; however, when I try to login to the CP, I get an infinite redirect (302) loop until Apache hits its URI size limit.

The network tab on my browser looks like

http://site.test/asdfjkl.php 302 redirect to http://site.test/asdfjkl.php?/cp/login&return= 302 redirect to http://site.test/asdfjkl.php?/cp/login&return=DHDHDHD 302 redirect to http://site.test/asdfjkl.php?/cp/login&return=DHDHDHDFTFTFTFTF 302 redirect to http://site.test/asdfjkl.php?/cp/login&return=DHDHDHDFTFTFTFTFRURURURU

I removed my .htaccess file completely to see if it was causing the issue and I got the same results when trying to login to the CP.

I tracked down where the redirects were happening in the EE code.

When booting a CP, system/ee/EllisLab/ExpressionEngine/Core/Core.php (line 188) is called. It tries to create a new class:

$controller = new $class;

When that class is initiated, run_cp() in system/ee/legacy/libraries/Core.php (line 471) is called. It checks to see if a Admin session exists, it does not, so it redirects:

ee()->functions->redirect(BASE.AMP.'C=login'.$return_url);

It seems that this function is called over and over again until Apache stops it because the length of the URI.

I really appreciate any advice you might have to give. Thanks!

Note: site.test -> EE 3.5.17 site running locally on docker container asdfjkl.php -> fake name for my admin.php file DHDHDHDFTFTFTFTFRURURURU -> fake string

1

I believe this happened because (1) I did not have addon.setup.php for a custom module or (2) I had uninstalled a module that I actually needed before performing the upgrade from EE2 to EE3. I walked through the upgrade again and it worked the second time around when I had corrected the two issues above. Hope this helps someone else at some point.

| improve this answer | |

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.