Results 1 to 9 of 9
  1. #1
    Join Date
    Mar 2007
    Posts
    62
    Plugin Contributions
    0

    Default Moving the cache folder.

    HI all,

    I have been searching for this scenario but have been unable to find it, sorry if its already been addressed.

    I have a live site and wish to move the directory above the public files, but all of the information I can find recomend a re-install.

    Would it work if I where to copy the directory to the new loaction, edit the configure.php file, change the session directory setting in admin, then delete the old cache folder?

    Also I may be wrong but it seems that during install I was asked if I wanted to write to the page or the database. I chose database, so is moving the cache folder a moot point?

    Thanks for any help,

    Steve
    Stuff: ZC v1.37 | Linux | mysql v 4.1x | php v 4.4x | phpmyadmin v 2.6x | Default Template

    Mods: Login Box v 1.41

  2. #2
    Join Date
    Aug 2005
    Posts
    26,012
    Plugin Contributions
    9

    Default Re: Moving the cache folder.

    Your cche folder should be "null" in this case but I would move it anyway....
    Zen-Venom Get Bitten
    Get Your Business Found

  3. #3
    Join Date
    Mar 2007
    Posts
    62
    Plugin Contributions
    0

    Default Re: Moving the cache folder.

    Thanks for the response kobra.

    Do you see any problems with moving the folder as I describe?

    Steve
    Stuff: ZC v1.37 | Linux | mysql v 4.1x | php v 4.4x | phpmyadmin v 2.6x | Default Template

    Mods: Login Box v 1.41

  4. #4
    Join Date
    Mar 2004
    Posts
    16,019
    Plugin Contributions
    5

    Default Re: Moving the cache folder.

    move the cache folder above public_html

    then in the config files you can just remove /public_html fro the path

    /home/username/cache

    works like a charm,

  5. #5
    Join Date
    Mar 2007
    Posts
    62
    Plugin Contributions
    0

    Default Re: Moving the cache folder.

    Thanks Merlin,

    Will try it now and report back.

    Steve
    Stuff: ZC v1.37 | Linux | mysql v 4.1x | php v 4.4x | phpmyadmin v 2.6x | Default Template

    Mods: Login Box v 1.41

  6. #6
    Join Date
    Mar 2007
    Posts
    62
    Plugin Contributions
    0

    Default Re: Moving the cache folder.

    Merlin,

    Works like a charm as you said.

    Thanks,

    Steve
    Stuff: ZC v1.37 | Linux | mysql v 4.1x | php v 4.4x | phpmyadmin v 2.6x | Default Template

    Mods: Login Box v 1.41

  7. #7
    Join Date
    Jul 2007
    Posts
    61
    Plugin Contributions
    0

    Default Re: Moving the cache folder.

    Just revisiting this activity myself and needed clarification on a few things.

    1) I also selected to put it into the database during the install, is this the most secure of the choices?

    2) After I do move the cache above the public_html (or whatever my host calls it), do I need to change the DIR_FS_SQL_CACHE path in both configure.php files (in includes and admin/includes)?

    3) When you say to "move" the cache directory up above public access, am I just creating a blank directory as a place holder (since I have database cache selected) or should I actually move the one in the ZenCart hierarchy so that the .htaccess and index.php remain intact in their new location? Are there changes I need to make to these new files because of their new location?

    Thanks, Karen

  8. #8
    Join Date
    Mar 2007
    Posts
    62
    Plugin Contributions
    0

    Default Re: Moving the cache folder.

    Hi Karen,

    As for the most secure way I couldn't say - I'm a newb myself.

    For # 2 - Yes change both

    For #3 - Copt the cache folder above the public directory and delete the old folder. Don't create a new folder to place it in, you're simply moving it.

    BTW - I'm not sure but it does still seem like a moot point.

    Hope it helps,

    Steve
    Stuff: ZC v1.37 | Linux | mysql v 4.1x | php v 4.4x | phpmyadmin v 2.6x | Default Template

    Mods: Login Box v 1.41

  9. #9
    Join Date
    Jan 2004
    Posts
    58,244
    Blog Entries
    3
    Plugin Contributions
    106

    Default Re: Moving the cache folder.

    It's best to still "keep" the cache folder, because it's not only sql query-caching that uses that folder. The PHP session system also stores its cache there. Thus, deleting the folder entirely is not advisable.

    Simply moving it by drag-and-drop with your FTP software, and then updating the 2 configure.php files and the Sessions Directory via the admin ... should be sufficient.
    Alternatively, deleting the old one, creating a new one, and making the new one read-write ... is effectively the same as drag-and-drop in FTP.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donations always welcome: www.zen-cart.com/donate

    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.

 

 

Similar Threads

  1. Is it safe to delete files in the cache folder?
    By spbennett in forum General Questions
    Replies: 8
    Last Post: 26 Sep 2008, 08:56 PM
  2. Moving all files from a folder to main page > logistics
    By chacha-vintage in forum General Questions
    Replies: 3
    Last Post: 11 May 2007, 05:35 AM
  3. Moving Zen Cart to a new folder...
    By Leovenous in forum Installing on a Linux/Unix Server
    Replies: 6
    Last Post: 3 Aug 2006, 06:06 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
  •