PomeloFoundation / Pomelo.EntityFrameworkCore.MySql

Entity Framework Core provider for MySQL and MariaDB built on top of MySqlConnector
MIT License
2.68k stars 382 forks source link

Unauthenticated User - Waiting in connection_control plugin #672

Closed ghost closed 6 years ago

ghost commented 6 years ago

The issue

I have a netcore web api project with pomelo connector and ef core, after a period of time, no matter if i'm doing a lot of request or just one, i get on mysql engine a lot of unauthenticated users on process list with the state "waiting in connection_control plugin", this list is growing up until reach the max connection pool size and then engine is dead, and obviously no one can connect or use it, i need to restart the engine to solve the problem.

The most rare things is i'm not getting any exceptions, just after a period of time i receive on webapi a badgateway error 502, i think this error is a refuse connection from mysql server because i'm unauthenticated o reach the max connection.

This is the mysql process list i get.

image

This is the configuration of my web api, i try with dbcontextpool and without it (dbcontext) and both produce the same behavior.

startup

This is the log i use (nlog) logging all from Microsoft.EntityFrameworkCore.* and when i get blocked i just get this on the log, no queries are executed.

log

Further technical details

MySQL version: 5.7.17 Operating system: Windows Server 2012 R2 Pomelo.EntityFrameworkCore.MySql version: 2.1.1

Other details about my project setup: Microsoft.EntityFrameworkCore version: 2.1.2


Hope u can help me! Thanks!

mguinness commented 6 years ago

Take a look at Unauthenticated User in MySQL?

Closing issue, if you need further assistance try Stack Overflow.