解决方案:敲入df -h 看是不是磁盘空间满了,如果满了删除几个文件即可
SQLSTATE[08004] [1040] Too many connections
Trace:
#0 /home/wwwroot/www.example.com/lib/Zend/Db/Adapter/Pdo/Mysql.php(96): Zend_Db_Adapter_Pdo_Abstract->_connect()
#1 /home/wwwroot/www.example.com/lib/Varien/Db/Adapter/Pdo/Mysql.php(300): Zend_Db_Adapter_Pdo_Mysql->_connect()
#2 /home/wwwroot/www.example.com/lib/Zend/Db/Adapter/Abstract.php(459): Varien_Db_Adapter_Pdo_Mysql->_connect()
#3 /home/wwwroot/www.example.com/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SET NAMES utf8', Array)
#4 /home/wwwroot/www.example.com/lib/Varien/Db/Adapter/Pdo/Mysql.php(389): Zend_Db_Adapter_Pdo_Abstract->query('SET NAMES utf8', Array)
#5 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Resource.php(169): Varien_Db_Adapter_Pdo_Mysql->query('SET NAMES utf8')
#6 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Resource.php(110): Mage_Core_Model_Resource->_newConnection('pdo_mysql', Object(Mage_Core_Model_Config_Element))
#7 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Resource/Db/Abstract.php(320): Mage_Core_Model_Resource->getConnection('core_read')
#8 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Resource/Db/Abstract.php(335): Mage_Core_Model_Resource_Db_Abstract->_getConnection('read')
#9 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Resource/Db/Abstract.php(355): Mage_Core_Model_Resource_Db_Abstract->_getReadAdapter()
#10 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Resource/Db/Collection/Abstract.php(134): Mage_Core_Model_Resource_Db_Abstract->getReadConnection()
#11 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Config.php(1350): Mage_Core_Model_Resource_Db_Collection_Abstract->__construct(Object(Mage_Core_Model_Resource_Website))
#12 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Config.php(1386): Mage_Core_Model_Config->getModelInstance('core_resource/w...', Object(Mage_Core_Model_Resource_Website))
#13 /home/wwwroot/www.example.com/app/Mage.php(460): Mage_Core_Model_Config->getResourceModelInstance('core/website_co...', Object(Mage_Core_Model_Resource_Website))
#14 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Abstract.php(208): Mage::getResourceModel('core/website_co...', Object(Mage_Core_Model_Resource_Website))
#15 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/Abstract.php(213): Mage_Core_Model_Abstract->getResourceCollection()
#16 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/App.php(602): Mage_Core_Model_Abstract->getCollection()
#17 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/App.php(460): Mage_Core_Model_App->_initStores()
#18 /home/wwwroot/www.example.com/app/code/core/Mage/Core/Model/App.php(344): Mage_Core_Model_App->_initCurrentStore('', 'store')
#19 /home/wwwroot/www.example.com/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#20 /home/wwwroot/www.example.com/index.php(80): Mage::run('', 'store')
#21 {main}