Skip to content
This repository was archived by the owner on Sep 25, 2023. It is now read-only.
This repository was archived by the owner on Sep 25, 2023. It is now read-only.

MySQL connection issue #1185

@KingStar1001

Description

@KingStar1001

I have deployed Pomelo server on AWS EC2 (Ubuntu) instance.

When I run the server, it works correctly.
But after several hours later, server crashed with mysql issue.

[2023-04-26 02:01:26.771] [ERROR] console - Caught exception: Error: Packets out of order. Got: 0 Expected: 14
at Parser._tryReadPacketHeader (/var/cw_server/game-server/node_modules/mysql/lib/protocol/Parser.js:470:15)
at Parser.write (/var/cw_server/game-server/node_modules/mysql/lib/protocol/Parser.js:33:29)
at Protocol.write (/var/cw_server/game-server/node_modules/mysql/lib/protocol/Protocol.js:38:16)
at Socket. (/var/cw_server/game-server/node_modules/mysql/lib/Connection.js:88:28)
at Socket. (/var/cw_server/game-server/node_modules/mysql/lib/Connection.js:526:10)
at Socket.emit (events.js:400:28)
at addChunk (internal/streams/readable.js:293:12)
at readableAddChunk (internal/streams/readable.js:267:9)
at Socket.Readable.push (internal/streams/readable.js:206:10)
at TCP.onStreamRead (internal/stream_base_commons.js:188:23)

*Note*: I used the same code as lordofpomelo for MySQL.

So, I created a simple socket server that uses the same database and it works correctly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions