Filesort Probes

Nasza ocena:

5
Wyświetleń: 679
Komentarze: 0
Notatek.pl

Pobierz ten dokument za darmo

Podgląd dokumentu
Filesort Probes - strona 1

Fragment notatki:

Filesort Probes
The filesort probes are triggered whenever a filesort operation is applied to a table. For more
information on filesort and the conditions under which it occurs, see Section 8.13.13, “ORDER BY
Optimization”.
filesort-start(database, table)
filesort-done(status, rows)
• filesort-start: Triggered when the filesort operation starts on a table. The two arguments to the
probe, database and table, will identify the table being sorted.
• filesort-done: Triggered when the filesort operation completes. Two arguments are supplied, the
status (0 for success, 1 for failure), and the number of rows sorted during the filesort process.
An example of this is in the following script, which tracks the duration of the filesort process in addition
to the duration of the main query:
#!/usr/sbin/dtrace -s
#pragma D option quiet
dtrace:::BEGIN
{
printf("%-2s %-10s %-10s %9s %18s %-s \n",
"St", "Who", "DB", "ConnID", "Dur microsec", "Query");
}
mysql*:::query-start
{
self-query = copyinstr(arg0);
self-who = strjoin(copyinstr(arg3),strjoin("@",copyinstr(arg4)));
... zobacz całą notatkę



Komentarze użytkowników (0)

Zaloguj się, aby dodać komentarz