3

I'm seeing weird errors in my system.log:

2014-12-01T13:35:05+00:00 ERR (3): Warning: simplexml_load_string(): Entity: line 47: parser error : Opening and ending tag mismatch: config line 1 and default  in /var/www/magento.live/htdocs/lib/Varien/Simplexml/Config.php on line 383
2014-12-01T13:35:05+00:00 ERR (3): Warning: simplexml_load_string(): eMonitoring_Model_Widget_Log_Tail></widgets></global></magemonitoring></default>  in /var/www/magento.live/htdocs/lib/Varien/Simplexml/Config.php on line 383

Not being new to troubleshooting Magento errors I started disabling the module I suspected causing the trouble, clearing the cache and checking the log again. Now the same error appears, yet points to another module.... Disabled that and guess? ... Yup. The error still appears.

I had success before dealing with XML-validation errors by checking if all Magento XML files are valid or not:

find . -name "*.xml" -type f -exec xmllint --noout '{}' \;

This told me that all XML files in the Magento folder structure are valid. Yet apparently Config.php still chokes on this error.

Anybody a clue on how to troubleshoot further?

0

As the error says, there is a tag mismatch no matter what your find command says.

Do a find . | xargs grep 'eMonitoring' -sl in app/code/local and you will find where is this string(node) this being used and you will be able to fix this.

  • I know what extension is mentioned in the log, completely removed it (deinstalled using modman), cleared the cache, yet the error keeps showing. I added "Mage::log(print_r($xmlString, true)); // Debug output Mage::log(print_r($this->_elementClass, true)); // Debug output" to config.php just below line 383 and according to online validators it indeed spits out invalid xml. Still config parts of this now completely uninstalled module. I'm going to see if there is anything left in core_config_data table – Ottonet Dec 1 '14 at 14:38
  • Any other cache being used? Maybe a file somewhere else like a layout? – mbalparda Dec 1 '14 at 14:43
  • 1
    In the end it was indeed this one extension that caused problems, after removing the corresponding rows from core_config_data and a flush of the cache the problem seemed to have disappeared. Luckily it's a non-essential extension. – Ottonet Dec 1 '14 at 14:55
2

I added the following code to Config.php (Core editing, a big NO NO, so I made a backup copy so I could revert back once debugging was done), just below line 383:

Mage::log(print_r($xmlString, true)); // Debug output 
Mage::log(print_r($this->_elementClass, true)); // Debug output

I now ended up with XML in the system.log that was indeed invalid once I pasted it into one of these online xml-validation tools.

All pointed to this one extension ('eMonitoring' = https://github.com/magento-hackathon/Hackathon_MageMonitoring), even though I had it completely removed the error didn't go away.

Only after going into the DB, opening core_config_data table and removing all rows that corresponded to this extension, and flushing the cache after that, the errors went away.

Weird thing is that the same extension in my 1:1 development copy works like a charm. But for now completely removing the extension was the quickest fix for this problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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