How can I see and terminate the active sessions on my mariadb?

0

Hi! We have a Mariadb rds (db.m5.xlarge) and lately I've seen that under "Current activity" the amount of sessions goes crazy high which creates a big problem for our app as it starts refusing new connections. When this is happening the CPU Util% remains low. My question is, how can I see and possibly terminate sessions through cli or the console?

Appreciate your help!

  • Closing connections server side is just a paliative solution. I highly suggest you to find which proccess are keeping open connection e fix it.

posta 9 mesi fa376 visualizzazioni
1 Risposta
0

Hello.

The number of sessions can be checked with the following command.

show status like 'Threads_connected';

You can check the process being processed with the following command.

show processlist;

You can erase the process by specifying the process ID with the following command.

kill processId;
profile picture
ESPERTO
con risposta 9 mesi fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande