This article is part of the Magento Enterprise Edition (EE) upgrade documentation. If you're looking for something else, click here to go back to the Magento Knowledge Base.
This article applies to the following Magento EE upgrades:
- From EE 188.8.131.52 to EE 184.108.40.206
- From EE 220.127.116.11 to EE 18.104.22.168
- From EE 22.214.171.124 to EE 126.96.36.199
If your upgrade is not in the preceding list, skip this article and continue with Completing the Magento Upgrade.
This article discusses how to run the URL redirect script that creates HTTP 301 (Moved Permanently) redirects for any duplicate product URL keys. This enables Previous links in your web store to work, for example.
To create redirects for your URLs, perform the following tasks in the order shown:
Verifying that cron is Disabled
It's very important to stop cron jobs from running until after the upgrade script completes. To do so, enter one of the following commands as a user with root privileges:
- Ubuntu: service crond stop
- CentOS: service cron stop
Running the Script
This section discusses how to run the URL redirect script to create permanent redirects for any URLs that changed in EE 188.8.131.52.
Note: The time the script takes to run and the amount of memory it uses is directly proportional to the size of your database.
To run the script:
- Change to your Magento installation directory.
- As the user who owns the files (typically, either root or the web server user), enter the following command:
php -f shell/url_migration_from_1_13_0_0_to_1_13_0_2.php
- Wait while the script runs.
Messages like the following display to indicate progress:
[INFO]: Initialization... [INFO]: Start url rewrites processing from 184.108.40.206 to 220.127.116.11 ... [INFO]: Start root category "Default Category" processing ... [INFO]: Start root category "test" processing ... [INFO]: Executed in time
- If the script succeeded, continue with Completing the Magento Upgrade.
If errors display, check [your Magento install dir]/shell/migration.log for exceptions. Following are errors that might display when you run the migration script:
- Application is not installed yet, please complete install wizard first
- PHP Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE  Access denied for user 'name'@'hostname' (using password: YES)' in /var/www/magento/lib/Zend/Db/Adapter/Pdo/Abstract.php
If one of these displays, make sure you copied [your Magento install dir]/app/etc/local.xml from your development system to the production system. Edit it if necessary to reference the production database instance. After you copy and edit local.xml, run the URL redirect script again.
Continue your upgrade with Completing the Magento Upgrade.