Call-back icon  Sales: Call 877.832.5289 (N America)|310.295.4144 (International)

Magento

eCommerce Software for Online Growth

Magento Forum

   
Uncaught exception ‘Mage_Core_Model_Store_Exception’
 
spreedictive
Jr. Member
 
Total Posts:  3
Joined:  2008-05-13
 

Hi, i am dying to get my hands on testing out magento but faced the below problem when i tried to install via simplescripts. Will anyone be able to help?

Fatal error: Uncaught exception ‘Mage_Core_Model_Store_Exception’ in /home/imbccoms/public_html/shop/app/code/core/Mage/Core/Model/App.php:1056 Stack trace: #0 /home/imbccoms/public_html/shop/app/code/core/Mage/Core/Model/App.php(545): Mage_Core_Model_App->throwStoreException() #1 /home/imbccoms/public_html/shop/app/Mage.php(577): Mage_Core_Model_App->getStore() #2 /home/imbccoms/public_html/shop/app/Mage.php(439): Mage::printException(Object(Zend_Db_Adapter_Exception)) #3 /home/imbccoms/public_html/shop/index.php(40): Mage::run() #4 {main} thrown in /home/imbccoms/public_html/shop/app/code/core/Mage/Core/Model/App.php on line 1056

 
Magento Community Magento Community
Magento Community
Magento Community
 
spreedictive
Jr. Member
 
Total Posts:  3
Joined:  2008-05-13
 

Hi,
After installing magento, my website show :

Fatal error: Uncaught exception ‘Mage_Core_Model_Store_Exception’ in /home/imbccoms/public_html/shop/app/code/core/Mage/Core/Model/App.php:1056 Stack trace: #0 /home/imbccoms/public_html/shop/app/code/core/Mage/Core/Model/App.php(545): Mage_Core_Model_App->throwStoreException() #1 /home/imbccoms/public_html/shop/app/Mage.php(577): Mage_Core_Model_App->getStore() #2 /home/imbccoms/public_html/shop/app/Mage.php(439): Mage::printException(Object(Zend_Db_Adapter_Exception)) #3 /home/imbccoms/public_html/shop/index.php(40): Mage::run() #4 {main} thrown in /home/imbccoms/public_html/shop/app/code/core/Mage/Core/Model/App.php on line 1056

Does anyone know what is the problem for this? how do i resolve this?

Website: http://www.shop.spreedictive.com

 
Magento Community Magento Community
Magento Community
Magento Community
 
bblinn
Jr. Member
 
Total Posts:  1
Joined:  2008-05-15
 

Same thing here on BlueHost. I’d really like to see if this does what I need, but ...
Fatal error: Uncaught exception ‘Mage_Core_Model_Store_Exception’ in /home/sixoneze/public_html/blinn-com/MagentoTest/app/code/core/Mage/Core/Model/App.php:1056 Stack trace: #0 /home/sixoneze/public_html/blinn-com/MagentoTest/app/code/core/Mage/Core/Model/App.php(545): Mage_Core_Model_App->throwStoreException() #1 /home/sixoneze/public_html/blinn-com/MagentoTest/app/Mage.php(577): Mage_Core_Model_App->getStore() #2 /home/sixoneze/public_html/blinn-com/MagentoTest/app/Mage.php(439): Mage::printException(Object(Zend_Db_Adapter_Exception)) #3 /home/sixoneze/public_html/blinn-com/MagentoTest/index.php(40): Mage::run() #4 {main} thrown in /home/sixoneze/public_html/blinn-com/MagentoTest/app/code/core/Mage/Core/Model/App.php on line 1056

I see posts here and elsewhere about this problem, but so far no solutions.  confused

 
Magento Community Magento Community
Magento Community
Magento Community
 
Crucial Web Host
Sr. Member
 
Avatar
Total Posts:  196
Joined:  2007-11-08
Phoenix, AZ
 

I have a couple of theories that I should share.

1.  These errors are the result of a low memory condition.  This could be related to a lot of configuration factors; Everything from the environment available memory to the php.ini memory configurations and as complex as the apache keepalive and MPM module configurations.

Each of these things would make it so that the system work work, until it ran out of memory - then it would throw the error.  I think a system restart can rule out this problem.

2.  PHP extensions directory location changes.  This is common with the very popular CPanel control panel.  CPanel has a nasty habit of changing your lib dir to it’s own custom location.  This can cause a lot of problems if your PDO is not located in this new setting.  However, this issue could only be caused by some sort of php/apache recompilation/upgrade.  Keep in mind that many CPanels are set to ‘automatically’ upgrade themselves when patches are available, which could easily lead to this lib directory changing. 

