cancel
Showing results for 
Search instead for 
Did you mean: 

can't open the store after restart my computer with DevBox

can't open the store after restart my computer with DevBox

Hello,

 

I installed DevBox on my computer, it works fine but the website not working after I restart my computer.  here are the error messages when I open storefront.

 

PDOExceptionSmiley FrustratedQLSTATE[42S02]: Base table or view not found: 1146 Table 'magento2.core_config_data' doesn't exist in /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Statement/Pdo.php:228 Stack trace: #0 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Statement/Pdo.php(228): PDOStatement->execute(Array) #1 /var/www/magento2/vendor/magento/framework/DB/Statement/Pdo/Mysql.php(95): Zend_Db_Statement_Pdo->_execute(Array) #2 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Statement.php(303): Magento\Framework\DB\Statement\Pdo\Mysql->_execute(Array) #3 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Adapter/Abstract.php(480): Zend_Db_Statement->execute(Array) #4 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT `main_ta...', Array) #5 /var/www/magento2/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php(465): Zend_Db_Adapter_Pdo_Abstract->query('SELECT `main_ta...', Array) #6 /var/www/magento2/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php(520): Magento\Framework\DB\Adapter\Pdo\Mysql->_query('SELECT `main_ta...', Array) #7 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Adapter/Abstract.php(737): Magento\Framework\DB\Adapter\Pdo\Mysql->query(Object(Magento\Framework\DB\Select), Array) #8 /var/www/magento2/vendor/magento/framework/Data/Collection/Db/FetchStrategy/Query.php(21): Zend_Db_Adapter_Abstract->fetchAll(Object(Magento\Framework\DB\Select), Array) #9 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(772): Magento\Framework\Data\Collection\Db\FetchStrategy\Query->fetchAll(Object(Magento\Framework\DB\Select), Array) #10 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(668): Magento\Framework\Data\Collection\AbstractDb->_fetchAll(Object(Magento\Framework\DB\Select)) #11 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(572): Magento\Framework\Data\Collection\AbstractDb->getData() #12 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(557): Magento\Framework\Data\Collection\AbstractDb->loadWithFilter(false, false) #13 /var/www/magento2/vendor/magento/framework/Data/Collection.php(820): Magento\Framework\Data\Collection\AbstractDb->load() #14 /var/www/magento2/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(78): Magento\Framework\Data\Collection->getIterator() #15 /var/www/magento2/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(58): Magento\Config\App\Config\Source\RuntimeConfigSource->loadConfig() #16 /var/www/magento2/vendor/magento/framework/App/Config/ConfigSourceAggregated.php(40): Magento\Config\App\Config\Source\RuntimeConfigSource->get('') #17 /var/www/magento2/var/generation/Magento/Framework/App/Config/ConfigSourceAggregated/Proxy.php(95): Magento\Framework\App\Config\ConfigSourceAggregated->get('') #18 /var/www/magento2/vendor/magento/module-config/App/Config/Type/System.php(98): Magento\Framework\App\Config\ConfigSourceAggregated\Proxy->get() #19 /var/www/magento2/vendor/magento/framework/App/Config.php(139): Magento\Config\App\Config\Type\System->get('default/web/sec...') #20 /var/www/magento2/vendor/magento/framework/App/Config.php(90): Magento\Framework\App\Config->get('system', 'default/web/sec...') #21 /var/www/magento2/vendor/magento/framework/App/Config.php(103): Magento\Framework\App\Config->getValue('web/secure/use_...', 'default', NULL) #22 /var/www/magento2/vendor/magento/module-store/Model/HeaderProvider/Hsts.php(48): Magento\Framework\App\Config->isSetFlag('web/secure/use_...') #23 /var/www/magento2/vendor/magento/framework/App/Response/HeaderManager.php(41): Magento\Store\Model\HeaderProvider\Hsts->canApply() #24 /var/www/magento2/vendor/magento/framework/Interception/Interceptor.php(123): Magento\Framework\App\Response\HeaderManager->beforeSendResponse(Object(Magento\Framework\App\Response\Http\Interceptor)) #25 /var/www/magento2/var/generation/Magento/Framework/App/Response/Http/Interceptor.php(26): Magento\Framework\App\Response\Http\Interceptor->___callPlugins('sendResponse', Array, Array) #26 /var/www/magento2/vendor/magento/framework/App/Http.php(185): Magento\Framework\App\Response\Http\Interceptor->sendResponse() #27 /var/www/magento2/vendor/magento/framework/App/Http.php(156): Magento\Framework\App\Http->handleDeveloperMode(Object(Magento\Framework\App\Bootstrap), Object(Zend_Db_Statement_Exception)) #28 /var/www/magento2/vendor/magento/framework/App/Bootstrap.php(263): Magento\Framework\App\Http->catchException(Object(Magento\Framework\App\Bootstrap), Object(Zend_Db_Statement_Exception)) #29 /var/www/magento2/index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http)) #30 {main} Next Zend_Db_Statement_Exception: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'magento2.core_config_data' doesn't exist, query was: SELECT `main_table`.* FROM `core_config_data` AS `main_table` in /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Statement/Pdo.php:235 Stack trace: #0 /var/www/magento2/vendor/magento/framework/DB/Statement/Pdo/Mysql.php(95): Zend_Db_Statement_Pdo->_execute(Array) #1 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Statement.php(303): Magento\Framework\DB\Statement\Pdo\Mysql->_execute(Array) #2 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Adapter/Abstract.php(480): Zend_Db_Statement->execute(Array) #3 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT `main_ta...', Array) #4 /var/www/magento2/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php(465): Zend_Db_Adapter_Pdo_Abstract->query('SELECT `main_ta...', Array) #5 /var/www/magento2/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php(520): Magento\Framework\DB\Adapter\Pdo\Mysql->_query('SELECT `main_ta...', Array) #6 /var/www/magento2/vendor/magento/zendframework1/library/Zend/Db/Adapter/Abstract.php(737): Magento\Framework\DB\Adapter\Pdo\Mysql->query(Object(Magento\Framework\DB\Select), Array) #7 /var/www/magento2/vendor/magento/framework/Data/Collection/Db/FetchStrategy/Query.php(21): Zend_Db_Adapter_Abstract->fetchAll(Object(Magento\Framework\DB\Select), Array) #8 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(772): Magento\Framework\Data\Collection\Db\FetchStrategy\Query->fetchAll(Object(Magento\Framework\DB\Select), Array) #9 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(668): Magento\Framework\Data\Collection\AbstractDb->_fetchAll(Object(Magento\Framework\DB\Select)) #10 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(572): Magento\Framework\Data\Collection\AbstractDb->getData() #11 /var/www/magento2/vendor/magento/framework/Data/Collection/AbstractDb.php(557): Magento\Framework\Data\Collection\AbstractDb->loadWithFilter(false, false) #12 /var/www/magento2/vendor/magento/framework/Data/Collection.php(820): Magento\Framework\Data\Collection\AbstractDb->load() #13 /var/www/magento2/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(78): Magento\Framework\Data\Collection->getIterator() #14 /var/www/magento2/vendor/magento/module-config/App/Config/Source/RuntimeConfigSource.php(58): Magento\Config\App\Config\Source\RuntimeConfigSource->loadConfig() #15 /var/www/magento2/vendor/magento/framework/App/Config/ConfigSourceAggregated.php(40): Magento\Config\App\Config\Source\RuntimeConfigSource->get('') #16 /var/www/magento2/var/generation/Magento/Framework/App/Config/ConfigSourceAggregated/Proxy.php(95): Magento\Framework\App\Config\ConfigSourceAggregated->get('') #17 /var/www/magento2/vendor/magento/module-config/App/Config/Type/System.php(98): Magento\Framework\App\Config\ConfigSourceAggregated\Proxy->get() #18 /var/www/magento2/vendor/magento/framework/App/Config.php(139): Magento\Config\App\Config\Type\System->get('default/web/sec...') #19 /var/www/magento2/vendor/magento/framework/App/Config.php(90): Magento\Framework\App\Config->get('system', 'default/web/sec...') #20 /var/www/magento2/vendor/magento/framework/App/Config.php(103): Magento\Framework\App\Config->getValue('web/secure/use_...', 'default', NULL) #21 /var/www/magento2/vendor/magento/module-store/Model/HeaderProvider/Hsts.php(48): Magento\Framework\App\Config->isSetFlag('web/secure/use_...') #22 /var/www/magento2/vendor/magento/framework/App/Response/HeaderManager.php(41): Magento\Store\Model\HeaderProvider\Hsts->canApply() #23 /var/www/magento2/vendor/magento/framework/Interception/Interceptor.php(123): Magento\Framework\App\Response\HeaderManager->beforeSendResponse(Object(Magento\Framework\App\Response\Http\Interceptor)) #24 /var/www/magento2/var/generation/Magento/Framework/App/Response/Http/Interceptor.php(26): Magento\Framework\App\Response\Http\Interceptor->___callPlugins('sendResponse', Array, Array) #25 /var/www/magento2/vendor/magento/framework/App/Http.php(185): Magento\Framework\App\Response\Http\Interceptor->sendResponse() #26 /var/www/magento2/vendor/magento/framework/App/Http.php(156): Magento\Framework\App\Http->handleDeveloperMode(Object(Magento\Framework\App\Bootstrap), Object(Zend_Db_Statement_Exception)) #27 /var/www/magento2/vendor/magento/framework/App/Bootstrap.php(263): Magento\Framework\App\Http->catchException(Object(Magento\Framework\App\Bootstrap), Object(Zend_Db_Statement_Exception)) #28 /var/www/magento2/index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http)) #29 {main}

