MediaWiki internal error.

Original exception: [b1877f15] /wiki/Iomedae Exception from line 1157 of /var/www/wiki/includes/db/Database.php: A database error has occurred. Did you forget to run maintenance/update.php after upgrading? See: https://www.mediawiki.org/wiki/Manual:Upgrading#Run_the_update_script
Query: SELECT page_id,page_namespace,page_title,page_is_redirect,page_len,page_latest FROM `mw_page` WHERE (page_namespace = '0' AND page_title IN ('Erik_Mona','Campaign_Setting','Paizo_Publishing,_LLC','Sean_K_Reynolds','Gods_and_Magic','Paizo_Publishing,_LLC','Rob_McCreary','The_Hellfire_Compact','Paizo_Inc','Erik_Mona','Campaign_Setting','Paizo_Publishing,_LLC','Erik_Mona','Campaign_Setting','Paizo_Publishing,_LLC','Erik_Mona','Campaign_Setting','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','Erik_Mona','A_Song_of_Silver','Paizo_Inc','Sean_K_Reynolds','Mother_of_Flies','Paizo_Publishing,_LLC','Judy_Bauer','Heaven_Unleashed','Paizo_Inc','Sean_K_Reynolds','Inner_Sea_Gods','Paizo_Inc','Sean_K_Reynolds','Inner_Sea_Gods','Paizo_Inc','Erik_Mona','Campaign_Setting','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','Hal_Maclean','Amber_E._Scott','Halflings_of_Golarion','Paizo_Publishing,_LLC','Hal_Maclean','Amber_E._Scott','Halflings_of_Golarion','Paizo_Publishing,_LLC','Gareth_Hanrahan','Steve_Kenson','Patrick_Renie','Tork_Shaw','Jerome_Virnich','Knights_of_the_Inner_Sea','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','Sean_K_Reynolds','Inner_Sea_Gods','Paizo_Inc','Sean_K_Reynolds','Gods_and_Magic','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','Erik_Mona','Campaign_Setting','Paizo_Publishing,_LLC','Colin_McComb','Faiths_of_Purity','Paizo_Publishing,_LLC','Colin_McComb','Faiths_of_Purity','Paizo_Publishing,_LLC','James_Jacobs','The_Inner_Sea_World_Guide','Paizo_Publishing,_LLC','Iomedae\'s_Realm','Heaven','Lawful_good','Lawful_good','Neutral_good','Chaotic_good','Lawful_neutral','Neutral','Chaotic_neutral','Lawful_evil','Neutral_evil','Chaotic_evil','Longsword','Lion','The_Inner_Sea_World_Guide','Goddess','Aroden','Aroden','Good','Evil','Chelaxian_(human_ethnicity)','Human','Cheliax','3800_AR','Shining_Crusade','3816_AR','Knights_of_Ozem','Whispering_Tyrant','Artifact','Heart\'s_Edge','3826_AR','Sword','Whispering_Tyrant','Iomedae\'s_Sixth_Act','3831_AR','Iomedae\'s_Tenth_Act','Kantaria','Faceless_stalker','Veiled_master','3832_AR','Test_of_the_Starstone','Herald','Arazni','4606_AR','Abadar','Cayden_Cailean','Erastil','Sarenrae','Shelyn','Torag','Pharasma','Irori','Asmodeus','Fiend','Hell','Plate_mail','Longsword','Shield','Axis','Iomedae\'s_Realm','Proelera','Heaven','Deity','Archon','Weapon','Gold','Silver','Gold_dragon','Parnoneryx','Divine_servitor','Angel','Iophanite','Harbinger','Lantern_archon','Hand_of_the_Inheritor','Herald','Angel','Jingh','Peace_Through_Vigilance','Celestial','Gold_dragon','Lymirin','Eagle','Humanoid','God','Test_of_the_Starstone','Mendevian_Crusades','Worldwound','Aroden','Deskari','Demon_lord','Abyss','First_Mendevian_Crusade','4622_AR','Aroden','Mendev','Absalom','Andoran','Cheliax','Galt','Lastwall','Molthune','Nirmathas','Numeria','Sargava','Chelaxian_(human_ethnicity)','Taldan','Halfling','Inner_Sea_region','Adventurer','Halfling','Slavery','Paladin','Knight','Paladin','Obedience','Divine_magic','Boon','Holy_symbol','Cleric','Acts_of_Iomedae','Acts_of_Iomedae','Seventh_Church','Lamashan','Ascendance_Day','Inheritor\'s_Ascendance','Arodus','Rova','Day_of_the_Inheritor','First_Crusader_Day','Armasse','Remembrance_Moon','Desnus','Hellknights','Order_of_the_Godclaw','Deity','Pathfinder_campaign_setting','Abadar','Asmodeus','Calistria','Cayden_Cailean','Desna','Erastil','Gorum','Gozreh','Irori','Lamashtu','Nethys','Norgorber','Pharasma','Rovagug','Sarenrae','Shelyn','Torag','Urgathoa','Zon-Kuthon','Abadar','Daikitsu','Desna','Fumeiyoshi','General_Susumu','Hei_Feng','Irori','Kofusachi','Lady_Nanbyo','Lamashtu','Lao_Shu_Po','Nalinivati','Pharasma','Qi_Zhong','Shelyn','Shizuru','Sun_Wukong','Tsukiyo','Yaezhing','Yamatsumi','Acavna','Achaekek','Aegirran','Ahriman','Alazhra','Alseta','Amaznen','Angradd','Anubis','Apep','Apsu','Arazni','Aroden','Arundhat','Azghat','Azhia','Bastet','Bergelmir','Bes','Besmara','Bolka','Brigh','Camazotz','Chaldira_Zuzaristan','Chamidu','Child-Goddess','Curchanus','Dahak','Dhalavei','Diomazul','Dranngvit','Dretha','Droskar','Easivra','Erecura','Eternal_Emperor','Fandarra','Feronia','Findeladlara','Folgrit','Ghlaunder','Groetus','Gruhastha','Grundinnar','Gyronna','Hadregash','Haggakal','Hanspur','Hathor','Horus','Ihys','Isis','Kelksiomides','Ketephys','Khepri','Kitumu','Kols','Kurgess','Lahkgya','Lanishra','Likha','Lissala','Maat','Magrim','Mestama','Milani','Minderhal','Morlock','Naderi','Namzaruum','Neith','Nephthys','Nivi_Rhombodazzle','Nulgreth','Osiris','Outer_God','Peacock_Spirit','Perbov','Prathos','Psomeira','Ptah','Pulura','Ra','Ragdya','Raumya','Rheth','Roidira','Rull','Sekhmet','Selket','Set','Sezelrian','Shimye-Magalla','Shumbauth','Sivanah','Skode','Skrymir','Sobek','Suyuddha','Thamir','Thoth','Thremyr','Tiamat','Tjasse','Trudd','Urazra','Varg','Vasaghati','Venkelvore','Verex','Vineshvakhi','Vritra','Wadjet','Walkena','White_Feather','Yahaiya','Ydersius','Yuelral','Zagresh','Zarongel','Zogmugot','Zursvaater','Zyphus','Ancestral_Spirits','Archdevil','Asura_rana','Harbinger','Demon_lord','Eldest','Elemental_lord','Empyreal_Lord','Four_Horsemen','Great_Old_One','Infernal_Duke','Iron_God','Kyton_demagogue','Malebranche','Manasaputra_kumara','Oni_daimyo','Orc_cults','Primal_inevitable','Protean_lord','Psychopomp_Usher','Qlippoth_lord','Rakshasa_immortal','Sahkil_tormentor','Whore_queen') ) OR (page_namespace = '11' AND page_title = 'Deities_navbox')
Function: LinkHolderArray::replaceInternal
Error: 1317 Query execution was interrupted (localhost)

