Magento Forum

Page 11 of 12
How to upgrade from 1.5.1 to 1.6.0
 
www.profico.cz
Member
 
Total Posts:  35
Joined:  2010-02-23
 

I have following problems after upgrade (manual upgrade by SSH):
(Update passed with no error.)

1. url rewrites was bad
I solved it manually, probably it’s not a good solution, i must try ($mysql> truncate core_url_rewrite;)
Same problem as here> http://www.magentocommerce.com/boards/viewthread/244508/

2. Now I don\’t see any orders on dashboard
I tried “php shell/indexer.php reindexall” (passed sucessfully), report->refresh statistic (rebuild all), clean cache, delete cache folders, reindex in index management....but i still don’t see orders in \"pending\" state.

3. I know it\’s OT, but AW_BLOG module was and now is not working, after upgrade is AW_Blog module disabled in administration, and can\’t be enabled. This module is marked as 1.6 compatible, so I not sure, if is it a problem at my side. http://ecommerce.aheadworks.com/free-stuff/blog.html (Reinstallation doesn\’t help)

4. Shop is working, but now (in 1.6) Im getting this reports>

a:5:{i:0;s:91:\"SQLSTATE[HY000]: General error: 1205 Lock wait timeout exceeded; try restarting transaction\";i:1;s:2501:\"#0 /home/eshop/magento/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#1 /home/eshop/magento/lib/Zend/Db/Statement.php(300): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#2 /home/eshop/magento/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#3 /home/eshop/magento/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query(\’INSERT INTO `he...\’, Array)
#4 /home/eshop/magento/lib/Varien/Db/Adapter/Pdo/Mysql.php(389): Zend_Db_Adapter_Pdo_Abstract->query(\’INSERT INTO `he...\’, Array)
#5 /home/eshop/magento/lib/Zend/Db/Adapter/Abstract.php(574): Varien_Db_Adapter_Pdo_Mysql->query(\’INSERT INTO `he...\’, Array)
#6 /home/eshop/magento/app/code/core/Mage/Core/Model/Resource/Db/Abstract.php(448): Zend_Db_Adapter_Abstract->insert(\’hesloneniveslol...\’, Array)
#7 /home/eshop/magento/app/code/core/Mage/Core/Model/Abstract.php(318): Mage_Core_Model_Resource_Db_Abstract->save(Object(Mage_Log_Model_Visitor))
#8 /home/eshop/magento/app/code/core/Mage/Log/Model/Visitor.php(167): Mage_Core_Model_Abstract->save()
#9 /home/eshop/magento/app/code/core/Mage/Core/Model/App.php(1299): Mage_Log_Model_Visitor->initByRequest(Object(Varien_Event_Observer))
#10 /home/eshop/magento/app/code/core/Mage/Core/Model/App.php(1280): Mage_Core_Model_App->_callObserverMethod(Object(Mage_Log_Model_Visitor), \’initByRequest\’, Object(Varien_Event_Observer))
#11 /home/eshop/magento/app/Mage.php(416): Mage_Core_Model_App->dispatchEvent(\’controller_acti...\’, Array)
#12 /home/eshop/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(505): Mage::dispatchEvent(\’controller_acti...\’, Array)
#13 /home/eshop/magento/app/code/core/Mage/Core/Controller/Front/Action.php(59): Mage_Core_Controller_Varien_Action->preDispatch()
#14 /home/eshop/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(409): Mage_Core_Controller_Front_Action->preDispatch()
#15 /home/eshop/magento/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch(\’noRoute\’)
#16 /home/eshop/magento/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#17 /home/eshop/magento/app/code/core/Mage/Core/Model/App.php(347): Mage_Core_Controller_Varien_Front->dispatch()
#18 /home/eshop/magento/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#19 /home/eshop/magento/index.php(90): Mage::run(\’frit\’, \’store\’)
#20 {main}\”;s:3:\"url\”;s:10:\"/prodejci/\”;s:11:\"script_name\”;s:10:\"/index.php\”;s:4:\"skin\”;s:4:\"frit\";}

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

Can you try increasing your innodb_lock_wait_timeout in your my.cnf?

innodb_lock_wait_timeout=1800
 
Magento Community Magento Community
Magento Community
Magento Community
 
www.profico.cz
Member
 
Total Posts:  35
Joined:  2010-02-23
 

Done, thank you.

I have two remarks to 1.6.
1) backup takes a much longer in 1.6 (i was not able to create backup till I cleaned logs)
(Backup before upgrade passed successfully (85MB), after upgrade it timed out, i solved it by truncate log tables(17MB), but it takes a much longer now than before. Same situation on 2 VPS - only change is a new version of Magento.)

