<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: MySQL Server Variables &#8211; SQL layer or Storage Engine specific.</title>
	<atom:link href="http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/</link>
	<description>Everything about MySQL Performance</description>
	<lastBuildDate>Sat, 21 Nov 2009 05:23:57 -0800</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Rubén Ortiz</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-459920</link>
		<dc:creator>Rubén Ortiz</dc:creator>
		<pubDate>Fri, 30 Jan 2009 10:35:54 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-459920</guid>
		<description>Hi

congratulations by your blog. Is interesting and helpful. I have a question about:

tmp_table_size

you said that &quot;will grow as MEMORY table before it will be converted to on disk MyISAM table&quot;. I read more of tmp_table_size, one of another definition was &quot;Maximum size of in-memory tables&quot;. Someone can give more ideas about what is a in-memory tables? are a temporary tables which are created as .MYI file on MySQL sometimes?

Thanks</description>
		<content:encoded><![CDATA[<p>Hi</p>
<p>congratulations by your blog. Is interesting and helpful. I have a question about:</p>
<p>tmp_table_size</p>
<p>you said that &#8220;will grow as MEMORY table before it will be converted to on disk MyISAM table&#8221;. I read more of tmp_table_size, one of another definition was &#8220;Maximum size of in-memory tables&#8221;. Someone can give more ideas about what is a in-memory tables? are a temporary tables which are created as .MYI file on MySQL sometimes?</p>
<p>Thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: 小议mysql变量及其优化 &#124; OurMySQL &#124; 我们致力于一个MySQL知识的分享网站</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-371885</link>
		<dc:creator>小议mysql变量及其优化 &#124; OurMySQL &#124; 我们致力于一个MySQL知识的分享网站</dc:creator>
		<pubDate>Mon, 03 Nov 2008 08:18:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-371885</guid>
		<description>[...]     以下内容参考 http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-sp... [...]</description>
		<content:encoded><![CDATA[<p>[...]     以下内容参考 <a href="http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-sp.." rel="nofollow">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-sp..</a>. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Web Solutions &#187; MySQL Optimization / Repair Information</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-363564</link>
		<dc:creator>Web Solutions &#187; MySQL Optimization / Repair Information</dc:creator>
		<pubDate>Tue, 21 Oct 2008 08:31:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-363564</guid>
		<description>[...] or Storage Engine specific. List some of the more common variables as well as a brief description Go to article 1 Go to article [...]</description>
		<content:encoded><![CDATA[<p>[...] or Storage Engine specific. List some of the more common variables as well as a brief description Go to article 1 Go to article [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Настройка конфига MySQL</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-336197</link>
		<dc:creator>Настройка конфига MySQL</dc:creator>
		<pubDate>Mon, 28 Jul 2008 13:47:55 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-336197</guid>
		<description>[...] списочек нужных конфигурационных переменных есть тут, при изменении настроек всегда лучше прочитать что же [...]</description>
		<content:encoded><![CDATA[<p>[...] списочек нужных конфигурационных переменных есть тут, при изменении настроек всегда лучше прочитать что же [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: MySQL Optimization / Repair Information &#124; Linux Linux Linux...........</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-323070</link>
		<dc:creator>MySQL Optimization / Repair Information &#124; Linux Linux Linux...........</dc:creator>
		<pubDate>Sat, 05 Jul 2008 07:23:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-323070</guid>
		<description>[...] or Storage Engine specific. List some of the more common variables as well as a brief description Go to article 1 Go to article [...]</description>
		<content:encoded><![CDATA[<p>[...] or Storage Engine specific. List some of the more common variables as well as a brief description Go to article 1 Go to article [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Smartcoder</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-220513</link>
		<dc:creator>Smartcoder</dc:creator>
		<pubDate>Wed, 19 Dec 2007 12:52:44 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-220513</guid>
		<description>Do you want to learn PHP/.NEt/JAVA/ERP/SAP/...... ???

Download EBooks Freely in .pdf,.chm formats and ready for interview questions....

http://hotsoftwareslist.blogspot.com/2007/08/download-ebook.html

Download Opensource CMS Freely

http://phpfunda.blogspot.com/

Project management System in PHP - MySQL - http://phpfunda.blogspot.com/2007/09/project-management-system-in-php-mysql.html

content management systems - http://phpfunda.blogspot.com/2007/08/content-management-systems.html</description>
		<content:encoded><![CDATA[<p>Do you want to learn PHP/.NEt/JAVA/ERP/SAP/&#8230;&#8230; ???</p>
<p>Download EBooks Freely in .pdf,.chm formats and ready for interview questions&#8230;.</p>
<p><a href="http://hotsoftwareslist.blogspot.com/2007/08/download-ebook.html" rel="nofollow">http://hotsoftwareslist.blogspot.com/2007/08/download-ebook.html</a></p>
<p>Download Opensource CMS Freely</p>
<p><a href="http://phpfunda.blogspot.com/" rel="nofollow">http://phpfunda.blogspot.com/</a></p>
<p>Project management System in PHP &#8211; MySQL &#8211; <a href="http://phpfunda.blogspot.com/2007/09/project-management-system-in-php-mysql.html" rel="nofollow">http://phpfunda.blogspot.com/2007/09/project-management-system-in-php-mysql.html</a></p>
<p>content management systems &#8211; <a href="http://phpfunda.blogspot.com/2007/08/content-management-systems.html" rel="nofollow">http://phpfunda.blogspot.com/2007/08/content-management-systems.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vadim</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-19254</link>
		<dc:creator>Vadim</dc:creator>
		<pubDate>Fri, 01 Dec 2006 19:56:42 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-19254</guid>
		<description>Anja,

You do not need to execute mount none /mnt/hugepages -t hugetlbfs 
for mysql

all what you need is 
echo 2000 &gt; /proc/sys/vm/nr_hugepages

or equal command for your Linux (what do you use btw ? )

As I see your command was not executed successfully:

HugePages_Total: 0
HugePages_Free: 0
Hugepagesize: 2048 kB

There should be
HugePages_Total: 2000

There can be several reasons:
1. Your memory is fragmented, so kernel can not allocated non-fragmented part with requested size,
can you try allocate just after reboot ?
2. echo 2000 &gt; /proc/sys/vm/nr_hugepages does not work on your box

See also Configuring Huge Pages in RHEL 3/4 here:
http://www.puschitz.com/TuningLinuxForOracle.shtml#ConfiguringHugePagesInRHEL4</description>
		<content:encoded><![CDATA[<p>Anja,</p>
<p>You do not need to execute mount none /mnt/hugepages -t hugetlbfs<br />
for mysql</p>
<p>all what you need is<br />
echo 2000 > /proc/sys/vm/nr_hugepages</p>
<p>or equal command for your Linux (what do you use btw ? )</p>
<p>As I see your command was not executed successfully:</p>
<p>HugePages_Total: 0<br />
HugePages_Free: 0<br />
Hugepagesize: 2048 kB</p>
<p>There should be<br />
HugePages_Total: 2000</p>
<p>There can be several reasons:<br />
1. Your memory is fragmented, so kernel can not allocated non-fragmented part with requested size,<br />
can you try allocate just after reboot ?<br />
2. echo 2000 > /proc/sys/vm/nr_hugepages does not work on your box</p>
<p>See also Configuring Huge Pages in RHEL 3/4 here:<br />
<a href="http://www.puschitz.com/TuningLinuxForOracle.shtml#ConfiguringHugePagesInRHEL4" rel="nofollow">http://www.puschitz.com/TuningLinuxForOracle.shtml#ConfiguringHugePagesInRHEL4</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Anja Gheldof</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-19140</link>
		<dc:creator>Anja Gheldof</dc:creator>
		<pubDate>Fri, 01 Dec 2006 15:35:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-19140</guid>
		<description>Vadim,

I configured already a kernel to enable huge pages. I can use huge pages with a size of 2MB. 

I made a script that does the following:
mount none /mnt/hugepages -t hugetlbfs

I did that because I saw with the monitoring tool strace that mysql uses mmap system calls.
Here you can see the output of 
strace -c -f -o strace.txt -p 4721 (4721 is the pid of mysql)

% time	seconds	usecs/call	calls	errors	syscall
					
84.78	18.000.427.471	10362	1737133	144871	futex
5.11	1.084.404.926	22078	49117	1	select
4.89	1.037.780.473	393	2637973	274671	read
1.25	264.358.705	46855	5642		rt_sigtimedwait
1.07	226.303.746	96	2368066		time
0.89	189.576.561	294	645392		sched_yield
0.42	90.140.144	80	1126118		rt_sigprocmask
0.42	89.731.199	88	1013972	1013972	sched_setscheduler
0.30	63.858.894	112	572717	4012	write
0.20	42.552.311	185	230154		munmap
0.20	42.525.781	75	564870		fcntl
0.16	32.911.366	135	243164		mmap
0.11	23.633.754	29	807912		lseek
0.08	16.839.725	62	271100		open
0.05	10.935.959	21	530205		pread
0.02	5.296.405	20	268102	265100	access
0.02	4.758.093	17	272612		close
0.01	2.227.735	154	14467		mprotect
0.00	0.484223	124	3906		pwrite
0.00	0.445093	404	1102		fsync
0.00	0.430290	72	6000	1500	lstat
0.00	0.372081	124	3002		unlink
0.00	0.347109	61	5701		tgkill
0.00	0.334789	74	4503		setsockopt
0.00	0.306899	54	5639		alarm
0.00	0.269266	60	4500	4500	readlink
0.00	0.132078	88	1501		getpeername
0.00	0.113291	75	1501		accept
0.00	0.112548	75	1504		shutdown
0.00	0.095832	64	1501		getsockname
0.00	0.004834	44	109		clone
0.00	0.001256	60	21		brk
0.00	0.000094	47	2		gettimeofday
0.00	0.000046	23	2		rt_sigaction
0.00	0.000028	14	2	2	rt_sigreturn
0.00	0.000009	9	1		clock_gettime
					
100.00	21.231.713.014	13399213	1708629	total	

I also put the parameter larges-pages in the my.cnf and when I check in mysql I saw the following:

show variables like &#039;%large%&#039;;
+---------------------+---------+
&#124; Variable_name       &#124; Value   &#124;
+---------------------+---------+
&#124; large_files_support &#124; ON      &#124;
&#124; large_page_size     &#124; 2097152 &#124;
&#124; large_pages         &#124; ON      &#124;
+---------------------+---------+
3 rows in set (0.00 sec)


Now I have a few questions:

- Did I do something wrong here? Or am I forgetting something?
- Can I assume that the large_page_size here is 2097152 kB? So it uses 1048 pages of 2M?
- Must I use the following or is mysql doing that when it starts:
Use the following command to dynamically allocate/deallocate hugepages:	
	echo 2000 &gt; /proc/sys/vm/nr_hugepages
- and the most important question for me is: How can i see that mysql use this huge pages.

Information about the server that I use:

Linux DL585 2.6.15.1-huge-page #1 SMP Thu Nov 23 22:37:15 CET 2006 x86_64 GNU/Linux

cat /proc/meminfo
MemTotal:      8012512 kB
MemFree:       6006088 kB
Buffers:          7484 kB
Cached:        1019872 kB
SwapCached:          0 kB
Active:         962876 kB
Inactive:      1003952 kB
HighTotal:           0 kB
HighFree:            0 kB
LowTotal:      8012512 kB
LowFree:       6006088 kB
SwapTotal:      975112 kB
SwapFree:       975112 kB
Dirty:               0 kB
Writeback:           0 kB
Mapped:         948948 kB
Slab:            18344 kB
CommitLimit:   4981368 kB
Committed_AS:  1555036 kB
PageTables:       3248 kB
VmallocTotal: 34359738367 kB
VmallocUsed:      3956 kB
VmallocChunk: 34359734159 kB
HugePages_Total:     0
HugePages_Free:      0
Hugepagesize:     2048 kB

I know I ask a lot, but it should be a great help for me if anyone could help me out.

Thanks,Anja</description>
		<content:encoded><![CDATA[<p>Vadim,</p>
<p>I configured already a kernel to enable huge pages. I can use huge pages with a size of 2MB. </p>
<p>I made a script that does the following:<br />
mount none /mnt/hugepages -t hugetlbfs</p>
<p>I did that because I saw with the monitoring tool strace that mysql uses mmap system calls.<br />
Here you can see the output of<br />
strace -c -f -o strace.txt -p 4721 (4721 is the pid of mysql)</p>
<p>% time	seconds	usecs/call	calls	errors	syscall</p>
<p>84.78	18.000.427.471	10362	1737133	144871	futex<br />
5.11	1.084.404.926	22078	49117	1	select<br />
4.89	1.037.780.473	393	2637973	274671	read<br />
1.25	264.358.705	46855	5642		rt_sigtimedwait<br />
1.07	226.303.746	96	2368066		time<br />
0.89	189.576.561	294	645392		sched_yield<br />
0.42	90.140.144	80	1126118		rt_sigprocmask<br />
0.42	89.731.199	88	1013972	1013972	sched_setscheduler<br />
0.30	63.858.894	112	572717	4012	write<br />
0.20	42.552.311	185	230154		munmap<br />
0.20	42.525.781	75	564870		fcntl<br />
0.16	32.911.366	135	243164		mmap<br />
0.11	23.633.754	29	807912		lseek<br />
0.08	16.839.725	62	271100		open<br />
0.05	10.935.959	21	530205		pread<br />
0.02	5.296.405	20	268102	265100	access<br />
0.02	4.758.093	17	272612		close<br />
0.01	2.227.735	154	14467		mprotect<br />
0.00	0.484223	124	3906		pwrite<br />
0.00	0.445093	404	1102		fsync<br />
0.00	0.430290	72	6000	1500	lstat<br />
0.00	0.372081	124	3002		unlink<br />
0.00	0.347109	61	5701		tgkill<br />
0.00	0.334789	74	4503		setsockopt<br />
0.00	0.306899	54	5639		alarm<br />
0.00	0.269266	60	4500	4500	readlink<br />
0.00	0.132078	88	1501		getpeername<br />
0.00	0.113291	75	1501		accept<br />
0.00	0.112548	75	1504		shutdown<br />
0.00	0.095832	64	1501		getsockname<br />
0.00	0.004834	44	109		clone<br />
0.00	0.001256	60	21		brk<br />
0.00	0.000094	47	2		gettimeofday<br />
0.00	0.000046	23	2		rt_sigaction<br />
0.00	0.000028	14	2	2	rt_sigreturn<br />
0.00	0.000009	9	1		clock_gettime</p>
<p>100.00	21.231.713.014	13399213	1708629	total	</p>
<p>I also put the parameter larges-pages in the my.cnf and when I check in mysql I saw the following:</p>
<p>show variables like &#8216;%large%&#8217;;<br />
+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;+&#8212;&#8212;&#8212;+<br />
| Variable_name       | Value   |<br />
+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;+&#8212;&#8212;&#8212;+<br />
| large_files_support | ON      |<br />
| large_page_size     | 2097152 |<br />
| large_pages         | ON      |<br />
+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;+&#8212;&#8212;&#8212;+<br />
3 rows in set (0.00 sec)</p>
<p>Now I have a few questions:</p>
<p>- Did I do something wrong here? Or am I forgetting something?<br />
- Can I assume that the large_page_size here is 2097152 kB? So it uses 1048 pages of 2M?<br />
- Must I use the following or is mysql doing that when it starts:<br />
Use the following command to dynamically allocate/deallocate hugepages:<br />
	echo 2000 &gt; /proc/sys/vm/nr_hugepages<br />
- and the most important question for me is: How can i see that mysql use this huge pages.</p>
<p>Information about the server that I use:</p>
<p>Linux DL585 2.6.15.1-huge-page #1 SMP Thu Nov 23 22:37:15 CET 2006 x86_64 GNU/Linux</p>
<p>cat /proc/meminfo<br />
MemTotal:      8012512 kB<br />
MemFree:       6006088 kB<br />
Buffers:          7484 kB<br />
Cached:        1019872 kB<br />
SwapCached:          0 kB<br />
Active:         962876 kB<br />
Inactive:      1003952 kB<br />
HighTotal:           0 kB<br />
HighFree:            0 kB<br />
LowTotal:      8012512 kB<br />
LowFree:       6006088 kB<br />
SwapTotal:      975112 kB<br />
SwapFree:       975112 kB<br />
Dirty:               0 kB<br />
Writeback:           0 kB<br />
Mapped:         948948 kB<br />
Slab:            18344 kB<br />
CommitLimit:   4981368 kB<br />
Committed_AS:  1555036 kB<br />
PageTables:       3248 kB<br />
VmallocTotal: 34359738367 kB<br />
VmallocUsed:      3956 kB<br />
VmallocChunk: 34359734159 kB<br />
HugePages_Total:     0<br />
HugePages_Free:      0<br />
Hugepagesize:     2048 kB</p>
<p>I know I ask a lot, but it should be a great help for me if anyone could help me out.</p>
<p>Thanks,Anja</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vadim</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-19126</link>
		<dc:creator>Vadim</dc:creator>
		<pubDate>Fri, 01 Dec 2006 13:49:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-19126</guid>
		<description>Anja,

You need to start mysql with --large-pages options
http://dev.mysql.com/doc/refman/5.0/en/server-options.html

But before, you have to configure your Linux to enable huge pages.
for example you can read hugetlbpage.txt :
http://www.mjmwired.net/kernel/Documentation/vm/hugetlbpage.txt

However take into account RedHat uses its own way to enable huge pages, perhaps others vendors too.</description>
		<content:encoded><![CDATA[<p>Anja,</p>
<p>You need to start mysql with &#8211;large-pages options<br />
<a href="http://dev.mysql.com/doc/refman/5.0/en/server-options.html" rel="nofollow">http://dev.mysql.com/doc/refman/5.0/en/server-options.html</a></p>
<p>But before, you have to configure your Linux to enable huge pages.<br />
for example you can read hugetlbpage.txt :<br />
<a href="http://www.mjmwired.net/kernel/Documentation/vm/hugetlbpage.txt" rel="nofollow">http://www.mjmwired.net/kernel/Documentation/vm/hugetlbpage.txt</a></p>
<p>However take into account RedHat uses its own way to enable huge pages, perhaps others vendors too.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Anja Gheldof</title>
		<link>http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/comment-page-1/#comment-18874</link>
		<dc:creator>Anja Gheldof</dc:creator>
		<pubDate>Fri, 01 Dec 2006 00:32:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.mysqlperformanceblog.com/2006/06/08/mysql-server-variables-sql-layer-or-storage-engine-specific/#comment-18874</guid>
		<description>Hello,

I&#039;m trying to test mysql with large-pages. I compiled a kernel so it support huge pages. Now I want to use large-pages in mysql. How do I use the large-pages? How do I know that mysql use this huge pages? Is there a way to see that? 

Anja (Student)</description>
		<content:encoded><![CDATA[<p>Hello,</p>
<p>I&#8217;m trying to test mysql with large-pages. I compiled a kernel so it support huge pages. Now I want to use large-pages in mysql. How do I use the large-pages? How do I know that mysql use this huge pages? Is there a way to see that? </p>
<p>Anja (Student)</p>
]]></content:encoded>
	</item>
</channel>
</rss>
