Skip to content

MySQL server has gone away (Mysql::ClientError::ServerGoneError) #32

@rbur004

Description

@rbur004

I just upgraded from ruby 2.6 to 3.1.2 and from a mySQL 5 DB to MariaDB 10.6.7

I now get this ServerGoneError when I do a query. I was originally connecting via the loopback interface, but for MariaDB, have switched to using the socket.

As a test, I installed the mysql2 gem, and it works fine with the same code. The only downside is that mysql2 doesn't expose the table names, so if I do switch gems, I will need to rewrite multi-table queries and the code that handles them.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions