Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 29
  1. #11
    Join Date
    Jan 2004
    Posts
    65,414
    Blog Entries
    7
    Plugin Contributions
    232

    Default Re: Fresh install admin access fails with too many redirects

    1. It's a bug.
    2. It's an attempt to integrate the logic for fix_cache_key into core so people don't need to run that separate util if they switch servers.
    3. This is what it was doing:
    - if the directory named by SESSION_WRITE_DIRECTORY doesn't exist, it was detecting what folder the script was running in so that it could guess what the correct "store root" was, and then appending /cache to it (since if the one in the db didn't exist then the best guess after that is /cache). The bug is that the file doing the detection is 2 levels under the admin folder, and thus was *incorrectly* guessing that it needed to use /admin/includes/ instead of just /

    It's easy to avoid encountering the bug:
    - create the /cache folder (or any other writable folder)
    - set SESSION_WRITE_DIRECTORY to point to it


    The fix to have it guess the correct /cache folder is to change the file I mentioned above, and alter the realpath(dirname(__FILE)) to be realpath(dirname($_SERVER['SCRIPT_FILENAME'])) .... but the redirect will still happen if you don't actually have the /cache folder.

    But I'm reluctant to commit a code fix for the above, because I'm wondering if the original need for this has maybe expired, and even using fix_cache_key may no longer be necessary, given that sessions are now only stored in the database, not the filesystem.
    Further research is required to determine the optimum solution.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  2. #12
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    7,208
    Plugin Contributions
    273

    Default Re: Fresh install admin access fails with too many redirects

    What if you just set the default value for SESSION_WRITE_DIRECTORY in the mysql script to DIR_FS_CATALOG/cache? That exists.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.

  3. #13
    Join Date
    Jan 2004
    Posts
    65,414
    Blog Entries
    7
    Plugin Contributions
    232

    Default Re: Fresh install admin access fails with too many redirects

    Will consider it.

    It's just strange that in all the testing we've done with multiple environments and upgrades we never triggered this issue.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  4. #14
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    7,208
    Plugin Contributions
    273

    Default Re: Fresh install admin access fails with too many redirects

    ok. I created the known bugs in 1.5.3 thread and added a pointer to this thread.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.

  5. #15
    Join Date
    Jan 2004
    Posts
    65,414
    Blog Entries
    7
    Plugin Contributions
    232

    Default Re: Fresh install admin access fails with too many redirects

    Here's a replacement file which should resolve the issue:
    Simply unzip and upload to your server as /admin/includes/init_includes/init_cache_key_check.php

    THIS FILE SHOULD ONLY BE USED ON ZC v1.5.3. .... DO NOT put it on any other version!
    Attached Files Attached Files
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  6. #16
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    7,208
    Plugin Contributions
    273

    Default Re: Fresh install admin access fails with too many redirects

    I wonder if the issue is that the /cache folder by default isn't writable. Could the installer check this condition and block progress as it does with configure.php files?
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.

  7. #17
    Join Date
    Jan 2004
    Posts
    65,414
    Blog Entries
    7
    Plugin Contributions
    232

    Default Re: Fresh install admin access fails with too many redirects

    Quote Originally Posted by swguy View Post
    I wonder if the issue is that the /cache folder by default isn't writable. Could the installer check this condition and block progress as it does with configure.php files?
    It does already point out that the folder isn't writable when running zc_install, on the System Inspection page.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  8. #18
    Join Date
    May 2005
    Location
    England
    Posts
    578
    Plugin Contributions
    0

    Default Re: Fresh install admin access fails with too many redirects

    Hello there,

    I originally posted here, when I first noticed the error it was a blank page, and then I went to 1.5.4 and it was 'too many redirects' on admin.

    http://www.zen-cart.com/showthread.p...ht=blank+admin

    I am going crazy here, lol. I have found this thread and can see there must be something wrong with my setup. I have had the same cache directory pointed to for ten year in configure:-

    define('DIR_FS_SQL_CACHE', '/home/******/public_html/cache');

    Is there a way to stop this check? I am sure the above is valid, I haven't changed it. I created more cache folders in admin as swguy put, and all permissions are 777. Hope somebody may be able to help please. thanks in advance.

  9. #19
    Join Date
    May 2005
    Location
    England
    Posts
    578
    Plugin Contributions
    0

    Default Re: Fresh install admin access fails with too many redirects

    I tried the replacement file contained here in this thread to no avail :-(

  10. #20
    Join Date
    Jan 2004
    Posts
    65,414
    Blog Entries
    7
    Plugin Contributions
    232

    Default Re: Fresh install admin access fails with too many redirects

    So where is it at now?
    - what ZC version are you using?
    - which init_cache_key_check.php file are you now using?
    - are you actually getting just "blank page"? or are you really getting the "too many redirects"?

    - Is your webserver running Linux/Ubuntu/CentOS/Windows/... what? If you don't know the answer to that, normally you could get it via your Admin, but since that's where your problem is, you could ask your hosting company to tell you what operating-system your server is using. They can answer the PHP questions too, if you don't know the answers:
    - what's your PHP version? Is it running "PHP as CGI"? or "suPHP"? or simply as an Apache module?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 
Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. Replies: 11
    Last Post: 5 Mar 2013, 12:21 PM
  2. 1.3.8 too many redirects at checkout when using FEC addon
    By anaxagoras in forum All Other Contributions/Addons
    Replies: 2
    Last Post: 1 Mar 2012, 07:24 PM
  3. too many redirects 301 error - trying to login to admin
    By ceffthor in forum Installing on a Linux/Unix Server
    Replies: 10
    Last Post: 10 Aug 2011, 09:09 PM
  4. Too many redirects? HELP
    By Uthernator in forum General Questions
    Replies: 1
    Last Post: 29 Sep 2010, 10:36 AM
  5. Too Many Redirects - Unable to login
    By webskipper in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 20 Jul 2008, 11:09 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR