This is an old revision of the document!
Here are the steps for upgrading Magento with a full package or via SVN. Steps for upgrading with the MagentoConnect Manager are below.
- Backup your database
- - In Magento go to Admin, System → Tools → Backups
- - You can use PHPMyAdmin (but this may fail due to time-limits on php scripts)
- - You can export in SSH by typing...
- - mysqldump -u USER -p DBNAME > dump.sql
- - Reimport using mysql -u USER -p DBNAME < dump.sql
- Backup all the code you modified yourself, and don’t forget to keep the original installation archive
- Take care of saving the media directory that contains all the uploaded product/category images
- Create a backup copy of app/etc/local.xml file
- Download a new installation archive or run SVN update if you checked it out from the Magento repository
- Extract and upload all the files it contains to your server
- Delete var/cache and var/session directories
- Point your browser to any Magento page
- Database upgrades should happen automatically
- You are done!
- Go to http://<YOUR_SERVR>/downloader
- Log in using a user who has full permissions
- Make sure to select “Clear all sessions after successful install or upgrade”
It is possible that you will see no extensions in MagentoConnect Manager. This means that you have just uploaded the files without using PEAR downloader. In that case enter
magento-core/Mage_All_Latest in the extension key field and click Install button. This will install all latest MagentoConnect core packages on top of existing files and will allow future upgrades through MagentoConnect.
NOTE: if, after the install has completed and you hit Refresh, you get a 500 error, and you get the same on your regular admin page and your storefront, look at permissions on index.php and downloader/index.php. If necessary, change them BACK to 644. Reload downloader/index.php to continue.
There should be at least one extension marked in yellow, which means a higher version is available on the MagentoConnect server
- Click ‘Select all upgradable extensions’
- Click ‘Commit changes’
- Watch the console progress for error messages
- After successfully upgrading click the ‘Refresh’ button that will appear under the console frame.
- For each desired extension upgrade choose ‘Upgrade’ in the dropdown
- To upgrade Magento Core modules choose the following packages, and all required dependencies will be upgraded automatically:
- MagentoConnect Manager is not installed as a PEAR package by default. If you wish to upgrade it, you will first need to install it as a PEAR package.
magento-core/Mage_Downloaderin the Extension key input field and click Install.
- After it is installed the first time, you can upgrade it the same way as other extensions.
You can not uninstall MagentoConnect Manager
You need to discuss the folder/file permissions here!!!
- To initialize the Magento PEAR command line registry, run the following command from the shell. Make sure you are in the Magento root folder:
./pear mage-setup .
- (make sure to include the second ‘.’)
- select php version (unix):
MAGE_PEAR_PHP_BIN=/usr/local/bin/php; export MAGE_PEAR_PHP_BIN
- for 1and1.com hosting, to use PHP5:
MAGE_PEAR_PHP_BIN=/usr/local/bin/php5; export MAGE_PEAR_PHP_BIN
If you have not used MagentoConnect or PEAR command line to install Magento, you will need to enter this command for initial PEAR installation of all Magento core modules:
./pear install magento-core/Mage_All_Latest
(You may have to upgrade pear extensions using the next step for this step to work).
./pear upgrade magento-core/Mage_Core_Modules magento-core/Mage_Core_Adminhtml
./pear upgrade magento-core/Interface_Adminhtml_Default magento-core/Interface_Frontend_Default magento-core/Interface_Install_Default
- If MagentoConnect Manager is not installed as a PEAR package yet:
./pear install magento-core/Mage_Downloader
- After it is installed it will be upgraded just as any other extension.