Ayúdanos a dar forma a GoConqr. ¿Qué deberíamos añadir?

Fichas

Presentation A

Gary Burrows Database Technology Inglés 12 fichas

Fichas del conjunto (12)

  1. 1Triangle trade offcan only have two out of three i.e. performance, cost and scale
  2. 2Performance corner stonesprocessor, memory, network, hard drive
  3. 3IndexingIndexes are created on a per column basis.
    When you create this index, MySQL will build a lookup index where employeeID specific queries can be run quickly.
    Indexes are something extra that you can enable on your MySQL tables to increase performance, but they do have some downsides.
    When you create a new index MySQL builds a separate block of information that needs to be updated every time there are changes made to the table.
    This means that if you are constantly updating, inserting and removing entries in your table this could have a negative impact on performance.
  4. 4ExplainEXPLAIN can provide information that points out the need to add an index. If a table already has indexes, you can use EXPLAIN to find out whether the optimiser is using them. EXPLAIN can tell you whether the rewrites are better for helping the server use the available indexes.
  5. 5Log slow queries1. Start mysql with the --log option:
    2. mysqld –log=log_file_name
    3. or place the following in your my.cnf file:
    4. log = log_file_name
    5. Either one will log all queries to log_file_name. You can also log only slow queries using the --log-slow-queries option instead of --log. By default, queries that take 10 seconds or longer are considered slow, you can change this by setting long_query_time to the number of seconds a query must take to execute before being logged.
  6. 6Use select * with cautionWhen you use select * you're make it impossible to profile, therefore you're not writing clear & straightforward code and you are going against the spirit of the quote. select * is an anti-pattern.
  7. 7DatatypesVarchar
    Char
    Char is faster as it is fixed
  8. 8Vertical & horizontal partitioningVertical & horizontal partitioning
  9. 9Analyse()analyses table and stores the key distribution.
  10. 10Query cache1. If you want to get optimized and speedy response from your MySQL server then you need to add following two configurations directive to your MySQL server:
    query_cache_size=SIZE
    The amount of memory (SIZE) allocated for caching query results. The default value is 0, which disables the query cache.
    query_cache_type=OPTION
    Set the query cache type. Possible options are as follows:
    0 : Don't cache results in or retrieve results from the query cache.
    1 : Cache all query results except for those that begin with SELECT S_NO_CACHE.
    2 : Cache results only for queries that begin with SELECT SQL_CACHE
  11. 11Show Status1. SHOW STATUS provides server status information.
    2. This information also can be obtained using the mysqladmin extended-status command. The LIKE clause, if present, indicates which variable names to match. The WHERE clause can be given to select rows using more general conditions.
    3. This statement does not require any privilege. It requires only the ability to connect to the server.
  12. 12Breakup QueriesTo answer your question directly - there is no benefit. Assuming that you're not hitting any physical limits (like the maximum amount of physical memory your OS supports) and that MySQL is a well written program, then no.

Información

Descripción
Database Technology Fichas sobre Presentation A, creado por Gary Burrows el 15/01/2015.
Creado por
Gary Burrows
Visitas
1
Valoración

Más sobre Database Performance Tuning

Escríbenos

¿Sobre qué es tu mensaje?

¿Qué deberíamos añadir?