I would think this would be common only in shared hosting environments.  Shared hosts sometimes rebuild apache without paying close enough attention to this particular configuration value and it’s certainly not an ‘expected’ result of recompilation.

I’m going to run some tests on lab hosting environments to see if I can find a way to replicate this error

If anyone has any other idea’s or things that you think would be important to look at it would be appreciated.

 Signature 

Crucial Web Hosting
Magento hosting in shared, semi-dedicated, and dedicated configurations. Demo store.
Dedicated Containers come with Varien’s professional support services for Magento.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Crucial Web Host
Sr. Member
 
Avatar
Total Posts:  196
Joined:  2007-11-08
Phoenix, AZ
 

I accidentally chopped my original reply by editing it.

I was asking if you guys could give any details regarding your hosting environment?

Things like;

1. VPS / Shared hosting?

2. If VPS how much RAM/Memory (guaranteed)

3. Apache/PHP configuration details

4. Caching systems in place?  eAcellerator/APC?

5. Anything unusual about your configuration that might be able to help replicate this issue?

Appreciate any feedback you can give.

 Signature 

Crucial Web Hosting
Magento hosting in shared, semi-dedicated, and dedicated configurations. Demo store.
Dedicated Containers come with Varien’s professional support services for Magento.

 
Magento Community Magento Community
Magento Community
Magento Community
 
dawgfather
Jr. Member
 
Total Posts:  2
Joined:  2008-05-15
 

I have bluehost too and used simple scripts

We use MySQL 5.0.x

Apache is 2.2.8
I have attached my phpinfo file and thx

File Attachments
bluehostphpinfo.txt  (File Size: 19KB - Downloads: 72)
 
Magento Community Magento Community
Magento Community
Magento Community
 
ben-zene
Jr. Member
 
Total Posts:  1
Joined:  2008-02-28
 

There’s another post that applies to this one: http://www.magentocommerce.com/boards/viewthread/8354/

He figured it out.

 
Magento Community Magento Community
Magento Community
Magento Community
 
chinesedream
Guru
 
Total Posts:  745
Joined:  2007-08-31
San Francisco, CA
 
Crucial Web Host - 15 May 2008 04:09 PM

I accidentally chopped my original reply by editing it.

I was asking if you guys could give any details regarding your hosting environment?

Things like;

1. VPS / Shared hosting?

2. If VPS how much RAM/Memory (guaranteed)

3. Apache/PHP configuration details

4. Caching systems in place?  eAcellerator/APC?

5. Anything unusual about your configuration that might be able to help replicate this issue?

Appreciate any feedback you can gxive.

My client’s site suddenly is having the exact same problem, I was in panic until I saw your post. Thank you!

Here is the server info:
1. Shared hosting with Cpanel.
I don’t know anything about the caching systems, as for the Apache/PHP confiiguration, I think it’s up to par as I have not encountered any problem testing Magento store until now.

If you want the PHP info, let me know, I will PM you.

THanks!

 
Magento Community Magento Community
Magento Community
Magento Community
 
Moshe
Magento Team
 
Avatar
Total Posts:  1771
Joined:  2007-08-07
Los Angeles
 

In app/Mage.php, do you have this code on approx line 575:

public static function printException(Exception $e$extra '')
// ...
            
chmod($reportFile0777);

// added these 5 lines
            
$storeCode 'default';
            try 
{
                $storeCode 
self::app()->getStore()->getCode();
            
}
            
