1

I'm having a huge issue with accessing my dev site. I two magentos sites on different servers. One is the dev site, the other live. However I needed to copy the database from the live to the dev site.

Ever since i did this i've had problems with accessing the dev URL. As it keeps re-directing me to the live site. I've googled the issue and tried the following:

  • Accessed the 'core_config_date' and changed the unsecure/BASE_URL & secure/base_url and changed them back to the dev URL.
  • I then went to clear the cache on the dev site, which had already been cleared from when i was installing a plugin.
  • Set everything to 0 in 'core_cache_option'.
  • Cleared cache on my browser
  • But i'm still getting the issue of the site re-directing to the live URL.

    I've noticed a few people had had the same problem, but the above solution doesn't seem to be working for me. Any help would be much appreciated.

    Thanks

    JDavies
    • 2,730
    • 7
    • 34
    • 54
    • Have you properly configured your local.xml file for development environment? – Mukesh Aug 02 '13 at 11:30
    • Yes, well it was all working before I did a DB dump. I've also managed to connect to the DB with the settings located in the local.XML file. Is there anything else in there that could cause an issue? – JDavies Aug 02 '13 at 11:32
    • It's not the issue with the tmp directory is it? http://stackoverflow.com/questions/8940458/cant-change-magento-base-url-stuck-in-cache – McNab Aug 02 '13 at 11:44

    3 Answers3

    4

    Right so managed to sort it. It was a permissions issue. I overlooked it as I didn't have a linux user setup for this site. However the folder user was set to 'root' as opposed to 'www-data'.

    For anyone with this issue in the future, I strongly recommend checking permissions on the server/folder for caching.

    Steps to fix the issue:

  • Change base URL in the 'core_config_data' table (can be found on line 5 or 6, give or take)
  • Check permissions on your siteroot/var folder. Delete everything from /var/session & /var/cache
  • Run 'chown websiteuser -R siteroot' and then 'chmod u+w -R siteroot' for permissions changes.
  • That should be enough to get it working.

    JDavies
    • 2,730
    • 7
    • 34
    • 54
    0

    Do the below steps in your development server :

    1) Check the development server database hostname,username, password in your config.xml file in below path : app/etc/.

    2) Open your live server database in any editor and find the live site url entirely. and replace with your development server url with searched result.

    above two steps will solve your issues. here after it will now solve.

    3) Check your .htaccess file in your root folder to check the any redirection rule.

    0

    Check your file permissions and set them properly so Magento doesn't end up creating a MagicCache in the system /tmp folder which is where your core configs are being cached, allowing for you to clear var/cache till the end of time and have the settings in the database never take.

    All over here Can't change Magento base URL -> Stuck in cache

    Community
    • 1
    • 1
    Fiasco Labs
    • 6,457
    • 3
    • 32
    • 43