Backtrace:
#0 /var/www/wiki/includes/db/Database.php(1123): DatabaseBase->reportQueryError(string, integer, string, string, boolean)
#1 /var/www/wiki/includes/db/Database.php(1590): DatabaseBase->query(string, string)
#2 /var/www/wiki/includes/parser/LinkHolderArray.php(339): DatabaseBase->select(string, array, string, string)
#3 /var/www/wiki/includes/parser/LinkHolderArray.php(261): LinkHolderArray->replaceInternal(string)
#4 /var/www/wiki/includes/parser/Parser.php(5056): LinkHolderArray->replace(string)
#5 /var/www/wiki/includes/parser/Parser.php(413): Parser->replaceLinkHolders(string)
#6 /var/www/wiki/includes/content/WikitextContent.php(322): Parser->parse(string, Title, ParserOptions, boolean, boolean, integer)
#7 /var/www/wiki/includes/WikiPage.php(3614): WikitextContent->getParserOutput(Title, integer, ParserOptions)
#8 /var/www/wiki/includes/poolcounter/PoolCounterWork.php(112): PoolWorkArticleView->doWork()
#9 /var/www/wiki/includes/Article.php(710): PoolCounterWork->execute()
#10 /var/www/wiki/includes/actions/ViewAction.php(44): Article->view()
#11 /var/www/wiki/includes/Wiki.php(487): ViewAction->show()
#12 /var/www/wiki/includes/Wiki.php(285): MediaWiki->performAction(Article, Title)
#13 /var/www/wiki/includes/Wiki.php(647): MediaWiki->performRequest()
#14 /var/www/wiki/includes/Wiki.php(506): MediaWiki->main()
#15 /var/www/wiki/index.php(46): MediaWiki->run()
#16 {main}

