I set up a cassandra cluster with 2 nodes. After a couple thousand of writes, it starts throwing TimeOut exceptions that don’t go away until after I restart the cassandra services. I am using phpcassa (latest at time of writing).
Cassandra.yaml both
cluster_name: 'Test Cluster'
seed_provider:
class_name: org.apache.cassandra.locator.SimpleSeedProvider
parameters:
seeds: "192.168.2.101"
rpc_address: 0.0.0.0
rpc_port: 8080
Cassandra.yaml 1
initial_token: 0
listen_address: 192.168.2.101
Cassandra.yaml 2
initial_token: 85070591730234615865843651857942052864
listen_address: 192.168.2.102
Assuming this configuration is correct, there must be an issue with my code. Here’s the test script I made to reproduce the error:
$pool = Config::ConnectionPool();
$stressTest = new ColumnFamily($pool, 'TwitterTest');
$id = 392766928478932992;
while(true)
{
try
{
$stressTest->insert($id++, array("analyzed"=>0, "followersCount"=>"35",
"friendsCount"=>"30", "lang"=>"en", "listedCount"=>"0",
"name"=>"Henky Tanky", "statusesCount"=>"X", "text"=>"#HERPDERP dude i kno i lost a 16gb flash drive #MEH",
"time"=>"2013-10-22 23:38:27", "twitterId"=>"392766928478932992", "username"=>"mehzor"),
null, null, \cassandra\ConsistencyLevel::ANY);
}
catch (Exception $ex){
print_r($ex);
exit;
}
}
class Config {
static function ConnectionPool(){
return new ConnectionPool('KSTwit', array('192.168.2.101:8080', '192.168.2.102:8080'));
}
}
With that config I get a 'cassandra\TimedOutException' (Stacktrace 1)
// Set max-retries to 5, and read/write timeout to 60 seconds
new ConnectionPool('KSTwit', array('192.168.2.101:8080', '192.168.2.102:8080'), NULL, 5, 60000, 60000);
With that config I get a 'Thrift\Exception\TTransportException' (Stacktrace 2)
I have tried various ConsistencyLevels;
ONE, QUORUM and ANY. Same issue with all of them.
As I said, the exceptions don’t occur until after a couple throusand of writes. However, if I restart the script after an exception ocurred it will throw exceptions immediately. I have to restart the cassandra services and then it can take a couple thousand again. This only seems to occur with writes. It also occurs if I don’t use counter columns so it’s not an issue with that.
Stack trace 1
Error performing add on 192.168.2.101:8080: exception 'cassandra\TimedOutException' in /var/installstuff/cassphp/lib/Thrift/Base/TBase.php:206
Stack trace:
#0 /var/installstuff/cassphp/lib/cassandra/Cassandra.php(3575): Thrift\Base\TBase->_read('Cassandra_add_r...', Array, Object(Thrift\Protocol\TBinaryProtocolAccelerated))
#1 /var/installstuff/cassphp/lib/cassandra/Cassandra.php(768): cassandra\Cassandra_add_result->read(Object(Thrift\Protocol\TBinaryProtocolAccelerated))
#2 /var/installstuff/cassphp/lib/cassandra/Cassandra.php(728): cassandra\CassandraClient->recv_add()
#3 [internal function]: cassandra\CassandraClient->add('All Tweets', Object(cassandra\ColumnParent), Object(cassandra\CounterColumn), 1)
#4 /var/installstuff/cassphp/lib/phpcassa/Connection/ConnectionPool.php(264): call_user_func_array(Array, Array)
#5 /var/installstuff/cassphp/lib/phpcassa/ColumnFamily.php(44): phpcassa\Connection\ConnectionPool->call('add', 'All Tweets', Object(cassandra\ColumnParent), Object(cassandra\CounterColumn), 1)
#6 /var/installstuff/cassphp/examples/db/TweetDatabase.php(103): phpcassa\ColumnFamily->add('All Tweets', 'Total')
#7 /var/installstuff/cassphp/examples/core/Helper.php(16): {closure}()
#8 /var/installstuff/cassphp/examples/db/TweetDatabase.php(104): Helper::DoForgiving(Object(Closure))
#9 /var/installstuff/cassphp/examples/core/twitterParser.php(98): TweetDatabaseCassandra->AddTweet('392633738364190...', Array)
#10 /var/installstuff/cassphp/examples/core/twitterParser.php(192): TwitterParser->RunOnce()
#11 /var/installstuff/cassphp/examples/runners/twitterParserCassandra.php(19): TwitterParser->Run()
#12 {main}
Stack trace 2
Error performing add on 192.168.2.101:8080: exception 'Thrift\Exception\TTransportException' with message 'TSocket: timed out reading 4 bytes from 192.168.2.101:8080' in /var/installstuff/cassphp/lib/Thrift/Transport/TSocket.php:284
Stack trace:
#0 /var/installstuff/cassphp/lib/Thrift/Transport/TTransport.php(74): Thrift\Transport\TSocket->read(4)
#1 /var/installstuff/cassphp/lib/Thrift/Transport/TFramedTransport.php(139): Thrift\Transport\TTransport->readAll(4)
#2 /var/installstuff/cassphp/lib/Thrift/Transport/TFramedTransport.php(106): Thrift\Transport\TFramedTransport->readFrame()
#3 /var/installstuff/cassphp/lib/Thrift/Transport/TTransport.php(74): Thrift\Transport\TFramedTransport->read(4)
#4 /var/installstuff/cassphp/lib/Thrift/Protocol/TBinaryProtocol.php(305): Thrift\Transport\TTransport->readAll(4)
#5 /var/installstuff/cassphp/lib/Thrift/Protocol/TBinaryProtocol.php(197): Thrift\Protocol\TBinaryProtocol->readI32(NULL)
#6 /var/installstuff/cassphp/lib/cassandra/Cassandra.php(760): Thrift\Protocol\TBinaryProtocol->readMessageBegin(NULL, 0, 0)
#7 /var/installstuff/cassphp/lib/cassandra/Cassandra.php(728): cassandra\CassandraClient->recv_add()
#8 [internal function]: cassandra\CassandraClient->add('All Tweets', Object(cassandra\ColumnParent), Object(cassandra\CounterColumn), 1)
#9 /var/installstuff/cassphp/lib/phpcassa/Connection/ConnectionPool.php(264): call_user_func_array(Array, Array)
#10 /var/installstuff/cassphp/lib/phpcassa/ColumnFamily.php(44): phpcassa\Connection\ConnectionPool->call('add', 'All Tweets', Object(cassandra\ColumnParent), Object(cassandra\CounterColumn), 1)
#11 /var/installstuff/cassphp/examples/db/TweetDatabase.php(103): phpcassa\ColumnFamily->add('All Tweets', 'Total')
#12 /var/installstuff/cassphp/examples/core/Helper.php(17): {closure}()
#13 /var/installstuff/cassphp/examples/db/TweetDatabase.php(104): Helper::DoForgiving(Object(Closure))
#14 /var/installstuff/cassphp/examples/core/twitterParser.php(98): TweetDatabaseCassandra->AddTweet('392642135327264...', Array)
#15 /var/installstuff/cassphp/examples/core/twitterParser.php(192): TwitterParser->RunOnce()
#16 /var/installstuff/cassphp/examples/runners/twitterParserCassandra.php(19): TwitterParser->Run()
#17 {main}
The cassandra log doesn't really show anything interesting. Except for this ocurring a lot, but that happens even when the exceptions don't occur so I don't think it's the issue;
INFO 10:58:58,241 Timed out replaying hints to /192.168.2.102; aborting further deliveries
WARN 11:07:17,979 MemoryMeter uninitialized (jamm not specified as java agent); assuming liveRatio of 10.0. Usually this means cassandra-env.sh disabled jamm because you are using a buggy JRE; upgrade to the Sun JRE instead
Keyspace is setup using ‘SIMPLE_STRATEGY’ and ‘replication_factor=2’ According to the ‘nodetool ring’ command on both machines, the nodes are functioning ‘normal’ even after the exceptions have been triggered. I honestly don’t know what to try next, can anyone spot the issue?
I fixed the issue in one of two ways (can't be sure.)
I initially installed cassandra using a guide online which listed these repo's;
deb http://www.apache.org/dist/cassandra/debian 11x main
deb-src http://www.apache.org/dist/cassandra/debian 11x main
These are outdated, there's a 20x version, so I updated to that.
I also replaced jsvc with sun's java. It's all working fine now.
Related
I am building a laravel application and everything seems to be working fine, except for the fact that I keep getting these errors appearing in the log file continuously. I mean they are showing up every few minutes, sometimes more often, sometimes less - it's making harder to find real problems in the log file. Except of these problems, they aren't really causing any problems - I have an App::missing method to take care of real users.
Do you have any idea of where to look for the solution?
[2014-05-15 19:58:20] local.ERROR: exception 'Symfony\Component\HttpKernel\Exception\NotFoundHttpException' with message 'Controller method not found.' in /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/Controller.php:254
Stack trace:
#0 [internal function]: Illuminate\Routing\Controller->missingMethod(Array)
#1 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/Controller.php(231): call_user_func_array(Array, Array)
#2 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php(93): Illuminate\Routing\Controller->callAction('missingMethod', Array)
#3 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php(62): Illuminate\Routing\ControllerDispatcher->call(Object(HomeController), Object(Illuminate\Routing\Route), 'missingMethod')
#4 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/Router.php(934): Illuminate\Routing\ControllerDispatcher->dispatch(Object(Illuminate\Routing\Route), Object(Illuminate\Http\Request), 'HomeController', 'missingMethod')
#5 [internal function]: Illuminate\Routing\Router->Illuminate\Routing\{closure}(Array)
#6 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/Route.php(105): call_user_func_array(Object(Closure), Array)
#7 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/Router.php(1000): Illuminate\Routing\Route->run(Object(Illuminate\Http\Request))
#8 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Routing/Router.php(968): Illuminate\Routing\Router->dispatchToRoute(Object(Illuminate\Http\Request))
#9 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(738): Illuminate\Routing\Router->dispatch(Object(Illuminate\Http\Request))
#10 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(708): Illuminate\Foundation\Application->dispatch(Object(Illuminate\Http\Request))
#11 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Http/FrameGuard.php(38): Illuminate\Foundation\Application->handle(Object(Illuminate\Http\Request), 1, true)
#12 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Session/Middleware.php(72): Illuminate\Http\FrameGuard->handle(Object(Illuminate\Http\Request), 1, true)
#13 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Cookie/Queue.php(47): Illuminate\Session\Middleware->handle(Object(Illuminate\Http\Request), 1, true)
#14 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Cookie/Guard.php(51): Illuminate\Cookie\Queue->handle(Object(Illuminate\Http\Request), 1, true)
#15 /Applications/MAMP/htdocs/gran.pw/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Illuminate\Cookie\Guard->handle(Object(Illuminate\Http\Request), 1, true)
#16 /Applications/MAMP/htdocs/gran.pw/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(606): Stack\StackedHttpKernel->handle(Object(Illuminate\Http\Request))
#17 /Applications/MAMP/htdocs/gran.pw/public/index.php(49): Illuminate\Foundation\Application->run()
#18 {main} [] []
Its a 404 for a non existant url.
i.e. http://example.com/this-url-does-not-exist
To see which URL is actually causing the 404 - add this to your filters file
App::missing(function($exception)
{
Log::error('Missing URL was: ' . Request::fullUrl());
});
It will record the URL that any exception occurs on in your logs.
It is most likely due to either a search engine bot trying to search for old links, or could be some broken links within your application.
I did mention this to Taylor as a possible bug in Laravel 4.1 - that the http exception does not record the missing url - but it was closed at the time. I might re-open it as I'm sure it is a bug (since old 404 did record the url).
Looks like your HomeController is not extending Laravel's controller:
class HomeController extends Controller {
}
Because the method missingMethod is missing from yours and this one is in the Laravel Controller base class.
I was just on the verge of turning my site live, as I had to update my database to the sites current standards for sales orders and transactions and what not so they fell just in line. I imported the sales files from the live database to the soon to be live database, which had been working perfectly prior to this. Once the updated sales and orders files were updated, my checkout process fails on the very last step of hitting 'Place Order' .. It goes into the submitting process, then simply comes up with a popup message stating "There was an error processing your order. Please contact us or try again later." Click okay, and you just stare at your waiting cart. I have looked around and tried a few things, to no avail. So I come to you all knowing stack crew!
This is the error log I am getting now;
exception 'PDOException' with message 'SQLSTATE[HY093]: Invalid parameter number: parameter was not defined' in /www/www/store/lib/Zend/Db/Statement/Pdo.php:228
Stack trace:
#0 /www/www/store/lib/Zend/Db/Statement/Pdo.php(228): PDOStatement- >execute(Array)
#1 /www/www/store/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#2 /www/www/store/app/code/core/Zend/Db/Statement.php(291): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#3 /www/www/store/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#4 /www/www/store/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT `sales_f...', Array)
#5 /www/www/store/lib/Varien/Db/Adapter/Pdo/Mysql.php(428): Zend_Db_Adapter_Pdo_Abstract->query('SELECT `sales_f...', Array)
#6 /www/www/store/lib/Zend/Db/Adapter/Abstract.php(825): Varien_Db_Adapter_Pdo_Mysql->query(Object(Varien_Db_Select), Array)
#7 /www/www/store/app/code/local/Mage/Sales/Model/Resource/Quote.php(169): Zend_Db_Adapter_Abstract->fetchOne(Object(Varien_Db_Select), Array)
#8 /www/www/store/app/code/core/Mage/Sales/Model/Quote.php(1637): Mage_Sales_Model_Resource_Quote->isOrderIncrementIdUsed('100014532')
#9 /www/www/store/app/code/core/Mage/Sales/Model/Service/Quote.php(147): Mage_Sales_Model_Quote->reserveOrderId()
#10 /www/www/store/app/code/core/Mage/Sales/Model/Service/Quote.php(249): Mage_Sales_Model_Service_Quote->submitOrder()
#11 /www/www/store/app/code/core/Mage/Checkout/Model/Type/Onepage.php(785): Mage_Sales_Model_Service_Quote->submitAll()
#12 /www/www/store/app/code/core/Mage/Checkout/controllers/OnepageController.php(579): Mage_Checkout_Model_Type_Onepage->saveOrder()
#13 /www/www/store/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Checkout_OnepageController->saveOrderAction()
#14 /www/www/store/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('saveOrder')
#15 /www/www/store/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#16 /www/www/store/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#17 /www/www/store/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#18 /www/www/store/index.php(87): Mage::run('', 'store')
#19 {main}
Next exception 'Zend_Db_Statement_Exception' with message 'SQLSTATE[HY093]: Invalid parameter number: parameter was not defined' in /www/www/store/lib/Zend/Db/Statement/Pdo.php:234
Stack trace:
#0 /www/www/store/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#1 /www/www/store/app/code/core/Zend/Db/Statement.php(291): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#2 /www/www/store/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#3 /www/www/store/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('SELECT `sales_f...', Array)
#4 /www/www/store/lib/Varien/Db/Adapter/Pdo/Mysql.php(428): Zend_Db_Adapter_Pdo_Abstract->query('SELECT `sales_f...', Array)
#5 /www/www/store/lib/Zend/Db/Adapter/Abstract.php(825): Varien_Db_Adapter_Pdo_Mysql->query(Object(Varien_Db_Select), Array)
#6 /www/www/store/app/code/local/Mage/Sales/Model/Resource/Quote.php(169): Zend_Db_Adapter_Abstract->fetchOne(Object(Varien_Db_Select), Array)
#7 /www/www/store/app/code/core/Mage/Sales/Model/Quote.php(1637): Mage_Sales_Model_Resource_Quote->isOrderIncrementIdUsed('100014532')
#8 /www/www/store/app/code/core/Mage/Sales/Model/Service/Quote.php(147): Mage_Sales_Model_Quote->reserveOrderId()
#9 /www/www/store/app/code/core/Mage/Sales/Model/Service/Quote.php(249): Mage_Sales_Model_Service_Quote->submitOrder()
#10 /www/www/store/app/code/core/Mage/Checkout/Model/Type/Onepage.php(785): Mage_Sales_Model_Service_Quote->submitAll()
#11 /www/www/store/app/code/core/Mage/Checkout/controllers/OnepageController.php(579): Mage_Checkout_Model_Type_Onepage->saveOrder()
#12 /www/www/store/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Checkout_OnepageController->saveOrderAction()
#13 /www/www/store/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('saveOrder')
#14 /www/www/store/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#15 /www/www/store/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#16 /www/www/store/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#17 /www/www/store/index.php(87): Mage::run('', 'store')
#18 {main}
I can see they are both dealing with the same invalid parameter, but I assume if I just fix that one single parameter (which is probably just the parameter for my one personally made user account I assume) it would still error for some other, not effectively solving the issue. So I have to ask, does this give anyone an idea of what the heck I did to blow up my store?! Thanks for your time guys, truly!
First, looking at your specific error
exception 'PDOException' with message SQLSTATE[HY093]: Invalid parameter number: parameter was not defined
This is PHP's database layers saying "someone used me wrong". Specifically, it looks like someone used a parameterized query where they included a blank and/or invalid parameter.
Second, looking at your stack trace, I noticed this.
/www/www/store/app/code/local/Mage/Sales/Model/Resource/Quote.php(169): Zend_Db_Adapter_Abstract->fetchOne(Object(Varien_Db_Select), Array)
Specifically, it looks like you, or someone, has created a code pool override for the quote resource model. Everything else being equal, I'd say it's likely the change you made to this file from the file in core is what's causing your problem. Likely in this method (around line 169)
#File: app/code/core/Mage/Sales/Model/Resource/Quote.php
public function isOrderIncrementIdUsed($orderIncrementId)
{
$adapter = $this->_getReadAdapter();
$bind = array(':increment_id' => (int)$orderIncrementId);
$select = $adapter->select();
$select->from($this->getTable('sales/order'), 'entity_id')
->where('increment_id = :increment_id');
$entity_id = $adapter->fetchOne($select, $bind);
if ($entity_id > 0) {
return true;
}
return false;
}
My guess is you've either jiggered with the $bind array
$entity_id = $adapter->fetchOne($select, $bind);
or included additional query parameters in the SQL that aren't accounted for.
->where('increment_id = :increment_id');
I have a Magento 1.8 installation which was working fine up until yesterday evening at which point changing any config settings in the admin area stopped working.
E.g. If I change 'store name' to anything different and clicking save: it says "The configuration has been saved" in the green bar at the top but the value stays as it previously was.
Checking in phpMyAdmin the value is unchanged, however you can change it manually in phpMyAdmin and this will be reflected in the admin backend.
Switching on developer mode, initially got me the following when I tried to load any page:
Strict Notice: Only variables should be passed by reference in /home/user/dev/lib/Varien/Db/Adapter/Pdo/Mysql.php on line 2765
#0 /home/user/dev/lib/Varien/Db/Adapter/Pdo/Mysql.php(2765): mageCoreErrorHandler(2048, 'Only variables ...', '/home/user/de...', 2765, Array)
#1 /home/user/dev/lib/Varien/Data/Collection/Db.php(483): Varien_Db_Adapter_Pdo_Mysql->prepareSqlCondition('path', Array)
#2 /home/user/dev/lib/Varien/Data/Collection/Db.php(414): Varien_Data_Collection_Db->_getConditionSql('path', Array)
#3 /home/user/dev/lib/Varien/Data/Collection/Db.php(385): Varien_Data_Collection_Db->_translateCondition('path', Array)
#4 /home/user/dev/app/code/core/Mage/Core/Model/Resource/Config/Data/Collection.php(58): Varien_Data_Collection_Db->addFieldToFilter('path', Array)
#5 /home/user/dev/app/code/core/Mage/Adminhtml/Model/Config/Data.php(306): Mage_Core_Model_Resource_Config_Data_Collection->addScopeFilter('default', 0, 'general')
#6 /home/user/dev/app/code/core/Mage/Adminhtml/Model/Config/Data.php(292): Mage_Adminhtml_Model_Config_Data->_getPathConfig('general', false)
#7 /home/user/dev/app/code/core/Mage/Adminhtml/Model/Config/Data.php(221): Mage_Adminhtml_Model_Config_Data->_getConfig(false)
#8 /home/user/dev/app/code/core/Mage/Adminhtml/Model/Config/Data.php(334): Mage_Adminhtml_Model_Config_Data->load()
#9 /home/user/dev/app/code/core/Mage/Paypal/Model/Observer.php(134): Mage_Adminhtml_Model_Config_Data->getConfigDataValue('paypal/general/...')
#10 /home/user/dev/app/code/core/Mage/Core/Model/App.php(1338): Mage_Paypal_Model_Observer->loadCountryDependentSolutionsConfig(Object(Varien_Event_Observer))
#11 /home/user/dev/app/code/core/Mage/Core/Model/App.php(1317): Mage_Core_Model_App->_callObserverMethod(Object(Mage_Paypal_Model_Observer), 'loadCountryDepe...', Object(Varien_Event_Observer))
#12 /home/user/dev/app/Mage.php(447): Mage_Core_Model_App->dispatchEvent('adminhtml_init_...', Array)
#13 /home/user/dev/app/code/core/Mage/Adminhtml/Model/Config.php(93): Mage::dispatchEvent('adminhtml_init_...', Array)
#14 /home/user/dev/app/code/core/Mage/Adminhtml/Model/Config.php(63): Mage_Adminhtml_Model_Config->_initSectionsAndTabs()
#15 /home/user/dev/app/code/core/Mage/Adminhtml/controllers/System/ConfigController.php(88): Mage_Adminhtml_Model_Config->getSections('general')
#16 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Adminhtml_System_ConfigController->editAction()
#17 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('edit')
#18 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#19 /home/user/dev/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#20 /home/user/dev/app/Mage.php(683): Mage_Core_Model_App->run(Array)
#21 /home/user/dev/index.php(87): Mage::run('', 'store')
#22 {main}
Looking up /home/user/dev/lib/Varien/Db/Adapter/Pdo/Mysql.php on line 2765:
$key = key(array_intersect_key($condition, $conditionKeyMap));
Which made no sense to me, but something to do with MySQL seemed like I might be on the right track... I googled the error and found this: http://www.magentocommerce.com/boards/v/viewthread/266575/ - and tried the suggestion of replacing line 2795 with:
$tmp = array_intersect_key($condition, $conditionKeyMap);
$key = key($tmp);
Which resulted in the following dev mode error:
Method "addJqueryLibrary" is not defined in "Magentothem_Upsellslider_Model_Layout_Generate_Observer"
#0 /home/user/dev/app/code/core/Mage/Core/Model/App.php(1340): Mage::throwException('Method "addJque...')
#1 /home/user/dev/app/code/core/Mage/Core/Model/App.php(1317): Mage_Core_Model_App->_callObserverMethod(Object(Magentothem_Upsellslider_Model_Layout_Generate_Observer), 'addJqueryLibrar...', Object(Varien_Event_Observer))
#2 /home/user/dev/app/Mage.php(447): Mage_Core_Model_App->dispatchEvent('controller_acti...', Array)
#3 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Action.php(351): Mage::dispatchEvent('controller_acti...', Array)
#4 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Action.php(269): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#5 /home/user/dev/app/code/core/Mage/Adminhtml/Controller/Action.php(275): Mage_Core_Controller_Varien_Action->loadLayout(NULL, true, true)
#6 /home/user/dev/app/code/core/Mage/Adminhtml/controllers/System/ConfigController.php(95): Mage_Adminhtml_Controller_Action->loadLayout()
#7 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Adminhtml_System_ConfigController->editAction()
#8 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('edit')
#9 /home/user/dev/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#10 /home/user/dev/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#11 /home/user/dev/app/Mage.php(683): Mage_Core_Model_App->run(Array)
#12 /home/user/dev/index.php(87): Mage::run('', 'store')
#13 {main}
If you switch developer mode off now, the same thing happens, says its saved but no change.
Just found in /var/exception.log another error that says:
exception 'Mage_Core_Exception' with message 'Invalid block type: Fishpig_FPAdmin_Block_Adminhtml_Extend' in /home/pieboy/dev/app/Mage.php:594
(followed by another stack trace)
I'm pretty much at my wits end with what to try next and out of my depth. The store is using a paid for theme which included a lot of extensions which I didn't personally install, but it has been working completely fine up until now.
The most recent extension I installed was this:
http://www.magentocommerce.com/magento-connect/stripe-for-magento.html
As far as I could tell it all went smoothly, and I've been editing config settings since, but it was when I went to enable it in the payment methods area that I noticed the problem.
I know this was a lot of reading, but was just trying to get down all the info. Any suggestions at all on how to debug from here are welcome.
EDIT: I uninstalled Fishpig and Magentothem upsellslider extensions, and now I get no errors or exceptions at all in dev mode but still the same behaviour with config settings not saving.
With the help of my hosting company, we tracked this down to being caused by suhosin, they increased the following suhosin limits in the php.ini file for my server which resolved the issue:
suhosin.post.max_vars = 1000
suhosin.request.max_vars = 1000
(Thought I would update here in case anyone in the same boat googles it!)
There is many topics like that all over the internet, but because i have NO IDEA what to do with answers i must ask it again.
I was transferring website from one server to another and after transfer i saw:
exception 'Zend_Loader_PluginLoader_Exception' with message 'Plugin by name 'Word_CamelCaseToDash' was not found in the registry; used paths:
Zend_Filter_: Zend/Filter/' in /library/Zend/Loader/PluginLoader.php:412
Stack trace:
#0 /library/Zend/Filter/Inflector.php(518): Zend_Loader_PluginLoader->load('Word_CamelCaseT...')
#1 /library/Zend/Filter/Inflector.php(411): Zend_Filter_Inflector->_getRule('Word_CamelCaseT...')
#2 /library/Zend/Filter/Inflector.php(311): Zend_Filter_Inflector->addFilterRule(':module', Array)
#3 /library/Zend/Controller/Action/Helper/ViewRenderer.php(281): Zend_Filter_Inflector->addRules(Array)
#4 /library/Zend/Controller/Action/Helper/ViewRenderer.php(381): Zend_Controller_Action_Helper_ViewRenderer->getInflector()
#5 /library/Zend/Controller/Action/Helper/ViewRenderer.php(469): Zend_Controller_Action_Helper_ViewRenderer->_getBasePath()
#6 /library/Zend/Controller/Action/Helper/ViewRenderer.php(516): Zend_Controller_Action_Helper_ViewRenderer->initView()
#7 /library/Zend/Controller/Action/HelperBroker.php(253): Zend_Controller_Action_Helper_ViewRenderer->init()
#8 /library/Zend/Controller/Action.php(132): Zend_Controller_Action_HelperBroker->__construct(Object(ErrorController))
#9 /library/Zend/Controller/Dispatcher/Standard.php(262): Zend_Controller_Action->__construct(Object(Zend_Controller_Request_Http), Object(Zend_Controller_Response_Http), Array)
#10 /library/Zend/Controller/Front.php(954): Zend_Controller_Dispatcher_Standard->dispatch(Object(Zend_Controller_Request_Http), Object(Zend_Controller_Response_Http))
#11 /index.php(39): Zend_Controller_Front->dispatch()
#12 {main}
Honestly i have no skill in Zend, so if anyone could tell me what is wrong with it? (website worker on previous hosting without a problem).
A file named CamelCaseToDash.php under Word directory is missing check that file first.
If the file exist than check in your configuration file whether the autoloadnamespace is for Word is added
I cannot find any documentation on how to read the exception.log in Magento; where is the documentation on how to read this?
If there is no documentation in what order are the exceptions printed?
Did #0 happen last or did it happen first?
Stack trace:
#0 .../html/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array)
#1 .../html/lib/Zend/Db/Statement.php(300): Varien_Db_Statement_Pdo_Mysql->_execute(Array)
#2 .../html/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array)
#3 .../html/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('select eav_opti...', Array)
#4 .../html/lib/Varien/Db/Adapter/Pdo/Mysql.php(419): Zend_Db_Adapter_Pdo_Abstract->query('select eav_opti...', Array)
#5 .../html/app/code/local/FME/Manufacturers/Model/Observer/Product.php(47): Varien_Db_Adapter_Pdo_Mysql->query('select eav_opti...')
#6 .../html/app/code/core/Mage/Core/Model/App.php(1338): FME_Manufacturers_Model_Observer_Product->saveTabData(Object(Varien_Event_Observer))
#7 .../html/app/code/core/Mage/Core/Model/App.php(1317): Mage_Core_Model_App->_callObserverMethod(Object(FME_Manufacturers_Model_Observer_Product), 'saveTabData', Object(Varien_Event_Observer))
#8 .../html/app/Mage.php(447): Mage_Core_Model_App->dispatchEvent('catalog_product...', Array)
#9 .../html/app/code/core/Mage/Core/Model/Abstract.php(466): Mage::dispatchEvent('catalog_product...', Array)
#10 .../html/app/code/core/Mage/Catalog/Model/Product.php(548): Mage_Core_Model_Abstract->_afterSave()
#11 .../html/app/code/core/Mage/Core/Model/Abstract.php(319): Mage_Catalog_Model_Product->_afterSave()
#12 .../html/app/code/core/Mage/Adminhtml/controllers/Catalog/ProductController.php(714): Mage_Core_Model_Abstract->save()
#13 .../html/app/code/core/Mage/Core/Controller/Varien/Action.php(419): Mage_Adminhtml_Catalog_ProductController->saveAction()
#14 .../html/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('save')
#15 .../html/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#16 .../html/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#17 .../html/app/Mage.php(683): Mage_Core_Model_App->run(Array)
#18 .../html/index.php(91): Mage::run('', 'store')
#19 {main}
This is a regular PHP Exception Stack Trace; it's not specific to Magento.
Line #0 tells us, that the line 110 of the file lib/Varien/Db/Statement/Pdo/Mysql.php managed to successfully call the method Zend_Db_Statement_Pdo->_execute(), but then execution of one of the commands of this method resulted in throwing an Exception.
Simply spoken, a Stack Trace is just a list of method/function calls, that an application was in the middle of execution of when an Exception was thrown.
Code execution started at #19 {main} (bottom of the stack).
#18, {main} was executed untilmethod Mage::run() was calledin line 91 of index.php
#17, Mage::run() was executed untilmethod Mage_Core_Model_App->run() was calledin line 683 of app/Mage.php
:
#1, Zend_Db_Statement->execute() was executed untilmethod Varien_Db_Statement_Pdo_Mysql->_execute() was calledin line 300 of lib/Zend/Db/Statement.php
#0, Varien_Db_Statement_Pdo_Mysql->_execute() was executed untilmethod Zend_Db_Statement_Pdo->_execute() was calledin line 110 of lib/Varien/Db/Statement/Pdo/Mysql.php,but some command of this method caused throwing an exception.
As a side note, I wouldn't generally say a stack trace is "going down the list of functions that are failing", like #pzirkind mentioned in his answer.
Because if the method called in #0 (top of the stack) wouldn't have "failed", many of the methods called before may still work as expected (and many usually do, at least to my experience), or even catch the thrown exception.
Zero happened last.
What's happening is that it's going down the list of functions that are failing.
It starts with the actual function that failed and then shows you how it continued to cause other things to fail (this makes it easier to trace a deeper problem if it exists).
Pesach