SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111)

Typecho_Db_Adapter_Exception: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111) in /usr/local/hkxq/var/Typecho/Db/Adapter/Pdo.php:60 Stack trace: #0 /usr/local/hkxq/var/Typecho/Db.php(199): Typecho_Db_Adapter_Pdo->connect(Object(Typecho_Config)) #1 /usr/local/hkxq/var/Typecho/Db.php(350): Typecho_Db->selectDb(1) #2 /usr/local/hkxq/var/Typecho/Db.php(384): Typecho_Db->query(Object(Typecho_Db_Query), 1) #3 /usr/local/hkxq/var/Widget/Options.php(358): Typecho_Db->fetchAll(Object(Typecho_Db_Query), Array) #4 /usr/local/hkxq/var/Typecho/Widget.php(221): Widget_Options->execute() #5 /usr/local/hkxq/var/Widget/Init.php(27): Typecho_Widget::widget('Widget_Options') #6 /usr/local/hkxq/var/Typecho/Widget.php(221): Widget_Init->execute() #7 /usr/local/hkxq/index.php(19): Typecho_Widget::widget('Widget_Init') #8 {main}