Exception caught inside exception handler: [144a57b8] /wiki/Iomedae Exception from line 967 of /var/www/wiki/includes/db/Database.php: DB connection error: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) (localhost)
Backtrace:
#0 /var/www/wiki/includes/db/DatabaseMysqlBase.php(103): DatabaseBase->reportConnectionError(string)
#1 /var/www/wiki/includes/db/DatabaseMysqlBase.php(574): DatabaseMysqlBase->open(string, string, string, string)
#2 /var/www/wiki/includes/db/Database.php(1103): DatabaseMysqlBase->ping()
#3 /var/www/wiki/includes/db/Database.php(1590): DatabaseBase->query(string, string)
#4 /var/www/wiki/includes/cache/LinkBatch.php(201): DatabaseBase->select(string, array, string, string)
#5 /var/www/wiki/includes/cache/LinkBatch.php(133): LinkBatch->doQuery()
#6 /var/www/wiki/includes/cache/LinkBatch.php(121): LinkBatch->executeInto(LinkCache)
#7 /var/www/wiki/includes/Skin.php(303): LinkBatch->execute()
#8 /var/www/wiki/includes/Skin.php(218): Skin->preloadExistence()
#9 /var/www/wiki/skins/Refreshed/Refreshed.skin.php(20): Skin->initPage(OutputPage)
#10 /var/www/wiki/includes/SkinTemplate.php(258): SkinRefreshed->initPage(OutputPage)
#11 /var/www/wiki/includes/OutputPage.php(2134): SkinTemplate->outputPage()
#12 /var/www/wiki/includes/exception/MWException.php(219): OutputPage->output()
#13 /var/www/wiki/includes/exception/MWException.php(260): MWException->reportHTML()
#14 /var/www/wiki/includes/exception/MWExceptionHandler.php(44): MWException->report()
#15 /var/www/wiki/includes/exception/MWExceptionHandler.php(139): MWExceptionHandler::report(DBQueryError)
#16 /var/www/wiki/includes/Wiki.php(513): MWExceptionHandler::handle(DBQueryError)
#17 /var/www/wiki/index.php(46): MediaWiki->run()
#18 {main}