MYSQL / AURORA Database Troubleshooting

Here is a look at some of the common queries that will be useful when troubleshooting AURORA database.

Number of Connections by Host
SELECT SUBSTRING(HOST, 1, 10) , DB,USER , COUNT(*) AS Count
    FROM information_schema.processlist 
    group by SUBSTRING(HOST, 0, 10) , DB,USER 
    ORDER BY Count desc ;
    -- '10.10.50.22', 'Portal', 'webguest-dev', '46'
Aurora Max Connections
 select AURORA_VERSION();
        select * from mysql.slow_log 
        where sql_text not like '%LOAD DATA%'
        order by query_time desc
        limit 1000 ;
         
        select count(*) from mysql.general_log 
        where user_host not like 'rdsadmin%'
        and user_host not like '[rdsadmin]%'
        and event_time > '2017-06-15 18:51:14';
         
        select current_timestamp();
         
        desc mysql.general_log  ;
         
        select @@MAX_CONNECTIONS
        -- '4000'
         
        select *  from mysql.general_log 
        where command_type like '%Connect%';
         
        select *  from mysql.general_log_backup 
        where command_type like '%Connect%' ;
         
        SHOW GLOBAL STATUS LIKE '%Connection_errors%';
         
        SHOW STATUS WHERE `variable_name` = 'Threads_connected';

Share this:

CloudIQ is a leading Cloud Consulting and Solutions firm that helps businesses solve today’s problems and plan the enterprise of tomorrow by integrating intelligent cloud solutions. We help you leverage the technologies that make your people more productive, your infrastructure more intelligent, and your business more profitable. 

US

626 120th Ave NE, B102, Bellevue,

WA, 98005.

 sales@cloudiqtech.com

INDIA

Chennai One IT SEZ,

Module No:5-C, Phase ll, 2nd Floor, North Block, Pallavaram-Thoraipakkam 200 ft road, Thoraipakkam, Chennai – 600097


© 2019 CloudIQ Technologies. All rights reserved.