Heads up! This content is more than six months old. Take some time to verify everything still works as expected.
In a some infuriating day, I have discovered there is one more step to changing a Magneto base url than most people list. It's a rare problem, and not one I expect most people will find.
The standard steps for changing magento's base url are:
- Update the core_config_data table.
You'll need to change the
- Clear the system cache
This could be in one of two places. If your directories are setup
properly and can be written to by the web process, they are in
httpdocs/var/session. If those directories are not writeable, they could appear in your server's root system at
But, as I discovered today, there are two more pieces...
- Check for non-standard modification of the .htaccess file forcing domain redirection.
- Check if the magento configuration cache is using APC.
APC is the one stuck me. I spent about 5 hours trying like made to figure out where it kept getting the 'old' url from, when it didn't exist in the code or database anymore. In this rare occasion, we are hosting the development site, and the live site, on the same server.
Everytime the live site got a hit, it would cache the live
configurations into the APC, and the dev would happily read right
on, redirecting to the live site. Make sure you check
This might be your issue!