Skip to content

Instantly share code, notes, and snippets.

@heat
Created April 25, 2018 20:15
Show Gist options
  • Save heat/28d13b56fae0c575ca0d19434fc75e7d to your computer and use it in GitHub Desktop.
Save heat/28d13b56fae0c575ca0d19434fc75e7d to your computer and use it in GitHub Desktop.
-log
[OK] Operating on 64-bit architecture
-------- Log file Recommendations ------------------------------------------------------------------
[--] Log file: /var/lib/mysql/mariadbeus05.err(0B)
[!!] Log file /var/lib/mysql/mariadbeus05.err doesn't exist
[!!] Log file /var/lib/mysql/mariadbeus05.err isn't readable.
-------- Storage Engine Statistics -----------------------------------------------------------------
[--] Status: +Aria +CSV +InnoDB +MEMORY +MRG_MyISAM +MyISAM +PERFORMANCE_SCHEMA +SEQUENCE
[--] Data in InnoDB tables: 3G (Tables: 318)
[OK] Total fragmented tables: 0
-------- Security Recommendations ------------------------------------------------------------------
[OK] There are no anonymous accounts for any database users
[OK] All database users have passwords assigned
[!!] User '6czs72zrokffrojqfnkjca@%' hasn't specific host restriction.
[!!] User 'adamohjwgpbchohaify7dg@%' hasn't specific host restriction.
[!!] User 'ebajimemsjagjogiivbrbj@%' hasn't specific host restriction.
[!!] User 'icarat7iytkwfuweovwci2@%' hasn't specific host restriction.
[!!] User 'iciveseruhemixom@%' hasn't specific host restriction.
[!!] User 'ivejot737j2hyoneoy9udi@%' hasn't specific host restriction.
[!!] User 'iwabuvjt6wmbxomoahwdax@%' hasn't specific host restriction.
[!!] User 'iwugir2rbpcqcocuamihty@%' hasn't specific host restriction.
[!!] User 'mmgbxdtg5rch5nf7evz66v@%' hasn't specific host restriction.
[!!] User 'sysbet@%' hasn't specific host restriction.
[!!] User 'ubofecddzp2qzayaic33jz@%' hasn't specific host restriction.
[!!] User 'ukagegr9pucqyumaurr9zv@%' hasn't specific host restriction.
[!!] User 'upocawti4m7qnuwaebm74z@%' hasn't specific host restriction.
[!!] User 'uwubatbziyxvyupeom2rbd@%' hasn't specific host restriction.
[!!] There is no basic password file list!
-------- CVE Security Recommendations --------------------------------------------------------------
[--] Skipped due to --cvefile option undefined
-------- Performance Metrics -----------------------------------------------------------------------
[--] Up for: 2d 1h 22m 10s (10M q [59.173 qps], 48K conn, TX: 38G, RX: 6G)
[--] Reads / Writes: 96% / 4%
[--] Binary logging is enabled (GTID MODE: OFF)
[--] Physical Memory : 6.8G
[--] Max MySQL memory : 8.0G
[--] Other process memory: 306.7M
[--] Total buffers: 616.0M global + 7.5M per thread (1000 max threads)
[--] P_S Max memory usage: 0B
[--] Galera GCache Max memory usage: 0B
[OK] Maximum reached memory usage: 2.3G (34.03% of installed RAM)
[!!] Maximum possible memory usage: 8.0G (117.32% of installed RAM)
[!!] Overall possible memory usage with other process exceeded memory
[OK] Slow queries: 0% (0/10M)
[OK] Highest usage of available connections: 23% (232/1000)
[!!] Aborted connections: 12.41% (5984/48238)
[!!] name resolution is active : a reverse name resolution is made for each new connection and can reduce performance
[!!] Query cache may be disabled by default due to mutex contention.
[OK] Query cache efficiency: 21.8% (2M cached / 13M selects)
[OK] Query cache prunes per day: 0
[OK] Sorts requiring temporary tables: 0% (4 temp sorts / 1M sorts)
[!!] Joins performed without indexes: 69364
[OK] Temporary tables created on disk: 0% (500 on disk / 1M total)
[OK] Thread cache hit rate: 99% (290 created / 48K connections)
[!!] Table cache hit rate: 2% (400 open / 17K opened)
[OK] Open file limit used: 0% (60/16K)
[OK] Table locks acquired immediately: 100% (2K immediate / 2K locks)
[OK] Binlog cache memory access: 96.45% (88501 Memory / 91756 Total)
-------- Performance schema ------------------------------------------------------------------------
[--] Performance schema is disabled.
[--] Memory used by P_S: 0B
[--] Sys schema isn't installed.
-------- ThreadPool Metrics ------------------------------------------------------------------------
[--] ThreadPool stat is enabled.
[--] Thread Pool Size: 2 thread(s).
[--] Using default value is good enough for your version (10.2.14-MariaDB-10.2.14+maria~xenial-log)
-------- MyISAM Metrics ----------------------------------------------------------------------------
[!!] Key buffer used: 18.2% (24M used / 134M cache)
[OK] Key buffer size / total MyISAM indexes: 128.0M/128.0K
[OK] Read Key buffer hit rate: 98.2% (7K cached / 134 reads)
[OK] Write Key buffer hit rate: 100.0% (304 cached / 304 writes)
-------- InnoDB Metrics ----------------------------------------------------------------------------
[--] InnoDB is enabled.
[--] InnoDB Thread Concurrency: 0
[OK] InnoDB File per table is activated
[!!] InnoDB buffer pool / data size: 256.0M/4.0G
[!!] Ratio InnoDB log file size / InnoDB Buffer pool size (37.5 %): 48.0M * 2/256.0M should be equal 25%
[OK] InnoDB buffer pool instances: 1
[--] Number of InnoDB Buffer Pool Chunk : 2 for 1 Buffer Pool Instance(s)
[OK] Innodb_buffer_pool_size aligned with Innodb_buffer_pool_chunk_size & Innodb_buffer_pool_instances
[OK] InnoDB Read buffer efficiency: 99.67% (18120901257 hits/ 18180325029 total)
[OK] InnoDB Write log efficiency: 98.83% (11859961 hits/ 12000540 total)
[OK] InnoDB log waits: 0.00% (0 waits / 140579 writes)
-------- AriaDB Metrics ----------------------------------------------------------------------------
[--] AriaDB is enabled.
[OK] Aria pagecache size / total Aria indexes: 128.0M/1B
[OK] Aria pagecache hit rate: 96.6% (14K cached / 500 reads)
-------- TokuDB Metrics ----------------------------------------------------------------------------
[--] TokuDB is disabled.
-------- XtraDB Metrics ----------------------------------------------------------------------------
[--] XtraDB is disabled.
-------- RocksDB Metrics ---------------------------------------------------------------------------
[--] RocksDB is disabled.
-------- Spider Metrics ----------------------------------------------------------------------------
[--] Spider is disabled.
-------- Connect Metrics ---------------------------------------------------------------------------
[--] Connect is disabled.
-------- Galera Metrics ----------------------------------------------------------------------------
[--] Galera is disabled.
-------- Replication Metrics -----------------------------------------------------------------------
[--] Galera Synchronous replication: NO
[--] No replication slave(s) for this server.
[--] Binlog format: MIXED
[--] XA support enabled: ON
[--] Semi synchronous replication Master: Not Activated
[--] Semi synchronous replication Slave: Not Activated
[--] This is a standalone server
-------- Recommendations ---------------------------------------------------------------------------
General recommendations:
Restrict Host for user@% to user@SpecificDNSorIp
Reduce your overall MySQL memory footprint for system stability
Dedicate this server to your database for highest performance.
Reduce or eliminate unclosed connections and network issues
Configure your accounts with ip or subnets only, then update your configuration with skip-name-resolve=1
Adjust your join queries to always utilize indexes
Increase table_open_cache gradually to avoid file descriptor limits
Read this before increasing table_open_cache over 64: http://bit.ly/1mi7c4C
This is MyISAM only table_cache scalability problem, InnoDB not affected.
See more details here: https://bugs.mysql.com/bug.php?id=49177
This bug already fixed in MySQL 5.7.9 and newer MySQL versions.
Beware that open_files_limit (16364) variable
should be greater than table_open_cache (400)
Performance should be activated for better diagnostics
Consider installing Sys schema from https://github.com/mysql/mysql-sys
Read this before changing innodb_log_file_size and/or innodb_log_files_in_group: http://bit.ly/2wgkDvS
Variables to adjust:
*** MySQL's maximum memory usage is dangerously high ***
*** Add RAM before increasing MySQL buffer variables ***
query_cache_size (=0)
query_cache_type (=0)
join_buffer_size (> 256.0K, or always use indexes with joins)
table_open_cache (> 400)
performance_schema = ON enable PFS
innodb_buffer_pool_size (>= 3G) if possible.
innodb_log_file_size should be (=32M) if possible, so InnoDB total log files size equals to 25% of buffer pool size.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment