:(

Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

错误位置

FILE: /var/www/www/Api/ThinkPHP/Lib/Core/Db.class.php  LINE: 162

TRACE

[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/Db.class.php (162) DbMysql->connect()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Driver/Db/DbMysql.class.php (94) Db->initConnect()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Driver/Db/DbMysql.class.php (213) DbMysql->query(SHOW COLUMNS FROM `api_app`)
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/Model.class.php (135) DbMysql->getFields(api_app)
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/Model.class.php (123) Model->flush()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/Model.class.php (1174) Model->_checkTableInfo()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/Model.class.php (98) Model->db(0, )
[19-04-26 07:46:04] /var/www/www/Api/home/Lib/Model/AppModel.class.php (7) Model->__construct()
[19-04-26 07:46:04] /var/www/www/Api/home/Lib/Action/IndexAction.class.php (13) AppModel->__construct()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Common/common.php (321) IndexAction->__construct()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/App.class.php (103) A(Index)
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/App.class.php (207) App::exec()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Lib/Core/Think.class.php (39) App::run()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/Common/runtime.php (242) Think::start()
[19-04-26 07:46:04] /var/www/www/Api/ThinkPHP/ThinkPHP.php (30) require(/var/www/www/Api/ThinkPHP/Common/runtime.php)
[19-04-26 07:46:04] /var/www/www/Api/index.php (6) require(/var/www/www/Api/ThinkPHP/ThinkPHP.php)