Ubuntu Server Guide
Download 1.23 Mb. Pdf ko'rish
|
ubuntu-server-guide (1)
MySQL Tuner
MySQL Tuner connects to a running MySQL instance and offer configuration suggestions to optimize the database for your workload. The longer the server has been running, the better the advice mysqltuner can provide. In a production environment, consider waiting for at least 24 hours before running the tool. You can install mysqltuner from the Ubuntu repositories: sudo apt i n s t a l l m ys q lt une r Then once its been installed, run: mysqltu ner and wait for its final report. The top section provides general information about the database server, and the bottom section provides tuning suggestions to alter in your my.cnf. Most of these can be altered live on the server without restarting; look through the official MySQL documentation (link in Resources section) for the relevant variables to change in production. The following example is part of a report from a production database showing potential benefits from increasing the query cache: −−−−−−−− Recommendations −−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−− Ge n e ra l recommendations : Run OPTIMIZE TABLE t o defragment t a b l e s f o r b e t t e r p e r f o r m a n c e I n c r e a s e t a b l e _ c a c h e g r a d u a l l y t o a v o i d f i l e d e s c r i p t o r l i m i t s V a r i a b l e s t o a d j u s t : k e y _ b u f f e r _ s i z e (> 1 . 4G) q u er y _ c a c h e _ s i z e (> 32M) t a b l e _ c a c h e (> 6 4 ) i n n o d b _ b u f f e r _ p o o l _ s i z e (>= 22G) It goes without saying that performance optimization strategies vary from application to application. So for example, what works best for Wordpress might not be the best for Drupal or Joomla. Performance can be dependent on the types of queries, use of indexes, how efficient the database design is and so on. You may find it useful to spend some time searching for database tuning tips based on what applications you’re using. Once you’ve reached the point of diminishing returns from database configuration adjustments, look to the application itself for improvements, or invest in more powerful hardware and/or scaling up the database environment. Download 1.23 Mb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling