Hi all, is there any guidance on how to configure ...
# fleet
j
Hi all, is there any guidance on how to configure the parameters
FLEET_MYSQL_MAX_IDLE_CONNS
and
FLEET_MYSQL_MAX_OPEN_CONNS
? I started to see
Error 1040: Too Many Connections
along with
Authentication Error: Finding Host
so i think that MySQL was dropping an excessive amount of connections coming from the FleetDM. Our configuration was
FLEET_MYSQL_MAX_IDLE_CONNS=50
and Max Open
FLEET_MYSQL_MAX_OPEN_CONNS=400
which i think it was overwhelming the mysql that has a
max_connections
variable of 151. Once i lowered `FLEET_MYSQL_MAX_OPEN_CONNS=100`i stopped seeing the errors. The question is, what is a typical configuration for those parameters when having deployments of several thousands clients? Should we configure
FLEET_MYSQL_MAX_OPEN_CONNS
close to the
max_connections
value in MySQL? And what would be FleetDM's behavior if he needs to check in the database but the max amount of connections is reached? Any guidance is appreciated!
m
Hi Juan, we're digging into this to provide some guidance for you. Thank you for your patience. And let us know if you find anything in the meantime. We would really appreciate it.
j
Thanks Martavis, appreciate any insight
z
The best thing to do is limit the open connections such that between all your Fleet servers you don't exceed the
max_connections
. So
FLEET_MYSQL_MAX_OPEN_CONNS=max_connections/# of Fleet servers
.
🥘 1
j
Thanks !
j
Hi @zwass, in the comment above, when you say to add
FLEET_MYSQL_MAX_OPEN_CONNS=max_connections
, it will automatically read the value stored in the
max_connections
variable of the DB? .... what would be the case where the
FLEET_MYSQL_MAX_OPEN_CONNS
is lower than the connections of the DB?