2) memory usage of 1.6 is bit higher, my VPS with 512 ram has only 5-13 MB free after one day, with 1.5.1 i had about 50-100 MB free ram after few days.

 
Magento Community Magento Community
Magento Community
Magento Community
 
aramsore
Jr. Member
 
Total Posts:  27
Joined:  2009-12-18
 

Thank you! Brent!  and walejo01!

I finally did upgrade from 1.5.1 to 1.6.0.0. It only took 2 hours...but i was scared though..:(
I did follow Brent and walejo01 \’s way.

of course I got tons of errors.. 

mysql4-upgrade-1.5.9.9-1.6.0.0.php\” - SQLSTATE[HY000]: General error: 1025
mysql4-upgrade-1.5.9.9-1.6.0.0.php\” - Column \"date\" does not exists on table \"catalog_product_in

but just keep refreshing and clear cache… and check the errors report.
surprisingly whenever I refresh errors were changing.. looks like it is solving by itself and finally my web came up!!

Whoever faces all the errors, be patient and refresh!
Again, you should not upgrade a live site.  Well but I did..  i did backup though.

Thank you again!

JC

 
Magento Community Magento Community
Magento Community
Magento Community
 
jam13
Jr. Member
 
Total Posts:  8
Joined:  2008-09-17
 

justintime67: I’ve not noticed that problem on the two sites I’ve upgraded. Is it all categories or just certain ones?

 
Magento Community Magento Community
Magento Community
Magento Community
 
pglock
Jr. Member
 
Avatar
Total Posts:  30
Joined:  2010-05-06
Princes Risborough, UK
 

one more ‘gotcha’ to check for. I’m using a memcached server to improve response times. As well flushing var/cache and var/session, I also had to flush the memcache to get the upgrade to complete.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Turnkeye
Enthusiast
 
Avatar
Total Posts:  908
Joined:  2008-12-20
URL: turnkeye.com
 
justintime67 - 19 September 2011 07:59 PM

Anyone getting the XML data is invalid error message after upgrading to 1.6 and trying to save changes to categories?? Anyone know a fix?

Yes, I saw this before.
The fix is very simple, try to remove the first and the last tags from the XML.

Could you please post XML category code here?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Brent W Peterson
Moderator
 
Avatar
Total Posts:  3217
Joined:  2009-02-26
Minneapolis MN
 

I suggest that we start splitting off this thread as it is getting confusing who is asking what. If you have a new issue, please post to a new thread.

 
Magento Community Magento Community
Magento Community
Magento Community
 
blakew
Sr. Member
 
Total Posts:  107
Joined:  2008-06-20
 

@tbrinkley:

I had the same error when upgrading from 1.5.1.0 to 1.6.0.0.

The issue lies in table \\\’magentoreport_viewed_product_index\\\’. Specifically, magento is trying to run this SQL:

\\\"ALTER TABLE `magentoreport_viewed_product_index` MODIFY COLUMN `customer_id` int UNSIGNED NOT NULL COMMENT â€˜â€™\\\"

I looked in my table \\\’report_viewed_product_index\\\’ and found the key magento was complaining about. The key was found in the product_id column. The first record that had a null value in column \\\’customer_id\\\’ was the same record that possessed the \\\"duplicate key\\\”.

I restored backups of my running 1.5.1.0 installation / database and truncated the whole table \\\’report_viewed_product_index\\\’.

Then I move the 1.5.1.0 files out of the way, then downloaded a fresh 1.6.0.0 installation. I copied the app/etc/local.xml from my working 1.5.1.0 installation to the new blank 1.6.0.0 installation, likewise I copied my .htaccess file from my working 1.5.1.0 installation to the new blank 1.6.0.0 installation.

Then I initiated the update process with:

nohup php index.php magento-update-log

It appears truncating the table \\\’report_viewed_product_index\\\’ or in your case \\\’magentoreport_viewed_product_index\\\’ fixes this duplicate problem issue

 
Magento Community Magento Community
Magento Community
Magento Community
 
sandrik
Sr. Member
 
Avatar
Total Posts:  79
Joined:  2008-03-25
Minneapolis
 

Hi.
I have problem with upgrading my website from 1.5.0 to 1.6.0.0. I tried make it through Instalatron on the SimpleHellix webhosting.

Error in file: “/home/christia/domains/christianrussianbook.com/public_html/bookstore/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php” - SQLSTATE[HY000]: General error: 1025 Error on rename of ‘./christia_mage15/#sql-2da5_7f2af’ to ‘./christia_mage15/sales_flat_order_item’ (errno: 150)

Trace:
#0 /home/christia/domains/christianrussianbook.com/public_html/bookstore/app/code/core/Mage/Core/Model/Resource/Setup.php(645): Mage::exception(’Mage_Core’, ‘Error in file: ...’)
#1 /home/christia/domains/christianrussianbook.com/public_html/bookstore/app/code/core/Mage/Core/Model/Resource/Setup.php(437): Mage_Core_Model_Resource_Setup->_modifyResourceDb(’upgrade’, ‘1.4.0.25’, ‘1.6.0.4’)
#2 /home/christia/domains/christianrussianbook.com/public_html/bookstore/app/code/core/Mage/Core/Model/Resource/Setup.php(320): Mage_Core_Model_Resource_Setup->_upgradeResourceDb(’1.4.0.25’, ‘1.6.0.4’)
#3 /home/christia/domains/christianrussianbook.com/public_html/bookstore/app/code/core/Mage/Core/Model/Resource/Setup.php(235): Mage_Core_Model_Resource_Setup->applyUpdates()
#4 /home/christia/domains/christianrussianbook.com/public_html/bookstore/app/code/core/Mage/Core/Model/App.php(412): Mage_Core_Model_Resource_Setup::applyAllUpdates()
#5 /home/christia/domains/christianrussianbook.com/public_html/bookstore/app/code/core/Mage/Core/Model/App.php(338): Mage_Core_Model_App->_initModules()
#6 /home/christia/domains/christianrussianbook.com/public_html/bookstore/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#7 /home/christia/domains/christianrussianbook.com/public_html/bookstore/index.php(80): Mage::run(’’, ‘store’)
#8 {main}

I tried all methods that was described here and in all magenta threads, but no luck.
Also I found some commands, but I don’t know if it is for MQL or for SSH?:
ALTER TABLE sales_flat_order_item DROP INDEX IDX_ORDER , ADD INDEX IDX_SALES_FLAT_ORDER_ITEM_ORDER_ID ( order_id )
ALTER TABLE sales_flat_order_item DROP INDEX IDX_STORE_ID , ADD INDEX IDX_SALES_FLAT_ORDER_ITEM_STORE_ID ( store_id )
ALTER TABLE sales_flat_order_item DROP INDEX IDX_PRODUCT_ID
The biggest problem that I have tried all that on my live website and now it shouted down.
Please help.
Regards.

 
Magento Community Magento Community
Magento Community
Magento Community
 
sandrik
Sr. Member
 
Avatar
Total Posts:  79
Joined:  2008-03-25
Minneapolis
 
John - 16 September 2011 11:32 AM

jam13 - 15 September 2011 10:52 AM
Just encountered exactly the same problem as others on this thread:

“Error in file: “/xxx/app/code/core/Mage/Sales/sql/sales_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php” - SQLSTATE[HY000]: General error: 1025 Error on rename of ‘./magento/#sql-25de_742’ to ‘./magento/sales_flat_order_item’ (errno: 150)”

I have the same issue - I have worked out that there is an issue with the DB. 

I have a magento 1.4.2 database
I have used to magento DB checker to ensure that it is consistent with the 1.4.2 vanilla DB - came out clean
I extract the SQL query that is causing the issue and run that in phpmyadmin specifically against the 1.4.2 database.

SQL queryALTER TABLE `sales_flat_order_itemDROP INDEX `IDX_STORE_ID`
#1025 - Error on rename of './magento/#sql-a94_107' to './magento/sales_flat_order_item' (errno: 150)

Hay presto I have the same error that I get when I try my 1.6.0.0 upgrade.

So, next I compare the two reference installs that I have made of v1.4.2.0 and v1.6.0.0

I changed the sales_flat_order_item indexes of my 1.4.2.0 site to match the 1.6.0.0 reference site and then run the upgrade and pulled the home page. 

ALTER TABLE sales_flat_order_item DROP INDEX IDX_ORDER ADD INDEX IDX_SALES_FLAT_ORDER_ITEM_ORDER_ID order_id 
ALTER TABLE sales_flat_order_item DROP INDEX IDX_STORE_ID ADD INDEX IDX_SALES_FLAT_ORDER_ITEM_STORE_ID store_id )
ALTER TABLE sales_flat_order_item DROP INDEX IDX_PRODUCT_ID

Completed with no errors - Yeeeerrrhhh.

So can anyone throw stones at this solution then?

Regards
John

Hi, John.
I have similar problem.
Where did ran these commands?
Regards.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Krish Developer
Jr. Member
 
Avatar
Total Posts:  1
Joined:  2011-10-11
 

Error :

Error in file\"/app/code/core/Mage/Customer/sql/customer_setup/mysql4-upgrade-1.5.9.9-1.6.0.0.php\" SQLSTATE[23000]Integrity constraint violation1062 Duplicate entry  
\
'0-918\' for key \'UNQ_BY_CUSTOMER\'

Solutions :
I am having a hard time trying to restore a v1.5.1 backup to the new 1.6 Or 1.7 install and finally i find the solution of this problem.

Whenever you guys got this type of error just open your database and fire the below query on your database.

UPDATE  `eav_attribute_group`
SET `default_id` = 1
WHERE 
`attribute_group_name` = \"General\" AND `default_id` = 0

Than Clear your cache and refresh your installation.

Hope it’ll help you.

If my solution will help you guy’s to solve your problem. So, Please follow My Blog for more help regarding Magento.

http://mayankzalavadia.blogspot.in/

Thanx,
Mayank Zalavadia

 
Magento Community Magento Community
Magento Community
Magento Community
 
devromans
Jr. Member
 
Avatar
Total Posts:  18
Joined:  2012-04-05
 
dc006 - 20 August 2011 07:35 AM

Hi
the code below worked fo me (Magento 1.5.1) without any issues. Just had to clean all cache folders after update.

Can anybody explain command ./mage config-set preferred_state beta ?

Why there is need to set preferred state BETA ?
.. and do we remove this state at later date ?

chmod 700 ./mage

./mage mage-setup .
./
mage install community Mage_Downloader --force 
./mage install community Mage_All_Latest --force

chmod 700 
./mage

./mage sync-pear
./mage list-installed
./mage list-upgrades
./mage install http://connect20.magentocommerce.com/community Mage_All_Latest --force

chmod 700 ./mage

./mage config-set preferred_state beta
./mage list-installed
./mage list-upgrades

I love you smile This piece of code saved for me a lot of time, thanks.

 
Magento Community Magento Community
Magento Community
Magento Community
 
riomukti21
Jr. Member
 
Total Posts:  1
Joined:  2012-12-16
 

I’ve try this one

ALTER TABLE sales_flat_order_item DROP INDEX IDX_ORDER , ADD INDEX IDX_SALES_FLAT_ORDER_ITEM_ORDER_ID ( order_id )
ALTER TABLE sales_flat_order_item DROP INDEX IDX_STORE_ID , ADD INDEX IDX_SALES_FLAT_ORDER_ITEM_STORE_ID ( store_id )
ALTER TABLE sales_flat_order_item DROP INDEX IDX_PRODUCT_ID

but still find the error. I hope anybody can help me here.

Aingindra.com - Informasi Harga Blackberry Dan Cara Membuat Blog

 
Magento Community Magento Community
Magento Community
Magento Community
 
heyokdang
Jr. Member
 
Total Posts:  5
Joined:  2009-12-10
 
Brent W Peterson - 21 August 2011 04:21 AM

Greetings,

I just did an upgrade on a 1.5 site to 1.6 using the following.

It worked great!

rm -rf /var/cache session
./mage mage-setup .
./
mage config-set preferred_state stable
./mage list-installed
./mage list-upgrades
./mage install http://connect20.magentocommerce.com/community Mage_All_Latest --force
./shell php indexer.php reindexall

I did step by step from top to bottom, all good but final step i got this error:
-bash: ./shell: is a directory

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top
Page 11 of 12