Database tuning Tid Bit
All:
I wanted you all to have this its just a tid bit of a Guide I am working on for MariaDB and or Mysql. I wanted to tell you about a cool tuning script called tuning-primer.sh. Should work on CentOS 7 if you have other disto may need to install bc with other package manager.
#requires bc to be installed yum install bc -y #install and correct permissions cd /usr/bin wget https://raw.githubusercontent.com/mattiabasone/tuning-primer/master/tuning-primer.sh -O tuning-primer.sh chmod +x tuning-primer.sh #make a backup of your current config cp /etc/my.cnf /etc/my.cnf.bak #run script for output on centos backend sh tuning-primer.sh
Begaining output looks like this:
# sh tuning-primer.sh
-- MYSQL PERFORMANCE TUNING PRIMER --
- By: Matthew Montgomery -
MySQL Version 10.4.6-MariaDB x86_64
Uptime = 0 days 13 hrs 59 min 21 sec
Avg. qps = 0
Total Questions = 44479
Threads Connected = 1
Warning: Server has not been running for at least 48hrs.
It may not be safe to use these recommendations
Once you have it installed and run it will tell you areas to improve in the config file (my.cnf). Also your Mysql server needs to be up for at least 2 days between changes.
PS I didn't write this script.
Hope this helps.
0 Comments
Recommended Comments
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now