<?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; 5.0</title>
	<atom:link href="http://planetmysql.ru/category/5-0/feed/" rel="self" type="application/rss+xml" />
	<link>http://planetmysql.ru</link>
	<description>Блог о самой популярной СУБД MySQL</description>
	<lastBuildDate>Thu, 24 May 2012 05:41:40 +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>MySQL Sandbox at the OTN MySQL Developers day in Paris, March 21st</title>
		<link>http://datacharmer.blogspot.com/2012/03/mysql-sandbox-at-otn-mysql-developers.html?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=mysql-sandbox-at-the-otn-mysql-developers-day-in-paris-march-21st</link>
		<comments>http://datacharmer.blogspot.com/2012/03/mysql-sandbox-at-otn-mysql-developers.html#comments</comments>
		<pubDate>Tue, 13 Mar 2012 08:57:00 +0000</pubDate>
		<dc:creator>Giuseppe Maxia</dc:creator>
				<category><![CDATA[5.0]]></category>
		<category><![CDATA[5.1]]></category>
		<category><![CDATA[5.5]]></category>
		<category><![CDATA[5.6]]></category>
		<category><![CDATA[community]]></category>
		<category><![CDATA[conference]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Europe]]></category>
		<category><![CDATA[events]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[sandbox]]></category>

		<guid isPermaLink="false">http://planetmysql.ru/?guid=c30c3c04a7733d33ea08a522aceb15c3</guid>
		<description><![CDATA[On March 21st I will be in Paris, to attend the OTN MySQL Developers Day.Oracle is organizing these events all over the world, and although the majority are in the US, some of them are touching the good old European continent.Previous events were an all-Oracle show. Recently, the MySQL Community team has been asking for cooperation from the community, and in such capacity I am also presenting at the event, on the topic of testing early releases of MySQL in a sandbox. Of course, this is one of my favorite topics, but it is quite appropriate in this period, when Oracle has released a whole lot of preview features in its MySQL Labs. Which is another favorite topic of mine, since I was the one who insisted for having the Labs when I was working in the community team. It's nice to see that the labs are still in place, and being put to good use.Speaking of sandboxes, I was making some quick tests yesterday, and I installed 15 sandboxes at once (all different versions, from 5.0.91 to 5.6.5). Installing a single sandbox, depending on the version, takes from 5 to 19 seconds.Do you know how long it takes to install 15 sandboxes, completely, from tarball to working conditions? It takes 19 seconds. How's so? It's because I have been working at a large project where we are dealing with many replicated clusters spread across three continents. Administering these clusters is a problem in itself, and so we are using tools to do our work in parallel. At the same time, using a host with a fast 16 core CPU I can install many sandboxes at once. It's a real joy to see software behaving efficiently the way it should!It works so fast, in fact, that I found a race condition bug. If you install more than one sandbox at once, the MySQL bootstrap process may try to open the same temporary file from two different servers. That's because I did not indicate a dedicated temporary directory for the bootstrap (I was using one only for the installed sandbox). When this happens, you may find that instead of 15 sandboxes you have installed only 9 or 11. So I fixed the bug, by adding --tmpdir to mysql_install_db, and now you can install more than one sandbox in parallel.]]></description>
			<content:encoded><![CDATA[On March 21st I will be in Paris, to attend the <a href="http://www.oracle.com/webapps/events/ns/EventsDetail.jsp?p_eventId=149253&amp;src=7314534&amp;src=7314534&amp;Act=259">OTN MySQL Developers Day</a>.Oracle is organizing these events all over the world, and although the majority are in the US, some of them are touching the good old European continent.Previous events were an all-Oracle show. Recently, the MySQL Community team has been asking for cooperation from the community, and in such capacity I am also presenting at the event, on the topic of testing early releases of MySQL in a sandbox. Of course, this is one of my favorite topics, but it is quite appropriate in this period, when Oracle has released a whole lot of preview features in its <a href="http://labs.mysql.com/">MySQL Labs</a>. Which is another favorite topic of mine, since I was the one who insisted for having the Labs when I was working in the community team. It's nice to see that the labs are still in place, and being put to good use.<p><img src="http://lh6.ggpht.com/-JJg6UwmaRXU/T18L57WzI_I/AAAAAAAABQc/fv8fINGHReE/MySQL_Sandbox.png?imgmax=800" alt="MySQL Sandbox" title="MySQL_Sandbox.png" border="0" width="600" height="545" /></p>Speaking of sandboxes, I was making some quick tests yesterday, and I installed 15 sandboxes at once (all different versions, from 5.0.91 to 5.6.5). Installing a single sandbox, depending on the version, takes from 5 to 19 seconds.Do you know how long it takes to install 15 sandboxes, completely, from tarball to working conditions? It takes 19 seconds. How's so? It's because I have been working at a large project where we are dealing with many replicated clusters spread across three continents. Administering these clusters is a problem in itself, and so we are using tools to do our work in parallel. At the same time, using a host with a fast 16 core CPU I can install many sandboxes at once. It's a real joy to see software behaving efficiently the way it should!It works so fast, in fact, that I found a race condition bug. If you install more than one sandbox at once, the MySQL bootstrap process may try to open the same temporary file from two different servers. That's because I did not indicate a dedicated temporary directory for the bootstrap (I was using one only for the installed sandbox). When this happens, you may find that instead of 15 sandboxes you have installed only 9 or 11. So I fixed the bug, by adding <i>--tmpdir</i> to <i>mysql_install_db</i>, and now you can install more than one sandbox in parallel.<div><img width="1" height="1" src="https://blogger.googleusercontent.com/tracker/16959946-5623504402958128054?l=datacharmer.blogspot.com" alt="" /></div><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=32309&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=32309&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2012/03/13/mysql-sandbox-at-the-otn-mysql-developers-day-in-paris-march-21st/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL Sandbox at the OTN MySQL Developers day in Paris, March 21st</title>
		<link>http://datacharmer.blogspot.com/2012/03/mysql-sandbox-at-otn-mysql-developers.html?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=mysql-sandbox-at-the-otn-mysql-developers-day-in-paris-march-21st</link>
		<comments>http://datacharmer.blogspot.com/2012/03/mysql-sandbox-at-otn-mysql-developers.html#comments</comments>
		<pubDate>Tue, 13 Mar 2012 08:57:00 +0000</pubDate>
		<dc:creator>Giuseppe Maxia</dc:creator>
				<category><![CDATA[5.0]]></category>
		<category><![CDATA[5.1]]></category>
		<category><![CDATA[5.5]]></category>
		<category><![CDATA[5.6]]></category>
		<category><![CDATA[community]]></category>
		<category><![CDATA[conference]]></category>
		<category><![CDATA[Development]]></category>
		<category><![CDATA[Europe]]></category>
		<category><![CDATA[events]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[sandbox]]></category>

		<guid isPermaLink="false">http://planetmysql.ru/?guid=c30c3c04a7733d33ea08a522aceb15c3</guid>
		<description><![CDATA[On March 21st I will be in Paris, to attend the OTN MySQL Developers Day.Oracle is organizing these events all over the world, and although the majority are in the US, some of them are touching the good old European continent.Previous events were an all-Oracle show. Recently, the MySQL Community team has been asking for cooperation from the community, and in such capacity I am also presenting at the event, on the topic of testing early releases of MySQL in a sandbox. Of course, this is one of my favorite topics, but it is quite appropriate in this period, when Oracle has released a whole lot of preview features in its MySQL Labs. Which is another favorite topic of mine, since I was the one who insisted for having the Labs when I was working in the community team. It's nice to see that the labs are still in place, and being put to good use.Speaking of sandboxes, I was making some quick tests yesterday, and I installed 15 sandboxes at once (all different versions, from 5.0.91 to 5.6.5). Installing a single sandbox, depending on the version, takes from 5 to 19 seconds.Do you know how long it takes to install 15 sandboxes, completely, from tarball to working conditions? It takes 19 seconds. How's so? It's because I have been working at a large project where we are dealing with many replicated clusters spread across three continents. Administering these clusters is a problem in itself, and so we are using tools to do our work in parallel. At the same time, using a host with a fast 16 core CPU I can install many sandboxes at once. It's a real joy to see software behaving efficiently the way it should!It works so fast, in fact, that I found a race condition bug. If you install more than one sandbox at once, the MySQL bootstrap process may try to open the same temporary file from two different servers. That's because I did not indicate a dedicated temporary directory for the bootstrap (I was using one only for the installed sandbox). When this happens, you may find that instead of 15 sandboxes you have installed only 9 or 11. So I fixed the bug, by adding --tmpdir to mysql_install_db, and now you can install more than one sandbox in parallel.]]></description>
			<content:encoded><![CDATA[On March 21st I will be in Paris, to attend the <a href="http://www.oracle.com/webapps/events/ns/EventsDetail.jsp?p_eventId=149253&amp;src=7314534&amp;src=7314534&amp;Act=259">OTN MySQL Developers Day</a>.Oracle is organizing these events all over the world, and although the majority are in the US, some of them are touching the good old European continent.Previous events were an all-Oracle show. Recently, the MySQL Community team has been asking for cooperation from the community, and in such capacity I am also presenting at the event, on the topic of testing early releases of MySQL in a sandbox. Of course, this is one of my favorite topics, but it is quite appropriate in this period, when Oracle has released a whole lot of preview features in its <a href="http://labs.mysql.com/">MySQL Labs</a>. Which is another favorite topic of mine, since I was the one who insisted for having the Labs when I was working in the community team. It's nice to see that the labs are still in place, and being put to good use.<p><img src="http://lh6.ggpht.com/-JJg6UwmaRXU/T18L57WzI_I/AAAAAAAABQc/fv8fINGHReE/MySQL_Sandbox.png?imgmax=800" alt="MySQL Sandbox" title="MySQL_Sandbox.png" border="0" width="600" height="545" /></p>Speaking of sandboxes, I was making some quick tests yesterday, and I installed 15 sandboxes at once (all different versions, from 5.0.91 to 5.6.5). Installing a single sandbox, depending on the version, takes from 5 to 19 seconds.Do you know how long it takes to install 15 sandboxes, completely, from tarball to working conditions? It takes 19 seconds. How's so? It's because I have been working at a large project where we are dealing with many replicated clusters spread across three continents. Administering these clusters is a problem in itself, and so we are using tools to do our work in parallel. At the same time, using a host with a fast 16 core CPU I can install many sandboxes at once. It's a real joy to see software behaving efficiently the way it should!It works so fast, in fact, that I found a race condition bug. If you install more than one sandbox at once, the MySQL bootstrap process may try to open the same temporary file from two different servers. That's because I did not indicate a dedicated temporary directory for the bootstrap (I was using one only for the installed sandbox). When this happens, you may find that instead of 15 sandboxes you have installed only 9 or 11. So I fixed the bug, by adding <i>--tmpdir</i> to <i>mysql_install_db</i>, and now you can install more than one sandbox in parallel.<div><img width="1" height="1" src="https://blogger.googleusercontent.com/tracker/16959946-5623504402958128054?l=datacharmer.blogspot.com" alt="" /></div><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=32309&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=32309&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2012/03/13/mysql-sandbox-at-the-otn-mysql-developers-day-in-paris-march-21st/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL 5.0 and 5.1 available on Solaris 11</title>
		<link>http://blogs.oracle.com/partnertech/entry/mysql_5_0_and_5?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=mysql-5-0-and-5-1-available-on-solaris-11</link>
		<comments>http://blogs.oracle.com/partnertech/entry/mysql_5_0_and_5#comments</comments>
		<pubDate>Wed, 18 Jan 2012 07:34:49 +0000</pubDate>
		<dc:creator>Sun Partner Technology</dc:creator>
				<category><![CDATA[11]]></category>
		<category><![CDATA[5.0]]></category>
		<category><![CDATA[5.1]]></category>
		<category><![CDATA[available]]></category>
		<category><![CDATA[certified]]></category>
		<category><![CDATA[download]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[solaris]]></category>
		<category><![CDATA[sun]]></category>

		<guid isPermaLink="false">http://blogs.oracle.com/partnertech/entry/mysql_5_0_and_5</guid>
		<description><![CDATA[The installation through the Solaris repository is as simple as typing: 
  $ pkg install&#160;mysql-50 
  to obtain MySQL 5.0.91 (status Jan 18, 2012) or click on this link to launch the interactive installer. 
  $ pkg install&#160;mysql-51 
  to obtain MySQL 5.1.37 (status Jan. 18, 2012) or click on this link to launch the interactive installer.]]></description>
			<content:encoded><![CDATA[<p>The installation through the <a href="http://pkg.oracle.com">Solaris repository</a> is as simple as typing:</p> 
  <pre>$ pkg install&nbsp;mysql-50</pre> 
  <p>to obtain MySQL 5.0.91 (status Jan 18, 2012) or click on this <a href="http://pkg.oracle.com/solaris/release/p5i/0/database/mysql-50.p5i" title="package manager">link to launch the interactive installer</a>.</p> 
  <pre>$ pkg install&nbsp;mysql-51</pre> 
  <p>to obtain MySQL 5.1.37 (status Jan. 18, 2012) or click on this <a href="http://pkg.oracle.com/solaris/release/p5i/0/database/mysql-51.p5i" title="package manager">link to launch the interactive installer</a>.</p><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=31643&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=31643&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2012/01/18/mysql-5-0-and-5-1-available-on-solaris-11/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL 5.1.47 and 5.0.91 released &#8212; Two strong reasons to upgrade</title>
		<link>http://blogs.sun.com/datacharmer/entry/mysql_5_1_47_released?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=mysql-5-1-47-and-5-0-91-released-two-strong-reasons-to-upgrade</link>
		<comments>http://blogs.sun.com/datacharmer/entry/mysql_5_1_47_released#comments</comments>
		<pubDate>Fri, 21 May 2010 04:38:48 +0000</pubDate>
		<dc:creator>Giuseppe Maxia</dc:creator>
				<category><![CDATA[5.0]]></category>
		<category><![CDATA[5.1]]></category>
		<category><![CDATA[community]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[plugin.innodb]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[upgrade]]></category>

		<guid isPermaLink="false">http://blogs.sun.com/datacharmer/entry/mysql_5_1_47_released</guid>
		<description><![CDATA[




MySQL has released security updates for MySQL 5.1.47 and 5.0.91. The most important changes in these releases are fixes of three security bugs. One of them is a problem that had been lurking in the code for many years, and it was found by chance when one of our developers, testing something unrelated, stumbled upon one of the vulnerabilities. Later on, when analyzing the bug, the developers found one more issue, and they fixed it as well. 

MySQL 5.1.47
In addition to the security update, MySQL 5.1.47 is also very important for an additional reason. The InnoDB plugin that ships with this version has been updated to 1.0.8, which is considered to be of General Availability (GA) quality.

There are more changes, including some twists to the error log, to make replication administration more robust.

MySQL 5.0.91 security update

Together with MySQl 5.1.47, there is a security update of MySQL 5.0.91.
Since MySQL 5.0 is now in Extended Support state, the binaries are not in the main download pages, but only in the archives.
 As the MySQL Lifecycle Policy says, only serious security bugs are fixed, and the binaries are provided at the company's discretion. 

If you are still using MySQL 5.0, this is a good moment to upgrade to 5.1.]]></description>
			<content:encoded><![CDATA[<table border="0">
<tr><td>
<a href="http://dev.mysql.com/doc/refman/5.1/en/news-5-1-47.html"><img src="http://blogs.sun.com/datacharmer/resource/sakila_security_256x203.jpg" border="0" title="MySQL Security alert" alt="MySQL security" /></a>
</td>
<td>
MySQL has released security updates for MySQL 5.1.47 and 5.0.91. The most important changes in these releases are fixes of three security bugs. One of them is a problem that had been lurking in the code for many years, and it was found by chance when one of our developers, testing something unrelated, stumbled upon one of the vulnerabilities. Later on, when analyzing the bug, the developers found one more issue, and they fixed it as well. 
</td></tr></table>
<h3>MySQL 5.1.47</h3>
<p>In addition to the security update, MySQL 5.1.47 is also very important for an additional reason. The <a href="http://dev.mysql.com/doc/innodb-plugin/1.0/en/innodb-plugin-introduction.html">InnoDB plugin</a> that ships with this version has been updated to 1.0.8, which is considered to be of General Availability (GA) quality.
</p>
<p>There are more <a href="http://dev.mysql.com/doc/refman/5.1/en/news-5-1-47.html">changes</a>, including some twists to the error log, to make replication administration more robust.
</p>
<h3>MySQL 5.0.91 security update</h3>
<p>
Together with MySQl 5.1.47, there is a security update of <a href="http://dev.mysql.com/doc/refman/5.0/en/news-5-0-91.html">MySQL 5.0.91</a>.<p>
<p>Since MySQL 5.0 is now in <a href="http://www.mysql.com/about/legal/lifecycle/">Extended Support</a> state, the binaries are not in the main download pages, but only in the <a href="http://downloads.mysql.com/archives.php?p=mysql-5.0">archives</a>.
 As the <a href="http://www.mysql.com/about/legal/lifecycle/">MySQL Lifecycle Policy</a> says, only serious security bugs are fixed, and the binaries are provided at the company's discretion. 
</p>
<p>If you are still using MySQL 5.0, this is a good moment to upgrade to 5.1.</p><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=24825&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=24825&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2010/05/21/mysql-5-1-47-and-5-0-91-released-two-strong-reasons-to-upgrade/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Further Thoughts on MySQL Upgrades</title>
		<link>http://blog.wl0.org/2010/01/further-thoughts-on-mysql-upgrades/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=further-thoughts-on-mysql-upgrades</link>
		<comments>http://blog.wl0.org/2010/01/further-thoughts-on-mysql-upgrades/#comments</comments>
		<pubDate>Fri, 29 Jan 2010 23:25:48 +0000</pubDate>
		<dc:creator>Simon Mudd</dc:creator>
				<category><![CDATA[5.0]]></category>
		<category><![CDATA[5.1]]></category>
		<category><![CDATA[advanced]]></category>
		<category><![CDATA[Databases]]></category>
		<category><![CDATA[enterprise]]></category>
		<category><![CDATA[hints]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[rpm]]></category>
		<category><![CDATA[upgrade]]></category>

		<guid isPermaLink="false">http://blog.wl0.org/2010/01/further-thoughts-on-mysql-upgrades/</guid>
		<description><![CDATA[I have been upgrading more MySQL database instances recently and have found a few more potential gotchas, which if you are not careful, can potentially be rather nasty. These are not documented explicitly by MySQL, so it may be handy for you to know if you have not come across this type of thing before.
Most of the issues are those related to upgrading MySQL instances which are replicated, either the master servers or the slaves. Some seem specific to the rpm packages I am using (MySQL enterprise or MySQL advanced rpms), though others are not.
Take care upgrading a 5.0 master when you have 5.1 slaves
It is not a good idea to run a mixed major version of mysql in a replicated environment so why would I be doing this? If you work in a replicated environment and have several slaves then it is recommended that you upgrade the slaves first. I work with quite a few slaves so the process of upgrading them all takes longer than you would think. Quite a long time in fact, while different systems are tested and upgraded. Along came a newer version of 5.0 and I thought of upgrading the master which had been giving a few issues, and one of them was resolved in the lastest 5.0.89. At least when using rpm packages, the package upgrade uses /usr/bin/mysql_install_db &#8211;rpm &#8211;user=mysql as part of the package upgrade procedure. This ensures that the mysql db is up to date but also writes to the binlog if one is configured. running on a master normally this would be the case. Of course these are 5.0 install commands and they are not really understood by the slaves which try to interpret them too. End result. Broken replication and you need to skip several transactions. If you have several slaves this can be rather painful.
Note: this is the cause of replicating the mysql database which I do as it is a good, quick and clean way to distribute GRANT information on to all slaves. As far as I know MySQL does not discourage this though perhaps many sites do not replicate their MySQL database.
If you upgrade a master server from 5.o to 5.1 by running mysql_upgrade after upgrading the binaries you may have a similar issue as the mysql_upgrade script determines that some new columns or tables are needed on the master and so adds them.  Again this gets written to the binlog which is good for point in time recovery on the server itself, but again bad from a replication point of view if the slave does not run the same version of MySQL.
In fact the binlog has these 2 uses: (a) writing changes for point in time recovery, and (b) writing the changes for replication to slaves.  Once could argue that for (a) the changes should not be written to the binlog but I think that is wrong if you have to recover just after an upgrade. So I would suggest that the upgrade changes should probably flagged specially in the binlog, allowing the slave to probably ignore them in the normal situation but also be able to recognise them, allowing you to stop the slave and perform the same binary upgrade, and then continue the upgrade with the new binaries exactly in the way this had been executed on the master. This behaviour should be controlled by a runtime flag which can be dynamically configured.
RPM Installs/Upgrades always start the server
rpm(8) is good but some of the design decisions in the MySQL rpms are questionable. One of these is that the current MySQL rpms are designed to always start when either doing a fresh install or doing an upgrade. Currently it&#8217;s not good practice to do rpm -Uvh MySQL-server-advanced-gpl&#8230;rpm (5.1 rpm) if you are running a MySQL-server-enterprise-gpl&#8230;rpm (5.0 rpm) so normally I stop MySQL, remove the enterprise rpm and install the advanced rpm. That starts the server and the slave on a box which is not completely &#8220;stable&#8221;. Solution is to add slave-skip-start to /etc/my.cnf but that should not be necessary as immediately after running mysql_upgrade you need to remove the value again.
Also during the upgrade process it is a good thing to avoid external client access so sometimes I also set the bind-address to 127.0.0.1 during the period of the upgrade.  That may not keep clients away if they are running on the local server but helps in many cases.
Conclusions
All this leads me to a simple conclusion: if you can, upgrade one box the slow way and then clone the other slaves from that. Cloning is simple and requires no thought so is a good idea.
The other conclusion based on the first one is that if you can: build a new master. That is clone a slave to make a new master. This will be the new master. Configure it to write it&#8217;s own binlogs and then you can move the existing slaves underneath the new one. Once all slaves are underneath the new master (left as the only slave of the original master) then you can simply point clients to the new master instead of the old one. That keeps down time to a minimum and avoids many problems.
As far as I know none of the comments I have made above are in the current 5.1 upgrade documentation. I have opened quite a few tickets requesting the documentation be improved and I guess that will happen slowly. For many people the points I have mentioned may seem irrelevant for their situation but for me they have caused a few problems. If you do not need to worry, then you can skip the documentation, otherwise if this were documented then you would be saved a few tears when least expecting problems.]]></description>
			<content:encoded><![CDATA[<p>I have been upgrading more MySQL database instances recently and have found a few more potential <em>gotchas,</em> which if you are not careful, can potentially be rather nasty. These are not documented explicitly by MySQL, so it may be handy for you to know if you have not come across this type of thing before.</p>
<p>Most of the issues are those related to upgrading MySQL instances which are replicated, either the master servers or the slaves. Some seem specific to the rpm packages I am using (MySQL enterprise or MySQL advanced rpms), though others are not.</p>
<h2>Take care upgrading a 5.0 master when you have 5.1 slaves</h2>
<p>It is not a good idea to run a mixed major version of mysql in a replicated environment so why would I be doing this? If you work in a replicated environment and have several slaves then it is recommended that you upgrade the slaves first. I work with quite a few slaves so the process of upgrading them all takes longer than you would think. Quite a long time in fact, while different systems are tested and upgraded. Along came a newer version of 5.0 and I thought of upgrading the master which had been giving a few issues, and one of them was resolved in the lastest 5.0.89. At least <span>when using rpm packages</span>, the package upgrade uses /usr/bin/mysql_install_db &#8211;rpm &#8211;user=mysql as part of the package upgrade procedure. This ensures that the mysql db is up to date but also writes to the binlog if one is configured. running on a master normally this would be the case. Of course these are 5.0 install commands and they are not really understood by the slaves which try to interpret them too. End result. Broken replication and you need to skip several transactions. If you have several slaves this can be rather painful.</p>
<p>Note: this is the cause of replicating the <span>mysql</span> database which I do as it is a good, quick and clean way to distribute GRANT information on to all slaves. As far as I know MySQL does not discourage this though perhaps many sites do not replicate their MySQL database.</p>
<p>If you upgrade a master server from 5.o to 5.1 by running <em>mysql_upgrade</em> after upgrading the binaries you may have a similar issue as the <em>mysql_upgrade</em> script determines that some new columns or tables are needed on the master and so adds them.  Again this gets written to the binlog which is good for point in time recovery on the server itself, but again bad from a replication point of view if the slave does not run the same version of MySQL.</p>
<p>In fact the binlog has these 2 uses: (a) writing changes for point in time recovery, and (b) writing the changes for replication to slaves.  Once could argue that for (a) the changes should not be written to the binlog but I think that is wrong if you have to recover just after an upgrade. So I would suggest that the <em>upgrade changes</em> should probably flagged specially in the binlog, allowing the slave to probably ignore them in the normal situation but also be able to recognise them, allowing you to stop the slave and perform the same binary upgrade, and then continue the upgrade with the new binaries exactly in the way this had been executed on the master. This behaviour should be controlled by a runtime flag which can be dynamically configured.</p>
<h2>RPM Installs/Upgrades always start the server</h2>
<p>rpm(8) is good but some of the design decisions in the MySQL rpms are questionable. One of these is that the current MySQL rpms are designed to always start when either doing a fresh install or doing an upgrade. Currently it&#8217;s not good practice to do rpm -Uvh MySQL-server-advanced-gpl&#8230;rpm (5.1 rpm) if you are running a MySQL-server-enterprise-gpl&#8230;rpm (5.0 rpm) so normally I stop MySQL, remove the enterprise rpm and install the advanced rpm. That starts the server and the slave on a box which is not completely &#8220;stable&#8221;. Solution is to add slave-skip-start to /etc/my.cnf but that should not be necessary as immediately after running mysql_upgrade you need to remove the value again.</p>
<p>Also during the upgrade process it is a good thing to avoid external client access so sometimes I also set the bind-address to 127.0.0.1 during the period of the upgrade.  That may not keep clients away if they are running on the local server but helps in many cases.</p>
<h2>Conclusions</h2>
<p>All this leads me to a simple conclusion: if you can, upgrade one box the slow way and then clone the other slaves from that. Cloning is simple and requires no thought so is a good idea.</p>
<p>The other conclusion based on the first one is that if you can: <strong>build a new master</strong>. That is clone a slave to make a new master. This will be the new master. Configure it to write it&#8217;s own binlogs and then you can move the existing slaves underneath the new one. Once all slaves are underneath the new master (left as the only slave of the original master) then you can simply point clients to the new master instead of the old one. That keeps down time to a minimum and avoids many problems.</p>
<p>As far as I know none of the comments I have made above are in the current 5.1 upgrade documentation. I have opened quite a few tickets requesting the documentation be improved and I guess that will happen slowly. For many people the points I have mentioned may seem irrelevant for their situation but for me they have caused a few problems. If you do not need to worry, then you can skip the documentation, otherwise if this were documented then you would be saved a few tears when least expecting problems.</p><br/>PlanetMySQL Voting:
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=23236&vote=1&apivote=1">Vote UP</a> /
	 <a href="http://planet.mysql.com/entry/vote/?entry_id=23236&vote=-1&apivote=1">Vote DOWN</a>]]></content:encoded>
			<wfw:commentRss>http://planetmysql.ru/2010/01/30/further-thoughts-on-mysql-upgrades/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

