<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>PlanetMysql.ru - информация о СУБД MySQL &#187; performance analysis</title>
	<atom:link href="http://planetmysql.ru/category/performance-analysis/feed/" rel="self" type="application/rss+xml" />
	<link>http://planetmysql.ru</link>
	<description>Блог о самой популярной СУБД MySQL</description>
	<lastBuildDate>Fri, 25 May 2012 06:11:10 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>What do MySQL Consultants do?</title>
		<link>http://ronaldbradford.com/blog/what-do-mysql-consultants-do-2010-07-08/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=what-do-mysql-consultants-do</link>
		<comments>http://ronaldbradford.com/blog/what-do-mysql-consultants-do-2010-07-08/#comments</comments>
		<pubDate>Thu, 08 Jul 2010 16:18:41 +0000</pubDate>
		<dc:creator>Ronald Bradford</dc:creator>
				<category><![CDATA[Databases]]></category>
		<category><![CDATA[monitoring]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[performance analysis]]></category>
		<category><![CDATA[Professional]]></category>
		<category><![CDATA[tuning]]></category>

		<guid isPermaLink="false">http://ronaldbradford.com/blog/?p=3029</guid>
		<description><![CDATA[One role of a MySQL consultant is to review an existing production system. Sometimes you have sufficient time and access, and other times you don&#8217;t.  If I am given a limited time here is a general list of things I look at.

Review Server architecture, OS, Memory, Disks (including raid and partition type), Network etc
Review server load and identify physical bottleneck
Look at all running processes
Look specifically at MySQL processes
Review MySQL Error Log
Determine MySQL version
Look at MySQL configuration (e.g. /etc/my.cnf)
Look at running MySQL Variables
Look at running MySQL status (x n times)
Look at running MySQL INNODB status (x n times) if used
Get Database and Schema Sizes
Get Database Schema
Review Slow Query Log
Capture query sample via SHOW FULL PROCESSLIST (locked and long running)
Analyze Binary Log file
Capture all running SQL

Here are some of the commands I would run.
2. Review server load and identify physical bottleneck

$ vmstat 5 720 &#62; vmstat.`date +%y%m%d.%H%M%S`.txt

4. Look at MySQL processes

$ ps -eopid,fname,rss,vsz,user,command &#124; grep -e "RSS" -e "mysql"
  PID COMMAND    RSS    VSZ USER     COMMAND
 5463 grep       764   5204 ronald   grep -e RSS -e mysql
13894 mysqld_s   596   3936 root     /bin/sh /usr/bin/mysqld_safe
13933 mysqld   4787812 5127208 mysql /usr/sbin/mysqld --basedir=/usr --datadir=/vol/mysql/mysqldata --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-external-locking --port=3306 --socket=/var/run/mysqld/mysqld.sock
13934 logger     608   3840 root     logger -p daemon.err -t mysqld_safe -i -t mysqld

$ ps -eopid,fname,rss,vsz,user,command &#124; grep " mysqld " &#124; grep -v grep &#124; awk '{print $3,$4}'
4787820 5127208

5. Review MySQL Error Log
The error log can be found in various different places based on the operating system and configuration. It is important to find the right log, the SHOW GLOBAL VARIABLES LIKE &#8216;log_error&#8217; will determine the location.
This is generally overlooked, however this can quickly identify some underlying problems with a MySQL environment.
7. Look at MySQL configuration

$ [ -f /etc/my.cnf ] &#38;&#38;  cat /etc/my.cnf
$ [ -f /etc/mysql/my.cnf ] &#38;&#38;  cat /etc/mysql/my.cnf
$ find / -name  "*my*cnf" 2&#62;/dev/null

8. Look at running MySQL Variables

$ mysqladmin -uroot -p variables

9. Look at running MySQL status (x n times)

$ mysqladmin -uroot -p extended-status

It is important to run this several times at regular intervals, say 60 seconds, 60 minutes, or 24 hours.
I also have dedicated scripts that can perform this. Check out Log MySQL Stats.
11.  Get Database and Schema Sizes
Check out my scripts on my MySQL DBA page
14. Capture Locked statements
Check out my script for Capturing MySQL sessions.
15. Analyze Binary Log file
Check out my post on using mk-query-digest.
16. Capture all SQL
Check out my post on DML Stats per table
Moving forward
Of course the commands I run exceeds this initial list, and gathering this information is only ]]></description>
			<content:encoded><![CDATA[<p>One role of a MySQL consultant is to review an existing production system. Sometimes you have sufficient time and access, and other times you don&#8217;t.  If I am given a limited time here is a general list of things I look at.</p>
<ol>
<li>Review Server architecture, OS, Memory, Disks (including raid and partition type), Network etc</li>
<li>Review server load and identify physical bottleneck</li>
<li>Look at all running processes</li>
<li>Look specifically at MySQL processes</li>
<li>Review MySQL Error Log</li>
<li>Determine MySQL version</li>
<li>Look at MySQL configuration (e.g. /etc/my.cnf)</li>
<li>Look at running MySQL Variables</li>
<li>Look at running MySQL status (x n times)</li>
<li>Look at running MySQL INNODB status (x n times) if used</li>
<li>Get Database and Schema Sizes</li>
<li>Get Database Schema</li>
<li>Review Slow Query Log</li>
<li>Capture query sample via SHOW FULL PROCESSLIST (locked and long running)</li>
<li>Analyze Binary Log file</li>
<li>Capture all running SQL</li>
</ol>
<p>Here are some of the commands I would run.</p>
<h3>2. Review server load and identify physical bottleneck</h3>
<pre>
$ vmstat 5 720 > vmstat.`date +%y%m%d.%H%M%S`.txt
</pre>
<h3>4. Look at MySQL processes</h3>
<pre>
$ ps -eopid,fname,rss,vsz,user,command | grep -e "RSS" -e "mysql"
  PID COMMAND    RSS    VSZ USER     COMMAND
 5463 grep       764   5204 ronald   grep -e RSS -e mysql
13894 mysqld_s   596   3936 root     /bin/sh /usr/bin/mysqld_safe
13933 mysqld   4787812 5127208 mysql /usr/sbin/mysqld --basedir=/usr --datadir=/vol/mysql/mysqldata --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-external-locking --port=3306 --socket=/var/run/mysqld/mysqld.sock
13934 logger     608   3840 root     logger -p daemon.err -t mysqld_safe -i -t mysqld

$ ps -eopid,fname,rss,vsz,user,command | grep " mysqld " | grep -v grep | awk '{print $3,$4}'
4787820 5127208
</pre>
<h3>5. Review MySQL Error Log</h3>
<p>The error log can be found in various different places based on the operating system and configuration. It is important to find the right log, the SHOW GLOBAL VARIABLES LIKE &#8216;log_error&#8217; will determine the location.</p>
<p>This is generally overlooked, however this can quickly identify some underlying problems with a MySQL environment.</p>
<h3>7. Look at MySQL configuration</h3>
<pre>
$ [ -f /etc/my.cnf ] &#038;&#038;  cat /etc/my.cnf
$ [ -f /etc/mysql/my.cnf ] &#038;&#038;  cat /etc/mysql/my.cnf
$ find / -name  "*my*cnf" 2>/dev/null
</pre>
<h3>8. Look at running MySQL Variables</h3>
<pre>
$ mysqladmin -uroot -p variables
</pre>
<h3>9. Look at running MySQL status (x n times)</h3>
<pre>
$ mysqladmin -uroot -p extended-status
</pre>
<p>It is important to run this several times at regular intervals, say 60 seconds, 60 minutes, or 24 hours.</p>
<p>I also have dedicated scripts that can perform this. Check out <a href="http://ronaldbradford.com/mysql-dba/#log-stats">Log MySQL Stats</a>.</p>
<h3>11.  Get Database and Schema Sizes</h3>
<p>Check out my scripts on my <a href="http://ronaldbradford.com/mysql-dba/">MySQL DBA page</a></p>
<h3>14. Capture Locked statements</h3>
<p>Check out my script for <a href="http://ronaldbradford.com/mysql-dba/#mysql-sessions">Capturing MySQL sessions</a>.</p>
<h3>15. Analyze Binary Log file</h3>
<p>Check out my post on using <a href="http://ronaldbradford.com/blog/take-a-look-at-mk-query-digest-2009-10-08/">mk-query-digest</a>.</p>
<h3>16. Capture all SQL</h3>
<p>Check out my post on <a href="http://ronaldbradford.com/blog/mysql-dml-stats-per-table-2009-09-09/">DML Stats per table</a></p>
<h3>Moving forward</h3>
<p>Of course the commands I run exceeds this initial list, and gathering this information is only </p><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=25240&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=25240&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2010/07/08/what-do-mysql-consultants-do/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL related bookmark collection</title>
		<link>http://mysqlpreacher.com/wordpress/2009/09/mysql-related-bookmark-collection/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=mysql-related-bookmark-collection</link>
		<comments>http://mysqlpreacher.com/wordpress/2009/09/mysql-related-bookmark-collection/#comments</comments>
		<pubDate>Thu, 17 Sep 2009 12:40:27 +0000</pubDate>
		<dc:creator>Darren Cassar</dc:creator>
				<category><![CDATA[administration]]></category>
		<category><![CDATA[Beginner]]></category>
		<category><![CDATA[benchmarking]]></category>
		<category><![CDATA[Cluster]]></category>
		<category><![CDATA[collection]]></category>
		<category><![CDATA[configuration]]></category>
		<category><![CDATA[Databases]]></category>
		<category><![CDATA[HA]]></category>
		<category><![CDATA[Information]]></category>
		<category><![CDATA[InnoDB]]></category>
		<category><![CDATA[monitoring]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[performance analysis]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://mysqlpreacher.com/wordpress/?p=293</guid>
		<description><![CDATA[I am publishing my MySQL related bookmark collection http://www.mysqlpreacher.com/bookmarks/.
Feel free to send me links you think might be good to add in order to help others.
Remember, SHARING IS CARING!!! …. we get so much for free, why shouldn’t we give some back?
Cheers,
Darren]]></description>
			<content:encoded><![CDATA[I am publishing my MySQL related bookmark collection http://www.mysqlpreacher.com/bookmarks/.
Feel free to send me links you think might be good to add in order to help others.
Remember, SHARING IS CARING!!! …. we get so much for free, why shouldn’t we give some back?
Cheers,
Darren<br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=21211&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=21211&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2009/09/17/mysql-related-bookmark-collection/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

