Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Indexer error exception ‘PDOException’ with message ‘SQLSTATE[HY000]: General error: 2006 MySQL server has gone away
 
larismedia
Jr. Member
 
Total Posts:  22
Joined:  2011-12-10
 

I’m having an strange issue where the Catalog Search Index wont update. Here is the output when I run it via command line.

I’ve tried repairing permissions. I’m truncate the core_url_rewrite database (as I found in another thread) but I’m still having the error.

I have other sites on the same server and none of them are having this error.

ff@ds1 [~/public_html/shell]# php indexer.php --reindex catalogsearch_fulltext
Catalog Search Index index process unknown error:
exception ‘PDOException’ with message ‘SQLSTATE[HY000]: General error: 2006 MySQL server has gone away’ in /home/ff/public_html/lib/Zend/Db/Statement/Pdo.php:228
Stack trace:
#0 /home/ff/public_html/lib/Zend/Db/Statement/Pdo.php(228): PDOStatement->execute(Array)
#1 /home/ff/public_html/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#2 /home/ff/public_html/lib/Zend/Db/Statement.php(300): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#3 /home/ff/public_html/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#4 /home/ff/public_html/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query(’UPDATE `index_p...’, Array)
#5 /home/ff/public_html/lib/Varien/Db/Adapter/Pdo/Mysql.php(419): Zend_Db_Adapter_Pdo_Abstract->query(’UPDATE `index_p...’, Array)
#6 /home/ff/public_html/lib/Zend/Db/Adapter/Abstract.php(632): Varien_Db_Adapter_Pdo_Mysql->query(’UPDATE `index_p...’, Array)
#7 /home/ff/public_html/app/code/core/Mage/Index/Model/Resource/Process.php(137): Zend_Db_Adapter_Abstract->update(’index_process’, Array, Array)
#8 /home/ff/public_html/app/code/core/Mage/Index/Model/Resource/Process.php(109): Mage_Index_Model_Resource_Process->_updateProcessData(’7’, Array)
#9 /home/ff/public_html/app/code/core/Mage/Index/Model/Process.php(221): Mage_Index_Model_Resource_Process->failProcess(Object(Mage_Index_Model_Process))
#10 /home/ff/public_html/app/code/core/Mage/Index/Model/Process.php(255): Mage_Index_Model_Process->reindexAll()
#11 /home/ff/public_html/shell/indexer.php(158): Mage_Index_Model_Process->reindexEverything()
#12 /home/ff/public_html/shell/indexer.php(198): Mage_Shell_Compiler->run()
#13 {main}

Next exception ‘Zend_Db_Statement_Exception’ with message ‘SQLSTATE[HY000]: General error: 2006 MySQL server has gone away’ in /home/ff/public_html/lib/Zend/Db/Statement/Pdo.php:234
Stack trace:
#0 /home/ff/public_html/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#1 /home/ff/public_html/lib/Zend/Db/Statement.php(300): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#2 /home/ff/public_html/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#3 /home/ff/public_html/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query(’UPDATE `index_p...’, Array)
#4 /home/ff/public_html/lib/Varien/Db/Adapter/Pdo/Mysql.php(419): Zend_Db_Adapter_Pdo_Abstract->query(’UPDATE `index_p...’, Array)
#5 /home/ff/public_html/lib/Zend/Db/Adapter/Abstract.php(632): Varien_Db_Adapter_Pdo_Mysql->query(’UPDATE `index_p...’, Array)
#6 /home/ff/public_html/app/code/core/Mage/Index/Model/Resource/Process.php(137): Zend_Db_Adapter_Abstract->update(’index_process’, Array, Array)
#7 /home/ff/public_html/app/code/core/Mage/Index/Model/Resource/Process.php(109): Mage_Index_Model_Resource_Process->_updateProcessData(’7’, Array)
#8 /home/ff/public_html/app/code/core/Mage/Index/Model/Process.php(221): Mage_Index_Model_Resource_Process->failProcess(Object(Mage_Index_Model_Process))
#9 /home/ff/public_html/app/code/core/Mage/Index/Model/Process.php(255): Mage_Index_Model_Process->reindexAll()
#10 /home/ff/public_html/shell/indexer.php(158): Mage_Index_Model_Process->reindexEverything()
#11 /home/ff/public_html/shell/indexer.php(198): Mage_Shell_Compiler->run()
#12 {main}
ff@ds1 [~/public_html/shell]#

 
Magento Community Magento Community
Magento Community
Magento Community
 
chiefair
Mentor
 
Avatar
Total Posts:  1848
Joined:  2009-06-04
 

...

 
Magento Community Magento Community
Magento Community
Magento Community
 
larismedia
Jr. Member
 
Total Posts:  22
Joined:  2011-12-10
 
chiefair - 24 April 2013 06:05 PM

Did it for me. Thanks!

 
Magento Community Magento Community
Magento Community
Magento Community
 
twocups
Jr. Member
 
Total Posts:  2
Joined:  2012-07-29
 
larismedia - 24 April 2013 06:09 PM

chiefair - 24 April 2013 06:05 PM

Did it for me. Thanks!

What was the solution please? Having the same issue.

 
Magento Community Magento Community
Magento Community
Magento Community
 
larismedia
Jr. Member
 
Total Posts:  22
Joined:  2011-12-10
 
twocups - 25 April 2013 07:11 AM

larismedia - 24 April 2013 06:09 PM
chiefair - 24 April 2013 06:05 PM

Did it for me. Thanks!

What was the solution please? Having the same issue.

I was messing with my settings and turned off what is below.

chiefair - 06 May 2012 07:45 AM

For the MySQL server has gone away error.

The usual problem here is timeout errors and max_allowed_packet being set too low. These are settings that will have to be made to your system’s my.cnf file by your hosting provider.

MySQL Server has gone away causes from MySQL.com

The connection to your MySQL server is timing out due a PHP script taking too long to execute, server overload, wretchedly huge requests or a misconfiguration of MySQL

my.cnf settings that might help…

max_allowed_packet 16M
wait_timeout 
1800 
connect_timeout 
120

You will need to restart your MySQL server for these settings to load

Try bumping max_allowed_packet incrementally up to 64M, you may need 24M-32M

Another cause for the error is Magento sessions that hang for some reason, possibly due to silent memory exhaustion, network transmission errors if the php process is on a separate machine from the database, etc.

Source: http://www.magentocommerce.com/boards/quotereply/386848/

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top