0

I am getting following error while searching products.

Getting SQLSTATE[HY000]: General error: 3 Error writing file '/tmp/MYgahdeW' (Errcode: 28) error while searching products

Trace:

#0 /home/cpanelusername/public_html/catalog/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#1 /home/cpanelusername/public_html/catalog/app/code/core/Zend/Db/Statement.php(291): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#2 /home/cpanelusername/public_html/catalog/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#3 /home/cpanelusername/public_html/catalog/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT `_oc_o`....', Array)
#4 /home/cpanelusername/public_html/catalog/lib/Varien/Db/Adapter/Pdo/Mysql.php(428): Zend_Db_Adapter_Pdo_Abstract->query('SELECT `_oc_o`....', Array)
#5 /home/cpanelusername/public_html/catalog/lib/Zend/Db/Adapter/Abstract.php(734): Varien_Db_Adapter_Pdo_Mysql->query(Object(Varien_Db_Select), Array)
#6 /home/cpanelusername/public_html/catalog/app/code/local/Mana/Filters/Resource/Filter/Attribute.php(93): Zend_Db_Adapter_Abstract->fetchAll(Object(Varien_Db_Select))
#7 /home/cpanelusername/public_html/catalog/app/code/local/Mana/Filters/Model/Filter/Attribute.php(229): Mana_Filters_Resource_Filter_Attribute->optimizedCountOnCollection(Object(Mage_CatalogSearch_Model_Resource_Fulltext_Collection), Object(Mana_Filters_Model_Filter_Attribute), Array)
#8 /home/cpanelusername/public_html/catalog/app/code/local/Mana/Filters/Model/Query.php(230): Mana_Filters_Model_Filter_Attribute->optimizedCountOnCollection(Object(Mage_CatalogSearch_Model_Resource_Fulltext_Collection), Array)
#9 /home/cpanelusername/public_html/catalog/app/code/local/Mana/Filters/Model/Filter/Attribute.php(74): Mana_Filters_Model_Query->getAllOptimizedAttributeFilterCounts()
#10 /home/cpanelusername/public_html/catalog/app/code/local/Mana/Filters/Model/Filter/Attribute.php(290): Mana_Filters_Model_Filter_Attribute->_getItemsData()
#11 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Catalog/Model/Layer/Filter/Abstract.php(120): Mana_Filters_Model_Filter_Attribute->_initItems()
#12 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Catalog/Model/Layer/Filter/Abstract.php(109): Mage_Catalog_Model_Layer_Filter_Abstract->getItems()
#13 /home/cpanelusername/public_html/catalog/app/code/local/Mana/Filters/Block/Filter.php(84): Mage_Catalog_Model_Layer_Filter_Abstract->getItemsCount()
#14 /home/cpanelusername/public_html/catalog/app/design/frontend/default/theme375/template/catalog/layer/view.phtml(49): Mana_Filters_Block_Filter->getItemsCount()
#15 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Template.php(241): include('/home/cpanelusername/...')
#16 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView('frontend/defaul...')
#17 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_Block_Template->renderView()
#18 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Abstract.php(919): Mage_Core_Block_Template->_toHtml()
#19 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Text/List.php(43): Mage_Core_Block_Abstract->toHtml()
#20 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Abstract.php(919): Mage_Core_Block_Text_List->_toHtml()
#21 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Abstract.php(637): Mage_Core_Block_Abstract->toHtml()
#22 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Abstract.php(581): Mage_Core_Block_Abstract->_getChildHtml('left', true)
#23 /home/cpanelusername/public_html/catalog/app/design/frontend/default/theme375/template/page/2columns-left.phtml(52): Mage_Core_Block_Abstract->getChildHtml('left')
#24 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Template.php(241): include('/home/cpanelusername/...')
#25 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView('frontend/defaul...')
#26 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_Block_Template->renderView()
#27 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Block/Abstract.php(919): Mage_Core_Block_Template->_toHtml()
#28 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Model/Layout.php(555): Mage_Core_Block_Abstract->toHtml()
#29 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Controller/Varien/Action.php(390): Mage_Core_Model_Layout->getOutput()
#30 /home/cpanelusername/public_html/catalog/app/code/core/Mage/CatalogSearch/controllers/ResultController.php(80): Mage_Core_Controller_Varien_Action->renderLayout()
#31 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_CatalogSearch_ResultController->indexAction()
#32 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('index')
#33 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#34 /home/cpanelusername/public_html/catalog/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#35 /home/cpanelusername/public_html/catalog/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#36 /home/cpanelusername/public_html/catalog/index.php(87): Mage::run('', 'store')
#37 {main}

The error occurs often and the /tmp mount point goes to 100% from 3%. I did contacted the hosting support team and they said it is something to do with the Magento.

1 Answer 1

1

This error means that tmp disk is full. Magento uses MySQL to store it data and MySQL uses tmp catalog quite extensively.

Unfortunately I don't know how big your tmp category mount point is and what action you've tried to perform. I have also no idea about the size of your database. You could check out MySQL Query Execution plan, you could clean up your database (more data means bigger temporary files, obviously).

And yeah, it has something to do with Magento (since you were so inconsiderate to actually run it) -- those lazy support people didn't bother to check what out what's really is going on. They always sort of expect people just to store stuff on their hard disks and not actually execute any code.

TL;DR you need more space!

5
  • /tmp mount point size is 485M and the database size is 4945.10 MB. I have tried repairing and optimizing the database but it is not helping at all.
    – Kevin S
    Jun 18, 2014 at 17:54
  • I'm shooting from the hip here, but there're two things I would try out: a) more disk space as mysql temporary files can easily pass 100MB and b) play around with MySQL config file. It could be that you have buffers bigger than available space in /tmp folder.
    – Pronto
    Jun 18, 2014 at 18:10
  • There's actually one other option - you ran out of iNodes
    – Pronto
    Jul 18, 2014 at 20:34
  • Errcode: 28 is an OS error defined in the linux OS #define ENOSPC 28 /* No space left on device */ and if you have a cheap hosting service, they probably didn't define dev.mysql.com/doc/refman/5.6/en/… file-per-table mode, so no amount of optimization will shrink the innodb database storage file. Aug 22, 2014 at 1:24
  • The Mana_Filters module is probably running a query with a very inefficient query like SELECT * FROM t1, t2; where t1 and t2 have a lot of rows. It probably works fine with a small database but the tmp table size grows exponentially and therefore fails with a bigger one. Use MySQL general log to find the bad query and rewrite it to be more efficient.
    – ColinM
    Mar 13, 2015 at 18:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.