catch (Exception $e{}
// until here

            
$baseUrl rtrim(dirname($_SERVER['SCRIPT_NAME']), '/');

            
$reportUrl $baseUrl '/report/?id='
// instead of:
                
$reportId '&s;=' self::app()->getStore()->getCode();

// replaced with:
                
$reportId '&s;=' $storeCode;
// ...

If not, please edit it and paste exception text if you get one.
Thanks.

 Signature 

- I would love to change the world, but they won’t give me the source code -

 
Magento Community Magento Community
Magento Community
Magento Community
 
chinesedream
Guru
 
Total Posts:  745
Joined:  2007-08-31
San Francisco, CA
 

Hi Moshe, thank for taking a look and I am greatly grateful.

I am getting different error though:

pdo_mysql extension is not installed
Trace:
#0 /home/citicomm/public_html/lib/Zend/Db/Adapter/Abstract.php(390): Varien_Db_Adapter_Pdo_Mysql->_connect()
#1 /home/citicomm/public_html/lib/Zend/Db/Adapter/Pdo/Abstract.php(206): Zend_Db_Adapter_Abstract->query(’SET NAMES utf8’, Array)
#2 /home/citicomm/public_html/app/code/core/Mage/Core/Model/Resource/Type/Db/Pdo/Mysql.php(39): Zend_Db_Adapter_Pdo_Abstract->query(’SET NAMES utf8’)
#3 /home/citicomm/public_html/app/code/core/Mage/Core/Model/Resource.php(77): Mage_Core_Model_Resource_Type_Db_Pdo_Mysql->getConnection(Object(Mage_Core_Model_Config_Element))
#4 /home/citicomm/public_html/app/code/core/Mage/Core/Model/Resource/Setup.php(54): Mage_Core_Model_Resource->getConnection(’core_setup’)
#5 /home/citicomm/public_html/app/code/core/Mage/Core/Model/Resource/Setup.php(110): Mage_Core_Model_Resource_Setup->__construct(’core_setup’)
#6 /home/citicomm/public_html/app/code/core/Mage/Core/Model/Config.php(195): Mage_Core_Model_Resource_Setup::applyAllUpdates()
#7 /home/citicomm/public_html/app/code/core/Mage/Core/Model/App.php(212): Mage_Core_Model_Config->init(Array)
#8 /home/citicomm/public_html/app/Mage.php(404): Mage_Core_Model_App->init(’’, ‘store’, Array)
#9 /home/citicomm/public_html/app/Mage.php(423): Mage::app(’’, ‘store’, Array)
#10 /home/citicomm/public_html/index.php(40): Mage::run()
#11 {main}

I realized that code you asked me to replace, matches the latest version, which I have not upgraded yet based on these :
@ryanb - since the packages are over-writing the code there should not be an issue to skip a version.

@ryanb: You can skip it, unless you are unhappy with the other bugs we have provided fixes for. It’s up to you, just review the release notes carefully.

I thought I will skip it till the next major upgrade in June. Now with this error, must I upgrade?
and here my the php info: http://74.52.59.43/phpinfo.php
I think the server is up to par.

Oh, also, here the replaced code in the Mage.php - I actually replaced it with the latest version soon after I saw the new error. THought it will make a different but obviously not.

public static function getIsDeveloperMode()
    
{
        
return self::$_isDeveloperMode;
    
}

    
/**
     * Display exception
     *
     * @param Exception $e
     */
    
public static function printException(Exception $e$extra '')
    
{
        
if (self::$_isDeveloperMode{
            
print '<pre>';

            if (!empty(
$extra)) {
                
print $extra "\n\n";
            
}

            
print $e->getMessage() . "\n\n";
            print 
$e->getTraceAsString();
            print 
'</pre>';
        
}
        
else {
            self
::getConfig()->createDirIfNotExists(self::getBaseDir('var') . DS 'report');
            
$reportId   intval(microtime(true) * rand(1001000));
            
$reportFile self::getBaseDir('var') . DS 'report' DS $reportId;
            
$reportData = array(
                !empty(
$extra) ? $extra "\n\n" '' $e->getMessage(),
                
$e->getTraceAsString()
            );
            
$reportData serialize($reportData);

            
file_put_contents($reportFile$reportData);
            
chmod($reportFile0777);

            
$storeCode 'default';
            try 
{
                $storeCode 
self::app()->getStore()->getCode();
            
}
            
catch (Exception $e{}

            $baseUrl 
rtrim(dirname($_SERVER['SCRIPT_NAME']), '/');
            
$reportUrl $baseUrl '/report/?id='
                
$reportId '&s;=' $storeCode;

            if (!
headers_sent()) {
                header
('Location: ' $reportUrl);
            
}
            
else {
                
print '<script type="text/javascript">';
                print 
"[removed].href = '{$reportUrl}';";
                print 
'</script>';
            
}
        }

        
die();
    
}

 
Magento Community Magento Community
Magento Community
Magento Community
 
Moshe
Magento Team
 
Avatar
Total Posts:  1771
Joined:  2007-08-07
Los Angeles
 

@chinesedream: you do not have PDO installed. Also make sure pdo_mysql is installed.

 Signature 

- I would love to change the world, but they won’t give me the source code -

 
Magento Community Magento Community
Magento Community
Magento Community
 
chinesedream
Guru
 
Total Posts:  745
Joined:  2007-08-31
San Francisco, CA
 
Moshe - 20 May 2008 07:00 PM

@chinesedream: you do not have PDO installed. Also make sure pdo_mysql is installed.

Moshe, thank you so much and so sorry! I should have double check many times the phpinfo - the scrolling of the file made me lose sight of it (though that shouldn’t be an excuse!).  The host didn’t upgrade the sever properly I believe.

Solved!

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top
 
Sales: Call 877.832.5289 (North America) 310.295.4144 (International)
© Copyright 2008 Varien. Magento, eCommerce software, is a trademark of Irubin Consulting Inc. DBA Varien
Privacy Policy|Terms of Service
Magento Community Count
53208 users|771 users currently online|107247 forum posts