walkor / walkor/workerman

MySQL server has gone away when in daemon mode?

Open
#700 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
11.6k
Forks
2.2k
Avg merge
11h 30m
Merged PRs (30d)
3

Description

When I run my server normally with "php80 server/server.php start" it works fine. I have a database call in my onMessage() function:

```
$wsWorker->onMessage = function ($connection, $data)
{
global $pdoConnection;
$sqlCallCheckResult = $pdoConnection -> prepare("select...
```

This is fine and work sell. As soon as I run it in daemon mode with "php80 server/server.php -d start" it server repeatedly fails with:
"MySQL server has gone away in...". See attached full error. Does anyone know why? I do nothing different at all except add -d for daemon mode.

[error.txt](https://github.com/walkor/workerman/files/7770060/error.txt)

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.