Installation of 2.5 : Redirect loop error

Installation of 2.5 : Redirect loop error

by Dinesh Goel -
Number of replies: 8

Hi, I installed Moodle 2.5 . I get an error that the website has a redirect loop and cannot access any of its pages.

 

How to go about it?

Average of ratings: -
In reply to Dinesh Goel

Re: Installation of 2.5 : Redirect loop error

by Sakshi Goel -

hi Dinesh

Here is a discussion on the same https://moodle.org/mod/forum/discuss.php?d=229591

In reply to Sakshi Goel

Re: Installation of 2.5 : Redirect loop error

by Dinesh Goel -

Thanks for the help. Tried everything on this link. Still not working.

In reply to Dinesh Goel

Re: Installation of 2.5 : Redirect loop error

by Guillermo Madero -

Hi Dinesh,

I would discard this being a Moodle problem, it sounds more like a server configuration issue. Anyway, was Moodle installed in the root directory, or in a subdirectory? What would happen if you rename the index.php file and put another one with some simple code.

 

In reply to Guillermo Madero

Re: Installation of 2.5 : Redirect loop error

by Dinesh Goel -

Does not seem like a server issue. It was installed in the root directory and on replacing the index.php, it still doesn't work. Moodle 2.4 is working fine though

In reply to Dinesh Goel

Re: Installation of 2.5 : Redirect loop error

by Ken Task -
Picture of Particularly helpful Moodlers

Any .htaccess file that might have been left by some other app in the now moodle code directory?

Apache server running anything 'additional' ... suPHP, apc, etc.? A phpinfo page dropped into moodle code root and accessed directly will show.

Any references in apache error log?

Have access to command line on server?  Moodle 2.5 has MUC and am wondering if it's already cached something creating the problem.  From command line:

cd /moodlecode/admin/cli/

php purge_caches.php

Then make sure your browser cache is also cleared.  OR make sure you use a browser you hadn't used with the site yet?  Speaking of browsers, which using?  Chrome, IE, or Firefox?

'spirit of sharing', Ken

Average of ratings: Useful (2)
In reply to Dinesh Goel

Re: Installation of 2.5 : Redirect loop error

by Guillermo Madero -

Hi Dinesh,

I meant, what would happen if you rename the Moodle index.php file (e.g. "index_bk.php"), create a new index.php file with some simple code, like:

<?php
<!DOCTYPE html>
<html>
<head>
<title>Basic page</title>
</head>
<body>
<p>Hello!</p>
</body>
</html>
?>

and then browse to your page. Would the page display the "Hello!" text?

I think this test would really discard the possibility of being a server configuration problem.

You say you have M 2.4 running fine... so that installation is in a subdirectory, right? If so, then maybe you have a file in your root directory (where you installed M 2.5) that is causing the redirect. I would make sure there aren't special files (e.g. dot htaccess) or even other index files (with extension dot htm or dot html) and reinstall again. You might also try installing M 2.5 in a subdirectory, so you can confirm that it is actually working fine.

In reply to Dinesh Goel

Re: Installation of 2.5 : Redirect loop error

by Cam Diep -

You can open <moodle_root>/index.php and comment the following code:

redirect_if_major_upgrade_required(); in line 35

It works for me but I don't know what's problem.