This howto is tested on:

  • Debian 10.0 Buster

Requirements

This howto requires:

Environment setup

Detect if sudo is available (“command” is used if not):

cmdProxy='command'
command type -f 'sudo' &>'/dev/null' && cmdProxy='sudo'

Installation

Install the software:

${cmdProxy} apt install 'mysqltuner'

Performance schema

Enable the database server performance schema:

${cmdProxy} tee '/etc/mysql/conf.d/performance-schema.cnf' <<< "[mysqld]
performance_schema = on"

Reload the database server configuration:

${cmdProxy} systemctl 'restart' 'mariadb'

Usage

Wait at least 24h after starting the MariaDB (MySQL) server to use this tool. This allow for the accumulated usage data to be pertinent.

Run the software:

${cmdProxy} mysqltuner

The tool check the MariaDB (MySQL) server settings and provide tips on possible performance enhancements.

Thanks


0 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.