Outline
1. configuration file description
My-small.cnf
My-medium.cnf
My-large.cnf
My-huge.cnf
My-innodb-heavy-4G.cnf
2. Detailed explanation my-innodb-heavy-4G.cnf
Iii. configuration file Optimization
Note: Environment Description, CentO5.5 x86_64 + MySQL-5.5.32 related software.
Recommended reading:
Details about MySQL Configuration Optimization
1. configuration file description
Mysql-5.5.32 is the last version of Mysql5.5 series, is also the last version of the configuration file, why do you say so, used 5.6 Boyou know, In mysql5.6 has not provided configuration file selection, there is only one default configuration file. Well, we are talking about version 5.5.32 today, so we will not talk about version 5.6 with everyone. Let's talk about it in mysql5.5.32, provides several optional configuration files,
My-small.cnf
My-medium.cnf
My-large.cnf
My-huge.cnf
My-innodb-heavy-4G.cnf
Next let's take a look at pai_^ ......
1. my-small.cnf
12345 |
[root@mysql support-files] # vim my-small.cnf # Example MySQL config file for small systems. # This is for a system with little memory (<= 64M) where MySQL is only used # from time to time and it's important that the mysqld daemon # doesn't use much resources. |
This is a brief introduction to the my-small.cnf configuration file, it shows that this configuration file is used when the memory is less than or equal to 64 m, small database system, the purpose is not to occupy more system resources!
2. my-medium.cnf
12345 |
[root@mysql support-files] # vim my-medium.cnf # Example MySQL config file for medium systems. # This is for a system with little memory (32M - 64M) where MySQL plays # an important part, or systems up to 128M where MySQL is used together with # other programs (such as a web server) |
This configuration file is used by a medium-sized data system, with a size of around MB!
3. my-large.cnf
1234 |
[root@mysql support-files] # vim my-large.cnf # Example MySQL config file for large systems. # This is for a large system with memory = 512M where the system runs mainly # MySQL. |
This configuration file is used by a large database system, with a size of around MB!
4. my-huge.cnf
1234 |
[root@mysql support-files] # vim my-huge.cnf # Example MySQL config file for very large systems. # This is for a large system with memory of 1G-2G where the system runs mainly # MySQL. |
This configuration file is used by a giant database system, and is about 1 GB to 2 GB!
5. my-innodb-heavy-4G.cnf
12345678 |
[root@mysql support-files] # vim my-innodb-heavy-4G.cnf #BEGIN CONFIG INFO #DESCR: 4GB RAM, InnoDB only, ACID, few connections, heavy queries #TYPE: SYSTEM #END CONFIG INFO # This is a MySQL example config file for systems with 4GB of memory # running mostly MySQL using InnoDB only tables and performing complex # queries with few connections. |
This configuration file is mainly used to support 4 GB memory, InnoDB engine, ACID, and other features!
Note: ACID refers to the abbreviation of four basic elements for correct execution of database transactions. Includes: Atomicity, Consistency, Isolation, and Durability )!
6. Summary
From the above description, we can see that the mysql configuration file is basically selected through the memory size. Some bloggers will say that the current server is still 32 GB memory or 64 GB memory, for larger memory, is it a little small if your configuration file only supports 4 GB memory at the maximum? �� after mysql5.6, in order to improve the performance of mysql, after selecting the configuration file, there is only one default configuration file, which contains only some basic configurations. All the setting administrators can set their own settings according to their actual needs, let's talk about it, the most used my-innodb-heavy-4G.cnf configuration file in the enterprise!