SQL
How to Improve MySql Server Performance with Query Caching

MySQL is the most commonly used Relational Database Management System(RDMS) for the Web. It is open source and has a free community version. It provides all those features that can be provided by an enterprise-level database.
The default settings provided with the MySQL installation may not be so good
for performance, and there are always ways to fine-tune these settings to get an improved performance. Also, remember that your database design plays a big role in performance. A poorly designed database will have an effect on the
overall performance.
In this post, we will discuss how to improve the MySQL database's performance.

Query caching
Query caching is an important performance feature of MySQL. It caches SELECT
queries along with the resulting dataset. When an identical SELECT query occurs,
MySQL fetches the data from memory so that the query is executed faster and
thus reduces the load on the database.
To check whether query cache is enabled on a MySQL server or not, issue the
following command in your MySQL command line:

to use this command in production, open phpmyadmin from cpanel, click on terminal, enter the command bellow and press ctrl+enter (not only enter) to run the command

SHOW VARIABLES LIKE 'have_query_cache';

5c6fdaad1bb78

The preceding command will display the following output:
The previous result set shows that query cache is enabled. If query cache is disabled,

the value will be NO .

To enable query caching, open up the my.cnf file and add the following lines. If
these lines are there and are commented, just uncomment them:

query_cache_type = 1
query_cache_size = 128MB
query_cache_limit = 1MB

Save the my.cnf file and restart the MySQL server.

**MySQL** is the most commonly used Relational Database Management System(**RDMS**) for the Web. It is open source and has a free community version. It provides all those features that can be provided by an enterprise-level database. The default settings provided with the MySQL installation may not be so good for performance, and there are always ways to fine-tune these settings to get an improved performance. Also, remember that your database design plays a big role in performance. A poorly designed database will have an effect on the overall performance. In this post, we will discuss how to improve the MySQL database's performance. **Query caching** Query caching is an important performance feature of MySQL. It caches **SELECT** queries along with the resulting dataset. When an identical **SELECT** query occurs, MySQL fetches the data from memory so that the query is executed faster and thus reduces the load on the database. To check whether query cache is enabled on a MySQL server or not, issue the following command in your MySQL command line: _to use this command in production, open phpmyadmin from cpanel, click on terminal, enter the command bellow and press ctrl+enter (not only enter) to run the command_ ```` SHOW VARIABLES LIKE 'have_query_cache'; ```` ![5c6fdaad1bb78](serve/attachment&path=5c6fdaad1bb78) The preceding command will display the following output: The previous result set shows that query cache is enabled. If query cache is disabled, >the value will be NO . To enable query caching, open up the my.cnf file and add the following lines. If these lines are there and are commented, just uncomment them: ```` query_cache_type = 1 query_cache_size = 128MB query_cache_limit = 1MB ```` Save the my.cnf file and restart the MySQL server.
edited Feb 22 at 11:27 am
0

wow, what i have been looking for........thanks man

wow, what i have been looking for........thanks man
0
55
1
2
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft