CentOS 7.x Mediawiki Debug internal error

From Notes_Wiki
Revision as of 11:40, 15 March 2020 by Saurabh (talk | contribs) (Created page with "<yambe:breadcrumb self="Debug internal error">CentOS 7.x Mediawiki|Mediawiki</yambe:breadcrumb> =CentOS 7.x Mediawiki Debug internal error= If mediawiki is crashing with Inte...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

<yambe:breadcrumb self="Debug internal error">CentOS 7.x Mediawiki|Mediawiki</yambe:breadcrumb>

CentOS 7.x Mediawiki Debug internal error

If mediawiki is crashing with Internal error, often due to issue with an extension, then add following to LocalSettings.php file:

$wgShowExceptionDetails = true;

After this perform the action again to get stack trace. Once you know where the issue is, you can debug by adding echo / die statements in php code to get more details. Often there is issue with the input to extension which extension does not expects or is unable to parse and hence crashes. If we print various variable values related to function where crash is happening, we can determine which input is leading to such crashes.

For example if Configuring yambe breadcrumbs extension for mediawiki is used and instead of self="Title" we accidentally type self"Title" without equal to "=", leading to malformed XML, the yambe extension crashes the mediawiki. To figure out that this is due to certain input we can print various values near the function which has crashed and recognize that we missed typing equal to(=) sign.