当前位置:网站首页>Error while sending STMT_ PREPARE packet. PID=29294

Error while sending STMT_ PREPARE packet. PID=29294

2022-06-25 12:30:00 Chafferer WANG

The error reporting scenario is , Use TP6 Of command command + linux Of nohup Execute continuous script .
The reason for the error : The connection to the database will be disconnected for a long time

The detailed error information is as follows

[think\exception\ErrorException]                    
Error while sending STMT_PREPARE packet. PID=29294  
                                                      


PHP Fatal error:  Uncaught think\exception\ErrorException: Error while sending STMT_CLOSE packet. PID=29294 in /....../vendor/topthink/think-orm/src/db/PDOConnection.php:603
Stack trace:
#0 /....../vendor/topthink/think-orm/src/db/PDOConnection.php(603): think\initializer\Error->appError(2, 'Error while sen...', '/...', 603, Array)
#1 /....../topthink/think-orm/src/db/PDOConnection.php(1576): think\db\PDOConnection->free()
#2 /....../vendor/topthink/think-orm/src/db/Connection.php(345): think\db\PDOConnection->close()
#3 [internal function]: think\db\Connection->__destruct()
#4 {main}
thrown in /....../vendor/topthink/think-orm/src/db/PDOConnection.php on line 603

terms of settlement :

 Modify the database configuration file  database.php , Set to true, Turn on disconnection reconnection 
 //  Whether it needs to be disconnected and reconnected 
'break_reconnect' => true,

If the error message still appears after the above configuration , It is recommended to use try catch Handling exceptions , Prevent program termination due to error reporting

原网站

版权声明
本文为[Chafferer WANG]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202200531230535.html

随机推荐