4 REPLIES

Re: can't open the store after restart my computer with DevBox

Hi @LinkJu,

 

Unfortunately I am not in the context of devbox, but that error usually appears when your Magento instance is connecting to empty database. You cat try to reinstall you Magento instance using bin/magento setup:install command. (run bin/magento setup:install -h for params instruction)

Re: can't open the store after restart my computer with DevBox

Hello,

 

As sivashchenko said, the error is due to a database problem. Just to add to that, you may want to check that your sql server started up properly with DevBox. If you made any changes to the sql server before the restart, you may want to try changing them back.

Leslie B.
Aspiration Hosting - Magento 1 & 2 Optimized Cloud Hosting
Problem solved? Click Accept as Solution!

Re: can't open the store after restart my computer with DevBox

Thanks @AHLeslie and @sivashchenko, I noticed the port of the MySQL in DevBox has been changed when I restart my computer.  do I have to setup the database every time when I restart my computer? and I have to setup all the products, customers, etc. again, sounds crazy...

 

Re: can't open the store after restart my computer with DevBox

Hello LinkJu,

 

You shouldn't have to, it sounds like there is some configuration not being saved somewhere. In any case, I don't believe the database should have deleted with a restart under any circumstances.

Leslie B.
Aspiration Hosting - Magento 1 & 2 Optimized Cloud Hosting
Problem solved? Click Accept as Solution!