<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Jeremy Cole</title>
	<atom:link href="http://blog.jcole.us/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.jcole.us</link>
	<description>Geek, electronics nerd, database nerd, father of three.</description>
	<lastBuildDate>Fri, 11 May 2012 09:06:03 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='blog.jcole.us' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Jeremy Cole</title>
		<link>http://blog.jcole.us</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://blog.jcole.us/osd.xml" title="Jeremy Cole" />
	<atom:link rel='hub' href='http://blog.jcole.us/?pushpress=hub'/>
		<item>
		<title>A brief update on NUMA and MySQL</title>
		<link>http://blog.jcole.us/2012/04/16/a-brief-update-on-numa-and-mysql/</link>
		<comments>http://blog.jcole.us/2012/04/16/a-brief-update-on-numa-and-mysql/#comments</comments>
		<pubDate>Mon, 16 Apr 2012 20:17:36 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[InnoDB]]></category>
		<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">http://blog.jcole.us/?p=763</guid>
		<description><![CDATA[Some time ago, I wrote a rather popular post The MySQL &#8220;swap insanity&#8221; problem and the effects of the NUMA architecture (if you haven&#8217;t read it, stop now and do that!), which described using numactl --interleave=all to balance memory allocation across nodes in a NUMA system. I should&#8217;ve titled it differently In reality, the problem [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=763&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Some time ago, I wrote a rather popular post <a href="http://blog.jcole.us/2010/09/28/mysql-swap-insanity-and-the-numa-architecture/">The MySQL &#8220;swap insanity&#8221; problem and the effects of the NUMA architecture</a> (if you haven&#8217;t read it, stop now and do that!), which described using <tt>numactl --interleave=all</tt> to balance memory allocation across nodes in a NUMA system.</p>
<h2>I should&#8217;ve titled it differently</h2>
<p>In reality, the problem posed by uneven allocation across nodes under NUMA is not entirely a <em>swapping problem</em>. I titled the previous post as it was and explained it in the way it was explained largely to address a specific problem seen in the MySQL community. However, the problem described actually has very little to do with swap itself. The problem is really related to Linux&#8217;s behavior under memory pressure, and specifically the pressure imposed by running a single NUMA node (and especially node 0) completely out of memory.</p>
<p>When swap is disabled completely, problems are <em>still</em> encountered, usually in the form of extremely slow performance and failed memory allocations.</p>
<h2>A more thorough solution</h2>
<p>The original post also only addressed only one part of the solution: using interleaved allocation. A complete and reliable solution actually requires three things, as we found when implementing this change for production systems at Twitter:</p>
<ol>
<li>Forcing interleaved allocation with <tt>numactl --interleave=all</tt>. This is exactly as described previously, and works well.</li>
<li>Flushing Linux&#8217;s buffer caches just before <tt>mysqld</tt> startup with <tt>sysctl -q -w vm.drop_caches=3</tt>. This helps to ensure allocation fairness, even if the daemon is restarted while significant amounts of data are in the operating system buffer cache.</li>
<li>Forcing the OS to allocate InnoDB&#8217;s buffer pool immediately upon startup, using <tt>MAP_POPULATE</tt> where supported (Linux 2.6.23+), and falling back to <tt>memset</tt> otherwise. This forces the NUMA node allocation decisions to be made immediately, while the buffer cache is still clean from the above flush.</li>
</ol>
<p>These changes are implemented in <a href="https://github.com/twitter/mysql">Twitter MySQL 5.5</a> as the <tt>mysqld_safe</tt> options <a href="https://github.com/twitter/mysql/commit/19cf63c596c0146a72583998d138190cc285df5c"><tt>numa-interleave</tt> and <tt>flush-caches</tt></a>, and <tt>mysqld</tt> option <a href="https://github.com/twitter/mysql/commit/76e70595e32dc30b1e8de7c3bf86e54cc9cea769"><tt>innodb_buffer_pool_populate</tt></a>, respectively.</p>
<h2>The results</h2>
<p>On a production machine with 144GB of RAM and a 120GB InnoDB buffer pool, all used memory has been allocated within 152 pages (0.00045%) of perfectly balanced across both NUMA nodes:</p>
<blockquote><pre>
N0        :     16870335 ( 64.36 GB)
N1        :     16870183 ( 64.35 GB)
active    :           81 (  0.00 GB)
anon      :     33739094 (128.70 GB)
dirty     :     33739094 (128.70 GB)
mapmax    :          221 (  0.00 GB)
mapped    :         1467 (  0.01 GB)
</pre>
</blockquote>
<p>The buffer pool itself was allocated within 4 pages of balanced (line-wrapped for clarity):</p>
<blockquote><pre>
2aaaab2db000 interleave=0-1 anon=33358486 dirty=33358486
  N0=16679245 N1=16679241
</pre>
</blockquote>
<p>Much more importantly, these systems have been extremely stable and have not experienced the &#8220;random&#8221; stalls under heavy load that we had seen before.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/763/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/763/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/763/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/763/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/763/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/763/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/763/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/763/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/763/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/763/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/763/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/763/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/763/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/763/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=763&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2012/04/16/a-brief-update-on-numa-and-mysql/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>
	</item>
		<item>
		<title>Twitter MySQL published</title>
		<link>http://blog.jcole.us/2012/04/09/twitter-mysql-published/</link>
		<comments>http://blog.jcole.us/2012/04/09/twitter-mysql-published/#comments</comments>
		<pubDate>Tue, 10 Apr 2012 00:33:24 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">http://blog.jcole.us/?p=757</guid>
		<description><![CDATA[It&#8217;s been a long time coming, but we&#8217;ve just published our Twitter-internal MySQL development branch onto GitHub. The initial publication and announcement isn&#8217;t meant to be groundbreaking&#8212;we&#8217;re setting up some groundwork to be able to collaborate publicly. It comes with an initial set of changes we&#8217;ve made to support our production workloads and make DBAs [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=757&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a long time coming, but <a href="http://engineering.twitter.com/2012/04/mysql-at-twitter.html">we&#8217;ve just published</a> our <a href="https://github.com/twitter/mysql">Twitter-internal MySQL development branch</a> onto <a href="http://github.com/">GitHub</a>. The initial publication and announcement isn&#8217;t meant to be groundbreaking&mdash;we&#8217;re setting up some groundwork to be able to collaborate publicly. It comes with an initial set of changes we&#8217;ve made to support our production workloads and make DBAs lives easier, which you can read about in the <a href="https://github.com/twitter/mysql/blob/master/README.md">README</a>.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/757/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/757/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/757/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/757/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/757/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/757/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/757/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/757/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/757/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/757/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/757/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/757/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/757/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/757/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=757&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2012/04/09/twitter-mysql-published/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>
	</item>
		<item>
		<title>Kiva: How to make a difference for 1,000 people with only $100 per month</title>
		<link>http://blog.jcole.us/2012/02/18/kiva-how-to-make-a-difference-for-1000-people-with-only-100-per-month/</link>
		<comments>http://blog.jcole.us/2012/02/18/kiva-how-to-make-a-difference-for-1000-people-with-only-100-per-month/#comments</comments>
		<pubDate>Sun, 19 Feb 2012 03:17:30 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://jcoledotus.wordpress.com/?p=743</guid>
		<description><![CDATA[Kiva (also see my lender page) is an amazing and deceptively simple idea: People, mostly in third world countries, need loans to buy food, crops, cows, equipment, education, etc. so they get a loan from a local Kiva partner, and those loans are backed by Kiva users in $25 increments. There is no interest paid [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=743&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.kiva.org/">Kiva</a> (also see my <a href="http://www.kiva.org/lender/jeremycole">lender page</a>) is an amazing and deceptively simple idea: People, mostly in third world countries, need loans to buy food, crops, cows, equipment, education, etc. so they get a loan from a local Kiva partner, and those loans are backed by Kiva users in $25 increments. There is no interest paid to Kiva users, (although the local partners do charge some interest), so it&#8217;s not really an investment per se. </p>
<p>I&#8217;ve been a user of Kiva for a more than five years now, and have made 350 loans so far for a total of $9,400 loaned. In the first few years I only sporadically made some loans and let repaid money sit around for a long time. In the past couple of years I&#8217;ve been using Kiva more consistently, every month re-investing the full repayment amounts as soon as they come in, and usually adding 4-6 loans ($100-$150) of new money.</p>
<p>As I&#8217;ve been doing this I noticed an effect that makes perfect sense but I hadn&#8217;t considered before: Since the loans are anywhere from 9-24 months, but the repaid amounts are repaid typically monthly, if the repaid amounts are re-invested immediately, the original loan amounts stack on top of each other, allowing the same money to be invested several times over simultaneously.</p>
<p>Recently I&#8217;ve been thinking about actually quantifying that effect and figuring out what impact it could have. Since it&#8217;s not a very simple calculation, I put together a spreadsheet to calculate the full picture for me.</p>
<h2>Assumptions</h2>
<p>The following assumptions are made:</p>
<ul>
<li><strong>Amount per loan: $25.00</strong> &mdash; This is the standard loan amount on Kiva, so this just assumes you never double up on a single loan (which is not a good idea as it spreads the loss risk poorly).</li>
<li><strong>Investment per month: 4 loans, or $100</strong> (and reinvest all repayments) &mdash; This is approximately what I&#8217;ve been doing, although frequently it&#8217;s a bit more than 4.</li>
<li><strong>Average loan duration: 15 months</strong> &mdash; This is the average loan duration for my loan portfolio, and seems about average for Kiva.</li>
<li><strong>Loss rate: 2.07%</strong> &mdash; This is the actual loss rate of my portfolio, which is a bit higher than the average Kiva user at 1.09% because I tend to loan to war-torn and riskier areas.</li>
</ul>
<h2>Results</h2>
<p>After 5 years (60 months) of consistent and prompt investment, the results could be:</p>
<ul>
<li><strong>Total investment: $6,000</strong> &mdash; This is the actual amount you&#8217;ve paid out of pocket.</li>
<li><strong>Total loans made: 1,004</strong> &mdash; The number of individuals or groups helped. This is the most amazing thing, watching all of these individuals succeed due to your help.</li>
<li><strong>Total amount loaned: $25,100</strong> &mdash; The amount your $6,000 turns into after re-investment through immediate re-loaning.</li>
<li><strong>Total amount lost: $519.57</strong> &mdash; Due to a combination of loan defaults and currency exchange loss, not all of your money will be returned.</li>
<li><strong>Total amount returned: $5480.43</strong> &mdash; If you stopped making loans after the 60 months and started to withdraw your money from Kiva, at the end of it you&#8217;d get this much back (investment minus loss).</li>
</ul>
<p>Check out the <a href="https://docs.google.com/spreadsheet/ccc?key=0Ak69OGWTdlptdDhmYnFUbXk5Zmx6QnJScXFRV2lHZ3c">full calculator on Google Docs</a> for all the details and per-month amounts.</p>
<h2>Conclusion</h2>
<p>The really amazing thing with following this plan is that the Kiva borrowers themselves end up&mdash;through prompt repayment of their loans&mdash;funding each other. For me, the amount being invested each month is quite modest, and through reinvestment of the repayments, the monthly impact is huge. This month, I received almost $400 in repayments, added an additional $100, and made $500 in new loans.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/743/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/743/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/743/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/743/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/743/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/743/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/743/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/743/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/743/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/743/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/743/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/743/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/743/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/743/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=743&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2012/02/18/kiva-how-to-make-a-difference-for-1000-people-with-only-100-per-month/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>
	</item>
		<item>
		<title>Vector: A new way to think about replication performance and slave lag</title>
		<link>http://blog.jcole.us/2011/12/29/vector-a-new-way-to-think-about-replication-performance-and-slave-lag/</link>
		<comments>http://blog.jcole.us/2011/12/29/vector-a-new-way-to-think-about-replication-performance-and-slave-lag/#comments</comments>
		<pubDate>Fri, 30 Dec 2011 03:35:10 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">https://jcoledotus.wordpress.com/?p=692</guid>
		<description><![CDATA[Background I have been considering a new way to think about, measure, graph, and monitor replication lag for a while. Previously I&#8217;ve always been primarily been using replication delay (lag), in seconds. Initially this came from SHOW SLAVE STATUS&#8216;s Seconds_Behind_Master field, later replaced by mk-heartbeat&#8216;s delay information. (These are equivalent, but mk-heartbeat is less buggy [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=692&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h2>Background</h2>
<p>I have been considering a new way to think about, measure, graph, and monitor replication lag for a while. Previously I&#8217;ve always been primarily been using replication delay (lag), in seconds. Initially this came from <tt>SHOW SLAVE STATUS</tt>&#8216;s <tt>Seconds_Behind_Master</tt> field, later replaced by <tt>mk-heartbeat</tt>&#8216;s delay information. (These are equivalent, but <tt>mk-heartbeat</tt> is less buggy and works to represent true lag with relay slaves in the replication topology.) Using delay in seconds to monitor replication has a few problems though:</p>
<ul>
<li>The current number of seconds delayed provides no information about how long it might take to catch up.</li>
<li>It&#8217;s very difficult to determine whether a slave is catching up at all, due to the scale. If a slave is a few thousand seconds behind it&#8217;s hard to tell whether it&#8217;s catching up, falling behind, or neither, at any particular moment.</li>
<li>If multiple slaves are graphed together, they may have widely different absolute delay values, and thus scales, and it can be very difficult to compare them, or to see that a slave is having problems, until it&#8217;s too late. Two slaves may be falling behind at the same rate, but if one is 300 seconds behind, and one is 20,000 seconds behind, the graphs are difficult to interpret.</li>
</ul>
<p>Given these problems, I determined that while we need the absolute <em>delay</em> information available, it&#8217;s not good enough by itself. I started to think about what it is that I&#8217;m really trying to determine when looking at the delay graphs.</p>
<h2>Vector: Velocity <em>and</em> direction</h2>
<p>The key bits of information missing from the delay information seem to be:</p>
<ul>
<li>Is the slave falling behind, catching up, or neither? We need a measure of the <strong>direction</strong> of replication&#8217;s delay.</li>
<li>How <em>fast</em> is the slave falling behind or catching up? We need a measure of <strong>velocity</strong> of replication&#8217;s performance</li>
</ul>
<p>Fortunately these two things can be combined together into a single number representing the <strong>vector</strong> of replication. This can then be presented to the user (likely a DBA) in an easy to consume format. The graphs can be read as follows:</p>
<ul>
<li><strong><em>Y = 0</em></strong> means the slave is neither catching up nor falling behind. It is replicating <em>in real time</em>. I chose zero for this state in order to make the other two states a bit more meaningful and to make the graph symmetric by default.</li>
<li><strong><em>Y &gt; 0</em></strong> means the slave is catching up at Y <em>seconds per second</em>. There is no maximum rate a slave can catch up, but in practice seeing velocities &gt;1 for extended periods is relatively uncommon in already busy systems.</li>
<li><strong><em>Y &lt; 0</em></strong> means the slave is falling behind at Y <em>seconds per second</em>. As a special case, <em>Y = -1</em> means that the slave is completely stopped and playing no events. Lagging is a function of the passage of time, so it is not possible to lag faster than one second per second.</li>
</ul>
<p>I like the symmetry of having the zero line be the center point, and having healthy hosts idle with a flat line at zero. Lag appears in the form of a meander away from zero into the negative, matched by an always equal-area<sup>1</sup> (but not necessarily similarly shaped) correction into the positive. In practice the Y-scale of graphs is <strong>fixed</strong> at <tt>[-1, +1]</tt> and the graphs are very easy and quick to interpret.</p>
<h3>Example 1</h3>
<p>Most slaves are replicating real time; one slave fell behind for some time before catching up again.</p>
<p><img src="http://jcole.us/blog/files/vector_example_1_vector.png"><br />
<em><strong>Vector</strong> &#8211; A few small perturbations can be seen, and one slave replicated at less than real time time for many hours, before finally crossing over zero and catching up at an increasing rate until current time was reached.</em></p>
<p><img src="http://jcole.us/blog/files/vector_example_1_delay.png"><br />
<em><strong>Delay</strong> &#8211; The small perturbations are difficult to see due to the scale imposed by the one very delayed slave. Although it&#8217;s easy to see on a day view that the slave did catch up quickly, that is less obvious when monitoring in real time.</em></p>
<h3>Example 2</h3>
<p>Many slaves with different replication rates, and a lot of trouble.</p>
<p><img src="http://jcole.us/blog/files/vector_example_2_vector.png"><br />
<em><strong>Vector</strong> &#8211; Overall replication performance is quite poor, and shows evidence of being unlikely to catch up to current time or maintain real time replication in the future.</em></p>
<p><img src="http://jcole.us/blog/files/vector_example_2_delay.png"><br />
<em><strong>Delay</strong> &#8211; It&#8217;s difficult to know if things are getting better or worse. The replication performance of each host is almost impossible to compare.</em></p>
<h2>Implementation</h2>
<p>In basic terms, the number of seconds of replication stream applied per second of real time, should be measured frequently, and with reasonably good precision. I have <tt>mk-heartbeat</tt> writing heartbeat events into a <tt>heartbeat</tt> table once a second on the master (which has an NTP-synchronized clock), providing a ready source of the progression of &#8220;replicated heartbeat time&#8221;<sup>2</sup> (<tt>htime</tt>) to the slaves. The slaves of course have their own NTP-synchronized clocks providing a source of local &#8220;clock time&#8221; (<tt>ctime</tt>). Both of these are collected on each slave once a minute, as integers (Unix epoch timestamps). Both the current sample (subscript <tt>c</tt>) and the previous successful sample (subscript <tt>p</tt>) are available to the processing program. The vector is calculated, stored, and sent off to be graphed once per minute. </p>
<p><!-- vector = \begin{pmatrix}\frac{htime_{c} - htime_{p}}{ctime_{c} - ctime_{p}}\end{pmatrix} - 1 --><img src="http://jcole.us/blog/files/vector_formula.png"></p>
<p>The implementation is actually quite simple, and tolerant of almost any sampling interval. In the future it could be extended to use millisecond resolution (although it can never be any higher resolution than the frequency the heartbeat is updated).</p>
<p><sup>1</sup> This is kind of an interesting point. Since the graph is nicely centered on zero, negative numbers represent the exact same scale as positive numbers, on the same dimensions.</p>
<p><sup>2</sup> <tt>SELECT UNIX_TIMESTAMP(ts) AS ts FROM heartbeat WHERE id = 1</tt></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/692/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/692/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/692/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/692/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/692/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/692/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/692/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/692/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/692/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/692/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/692/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/692/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/692/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/692/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=692&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2011/12/29/vector-a-new-way-to-think-about-replication-performance-and-slave-lag/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>

		<media:content url="http://jcole.us/blog/files/vector_example_1_vector.png" medium="image" />

		<media:content url="http://jcole.us/blog/files/vector_example_1_delay.png" medium="image" />

		<media:content url="http://jcole.us/blog/files/vector_example_2_vector.png" medium="image" />

		<media:content url="http://jcole.us/blog/files/vector_example_2_delay.png" medium="image" />

		<media:content url="http://jcole.us/blog/files/vector_formula.png" medium="image" />
	</item>
		<item>
		<title>Migrating to WordPress.com hosting</title>
		<link>http://blog.jcole.us/2011/12/29/migrating-to-wordpress-com-hosting/</link>
		<comments>http://blog.jcole.us/2011/12/29/migrating-to-wordpress-com-hosting/#comments</comments>
		<pubDate>Fri, 30 Dec 2011 02:42:07 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://blog.jcole.us/?p=686</guid>
		<description><![CDATA[As I get older I realize how much I don&#8217;t want my personal life to feel like my work life. I&#8217;ve been running my own WordPress.org installation for years, and it&#8217;s been easy and not really a problem. However it does also mean maintaining Linux, Apache, PHP, and other supporting infrastructure, and keeping things updated [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=686&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>As I get older I realize how much I don&#8217;t want my personal life to feel like my work life. I&#8217;ve been running my own <a href="http://wordpress.org/">WordPress.org</a> installation for years, and it&#8217;s been easy and not really a problem. However it does also mean maintaining Linux, Apache, PHP, and other supporting infrastructure, and keeping things updated and upgraded all the time. My usage of WordPress is remarkably simplistic, so I really don&#8217;t need to do all of that. I decided to migrate to a paid <a href="http://wordpress.com/">WordPress.com</a> hosted account instead.</p>
<p>As part of this migration I also changed the URL structure a bit, to match WordPress.com&#8217;s directory structure and make things simpler (and easier to move in the future if I want to). There is a mod_rewrite redirector in place to keep the old URLs working forever. (I hope.) The changes are:</p>
<ul>
<li>Moving from <tt>jcole.us/blog</tt> to <tt>blog.jcole.us</tt>.</li>
<li>Removing <tt>archives/</tt> from the permalink path structure.</li>
<li>Simplifying the theme a bit. It&#8217;s pretty generic right now, but I&#8217;ll fix it up some more in the future.</li>
</ul>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/686/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/686/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/686/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/686/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/686/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/686/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/686/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/686/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/686/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/686/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/686/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/686/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/686/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/686/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=686&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2011/12/29/migrating-to-wordpress-com-hosting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>
	</item>
		<item>
		<title>January 2011 MySQL Meetup: Clustrix</title>
		<link>http://blog.jcole.us/2011/01/08/january-2011-mysql-meetup-clustrix/</link>
		<comments>http://blog.jcole.us/2011/01/08/january-2011-mysql-meetup-clustrix/#comments</comments>
		<pubDate>Sun, 09 Jan 2011 02:16:22 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[MySQL Meetup]]></category>

		<guid isPermaLink="false">http://jcole.us/blog/?p=683</guid>
		<description><![CDATA[Clustrix will be presenting at this month&#8217;s Silicon Valley MySQL Meetup in Sunnyvale, CA. Stop by if you can! Paul Mikesell (CEO and VP Engineering) and Aaron Passey (CTO) will be discussing the unique architecture behind Clustrix’s massively scalable, distributed, MySQL-compatible database solution. They will talk about how the company has addressed the common challenges [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=683&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.clustrix.com/">Clustrix</a> will be presenting at this <a href="http://www.meetup.com/mysql-silicon-valley/calendar/15276732/">month&#8217;s Silicon Valley MySQL Meetup</a> in Sunnyvale, CA.  Stop by if you can!</p>
<p><a href="http://www.clustrix.com/"><img src="http://jcoledotus.files.wordpress.com/2011/12/meetup-clustrix-logo.jpg?w=450" /></a></p>
<p>Paul Mikesell (CEO and VP Engineering) and Aaron Passey (CTO) will be discussing the unique architecture behind Clustrix’s massively scalable, distributed, MySQL-compatible database solution. They will talk about how the company has addressed the common challenges associated with achieving massive scale for transactional (OLTP) relational workloads.</p>
<p>Prior to developing the Clustrix solution over the past four years, Paul was co-founder of Isilon Systems, just acquired by EMC in December 2010 for $2.25B and still has the largest clustering capability (&gt;120 nodes) of any NAS solution.</p>
<p><a href="http://www.meetup.com/mysql-silicon-valley/calendar/15276732/">Read more and RSVP on Meetup.com!</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/683/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/683/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/683/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/683/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/683/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/683/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/683/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/683/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/683/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/683/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/683/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/683/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/683/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/683/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=683&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2011/01/08/january-2011-mysql-meetup-clustrix/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>

		<media:content url="http://jcoledotus.files.wordpress.com/2011/12/meetup-clustrix-logo.jpg" medium="image" />
	</item>
		<item>
		<title>InnoDB online index add and &#8220;The table &#8216;t&#8217; is full&#8221; error</title>
		<link>http://blog.jcole.us/2011/01/05/innodb-online-index-add-and-the-table-t-is-full-error/</link>
		<comments>http://blog.jcole.us/2011/01/05/innodb-online-index-add-and-the-table-t-is-full-error/#comments</comments>
		<pubDate>Wed, 05 Jan 2011 18:46:24 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[InnoDB]]></category>
		<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">http://jcole.us/blog/?p=677</guid>
		<description><![CDATA[While trying to add an index to a fairly large table today, on a server1 I&#8217;d not worked on previously, I got the following error after some time (and while I was away from the computer): mysql&#62; ALTER TABLE t -&#62; ADD KEY `index_a` (`a`), -&#62; ADD KEY `index_b` (`b`), -&#62; ADD KEY `index_c` (`c`); [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=677&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>While trying to add an index to a fairly large table today, on a server<sup>1</sup> I&#8217;d not worked on previously, I got the following error after some time (and while I was away from the computer):</p>
<blockquote><pre>
mysql&gt; ALTER TABLE t
    -&gt;   ADD KEY `index_a` (`a`),
    -&gt;   ADD KEY `index_b` (`b`),
    -&gt;   ADD KEY `index_c` (`c`);
ERROR 1114 (HY000): The table 't' is full
</pre>
</blockquote>
<p>The error log did not bring particular enlightenment (as usual, InnoDB is extremely verbose with the logs, without saying anything useful):</p>
<blockquote><pre>
110105 16:22:30  InnoDB: Error: Write to file (merge) failed at offset 4 1387266048.
InnoDB: 1048576 bytes should have been written, only 888832 were written.
InnoDB: Operating system error number 0.
InnoDB: Check that your OS and file system support files of this size.
InnoDB: Check also that the disk is not full or a disk quota exceeded.
InnoDB: Error number 0 means 'Success'.
InnoDB: Some operating system error numbers are described at
InnoDB: http://dev.mysql.com/doc/refman/5.1/en/operating-system-error-codes.html
110105 16:23:00 [ERROR] /usr/sbin/mysqld: The table 't' is full
</pre>
</blockquote>
<p>I had to re-run the command while keeping a close eye on things, and I discovered that it was writing significant amounts of data to the root file system (which isn&#8217;t very big, as usual). I looked in all the usual places, and didn&#8217;t see any files of note.  However, on a hunch, I checked out <tt>/proc/&lt;pid&gt;/fd</tt> (which can be a lifesaver).  I found these:</p>
<blockquote><pre>
# ls -l /proc/`pidof mysqld`/fd | grep deleted
lrwx------ 1 root root 64 Jan  5 17:33 14 -&gt; /var/tmp/ibEnEaSj (deleted)
lrwx------ 1 root root 64 Jan  5 17:33 5 -&gt; /var/tmp/ibEoZHQc (deleted)
lrwx------ 1 root root 64 Jan  5 17:33 6 -&gt; /var/tmp/ibHlWZb3 (deleted)
lrwx------ 1 root root 64 Jan  5 17:33 7 -&gt; /var/tmp/ibUtVhxT (deleted)
lrwx------ 1 root root 64 Jan  5 17:33 8 -&gt; /var/tmp/ibt1daDR (deleted)
</pre>
</blockquote>
<p>I can only assume it&#8217;s one of these files that&#8217;s growing.  Changing the setting of <tt>tmpdir</tt> fixed things up, and it&#8217;s writing its large data files to a place with significant space now (and on a much bigger and faster RAID array, to boot).  However, this brings with it a couple of questions:</p>
<ol>
<li>Why does InnoDB need significant space in <tt>tmpdir</tt>? This is a new requirement with InnoDB plugin (due to online index addition only?), but I don&#8217;t see it documented anywhere.<sup>2</sup></li>
<li>Why are the files deleted while in use? This makes it very painful for a DBA to manage it and see what&#8217;s using space. I know it&#8217;s a typical Unix paradigm, but cleanup-on-start and leaving the files linked is much easier to manage.</li>
<li>Why are the error messages useless? How else is a DBA supposed to track this down?</li>
</ol>
<p>I could also note that using online index add makes useless the only previous way of getting some sort of a status update while adding indexes: watching the temporary file grow. Perhaps it&#8217;s time to bring back my <a href="http://jcole.us/patches/mysql/5.0/progress_rows_percent.patch">patch to show progress</a> (<a href="http://bugs.mysql.com/bug.php?id=26182">MySQL Bug #26182</a>)?</p>
<p><sup>1</sup> Running <tt>MySQL-server-percona-5.1.42-9.rhel5</tt> with <tt>innodb_version</tt> = 1.0.6-9.</p>
<p><sup>2</sup> Perhaps it should go on <a href="http://dev.mysql.com/doc/innodb-plugin/1.0/en/innodb-create-index-limitations.html">Fast Index Creation in the InnoDB Storage Engine: Limitations</a> at very least?</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/677/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/677/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/677/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/677/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/677/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/677/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/677/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/677/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/677/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/677/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/677/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/677/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/677/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/677/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=677&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2011/01/05/innodb-online-index-add-and-the-table-t-is-full-error/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>
	</item>
		<item>
		<title>Are we really living in the 1700s?</title>
		<link>http://blog.jcole.us/2011/01/02/are-we-really-living-in-the-1700s/</link>
		<comments>http://blog.jcole.us/2011/01/02/are-we-really-living-in-the-1700s/#comments</comments>
		<pubDate>Mon, 03 Jan 2011 03:29:28 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://jcole.us/blog/?p=667</guid>
		<description><![CDATA[I stumbled upon an interesting theory today, which I hadn&#8217;t heard of or researched before: a supposition that the Dark Ages was not dark merely because there was so little political, cultural, archeological, scientific, etc. advancements, but rather that it&#8217;s because a period of approximately 300 years (AD 614-911) of the dark ages didn&#8217;t exist [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=667&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I stumbled upon an interesting theory today, which I hadn&#8217;t heard of or researched before: a supposition that the <a href="http://en.wikipedia.org/wiki/Dark_Ages">Dark Ages</a> was not dark merely because there was so little political, cultural, archeological, scientific, etc. advancements, but rather that it&#8217;s because a period of approximately 300 years (AD 614-911) of the dark ages <em>didn&#8217;t exist at all</em>: A theory titled the <a href="http://en.wikipedia.org/wiki/Phantom_time_hypothesis">Phantom time hypothesis</a>.</p>
<p>A paper <a href="http://www.cl.cam.ac.uk/~mgk25/volatile/Niemitz-1997.pdf">Did the Early Middle Ages Really Exist?</a> by Dr. Hans-Ulrich Niemitz, lays out the theory (much of it originated from Heribert Illig in the early 1990s). An interesting <a href="http://www.korthweb.de/PhZT/FAQ_E.html">FAQ</a> written by Jan Beaufort rounds out some the questions.  A summary and a few more bits of insight are <a href="http://lelarge.de/wamse.html">provided by Gunnar Ries and Ruth Lelarge</a>.  The topic is also covered by a <a href="http://www.damninteresting.com/the-phantom-time-hypothesis">DamnInteresting post</a> and thread of comments&mdash;some comical and some insightful. Of course any such theory is not without a lot of criticism and counterpoints, as it should have, and Phil John Kneis <a href="http://www.philjohn.com/papers/pjkd_h04.html">counters a lot of things nicely</a>. I found the story of <a href="http://en.wikipedia.org/wiki/Seven_Sleepers">The Seven Sleepers of Ephesus</a> as a potential link to possible truth of this story; not that the Seven Sleepers story was at all truth, but that in that time stories (fictions) were made up to relate truths or partial truths quite frequently.</p>
<p>Some of the claims made, often based at least tangentially on well-known reasons for having called them the &#8220;Dark Ages&#8221; in the first place (and in many cases refuted by others) are:</p>
<ul>
<li>Overall lack of reputable, accurately dated literature and historical documents from the time period.</li>
<li>Much of the otherwise supporting evidence in support of the time period depending on Carbon-14 dating, which has had adjustments made in order to line up with perceived history, and which has been calibrated based on dendrochronology (tree-ring dating) which has had known flaws.</li>
<li>Architectural development discontinuities; the seemingly complete stoppage of forward progress in architectural style for 300 years, with buildings known to be constructed after the Dark Ages (based on calibration backwards from modern times) compared to buildings known to be constructed before them (based on calibration forwards from ancient times) showing little or no difference.</li>
<li>Farming, war, and scientific knowledge making practically no advancement during the period.</li>
<li>A huge spate of forgery of official documents and religious texts otherwise before, during, and after the time period.</li>
</ul>
<p>It&#8217;s not easy to believe one way or the other, but I personally find it not that hard to believe that three hundred years may have been accidentally or intentionally inserted into the calendar for whatever reason.  Remember that calendars are man-invented tools, not scientific absolutes, and particularly the points of reference used in them are almost entirely arbitrary.  It wouldn&#8217;t change our daily lives<sup>1</sup> in any way if the actual number of years having passed since the Roman empire was closer to 1700 than 2000.  We&#8217;ve made a lot of adjustments to the calendar, and even switched points of reference and entire ways of counting several times during man&#8217;s history.  Even today, not everyone uses the same calendar or agrees on the calendar.<sup>2</sup></p>
<p>It&#8217;s easy to misinterpret the meaning of &#8220;missing years&#8221;, and it seems like many comment authors on the various articles have made the mistake of thinking that Illig and Niemitz are suggesting that the <em>years themselves didn&#8217;t exist</em>, which of course is nonsense. The only claim being made is that three centuries of already-sketchy history may have just been fabricated entirely, an offset to the calendar was introduced intentionally or not, and as a result of that, we&#8217;ve been mis-numbering years for the 1100 years following that.</p>
<p>If true, there would be no need to correct the current calendar date, just to note in history books, elapsed-time calculations involving the past and including those years, and other places that there is a gap.  There are already other gaps in the Gregorian calendar, this would just be the largest.</p>
<p>What do you think?  Do you find it plausible? Should I be signing this post January 2, 1714? If true, I guess that gives us an extra 298 years before we the <a href="http://en.wikipedia.org/wiki/2012_phenomenon">Mayan-predicted end-times in 2012</a>, so that&#8217;s a bonus!</p>
<p><sup>1</sup> With the possible exception that some churches, and some acts of various churches, may be on slightly shakier footings, especially if it could be proven that they had been maliciously involved in the fabrication of the calendar.</p>
<p><sup>2</sup> See Wikipedia&#8217;s <a href="http://en.wikipedia.org/wiki/List_of_calendars">List of calendars</a> and <a href="http://en.wikipedia.org/wiki/Calendar">Calendar</a> pages for a few points of study. In addition to our <a href="http://en.wikipedia.org/wiki/Gregorian_calendar">Gregorian</a> calendar, at least the <a href="http://en.wikipedia.org/wiki/Hebrew_calendar">Hebrew</a> and <a href="http://en.wikipedia.org/wiki/Chinese_calendar">Chinese</a> calendars are still in widespread use.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/667/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/667/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/667/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/667/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/667/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/667/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/667/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/667/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/667/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/667/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/667/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/667/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/667/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/667/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=667&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2011/01/02/are-we-really-living-in-the-1700s/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>
	</item>
		<item>
		<title>Now a Database Architect at Twitter</title>
		<link>http://blog.jcole.us/2010/11/15/now-a-database-architect-at-twitter/</link>
		<comments>http://blog.jcole.us/2010/11/15/now-a-database-architect-at-twitter/#comments</comments>
		<pubDate>Tue, 16 Nov 2010 04:44:46 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[Commuting]]></category>
		<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">http://jcole.us/blog/?p=647</guid>
		<description><![CDATA[Just a small announcement: Starting today, I am now &#8220;MySQL Database Architect&#8221; at Twitter, where I am joining some old friends on the small but hard-working DBA and operations teams there. I&#8217;ll be working to help debug, support, and scale the MySQL databases, of course, and who knows what else. I&#8217;m looking forward to the [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=647&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Just a small announcement:</p>
<p><a href="http://twitter.com/"><img src="http://jcole.us/blog/files/twitter-logo.png" width="333" height="62" /></a></p>
<p>Starting today, I am now &#8220;MySQL Database Architect&#8221; at <a href="http://twitter.com/">Twitter</a>, where I am joining some old friends on the small but hard-working DBA and operations teams there. I&#8217;ll be working to help debug, support, and scale the MySQL databases, of course, and who knows what else. I&#8217;m looking forward to the challenges and fast paced operations again. I&#8217;m also looking forward to writing a lot more on this blog about MySQL. I&#8217;ve had a Twitter account for a long time, but I suppose I&#8217;ll write a lot more on it now:</p>
<p><a href="http://twitter.com/jeremycole"><img src="http://jcole.us/blog/files/twitter-follow-me.png" /></a></p>
<p>Since I will now be commuting from <a href="http://maps.google.com/maps?q=monterey%20terrace,%20sunnyvale,%20ca%20to%20795%20folsom%20st.,%20san%20francisco,%20ca">Sunnyvale to San Francisco</a> nearly daily, I think my old &#8220;<a href="http://jcole.us/blog/archives/category/commuting/">Commuting</a>&#8221; category will get more of a work-out too.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/647/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/647/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/647/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/647/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/647/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/647/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/647/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/647/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/647/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/647/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/647/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/647/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/647/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/647/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=647&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2010/11/15/now-a-database-architect-at-twitter/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>

		<media:content url="http://jcole.us/blog/files/twitter-logo.png" medium="image" />

		<media:content url="http://jcole.us/blog/files/twitter-follow-me.png" medium="image" />
	</item>
		<item>
		<title>On early MySQL development hostnames</title>
		<link>http://blog.jcole.us/2010/10/12/on-early-mysql-development-hostnames/</link>
		<comments>http://blog.jcole.us/2010/10/12/on-early-mysql-development-hostnames/#comments</comments>
		<pubDate>Tue, 12 Oct 2010 22:03:24 +0000</pubDate>
		<dc:creator>Jeremy Cole</dc:creator>
				<category><![CDATA[InnoDB]]></category>
		<category><![CDATA[MySQL]]></category>

		<guid isPermaLink="false">http://jcole.us/blog/?p=637</guid>
		<description><![CDATA[While reading through the manual I ran across something I had totally forgotten about from the early MySQL days. Early on, Monty (or was it Jani?) decided to name many development servers variants of &#8220;bitch&#8221; in different languages. I have no idea what the back-story was, but maybe Monty or Jani can fill it in. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=637&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>While reading through the manual I ran across something I had totally forgotten about from the early MySQL days. Early on, Monty (or was it Jani?) decided to name many development servers variants of &#8220;bitch&#8221; in different languages.  I have no idea what the back-story was, but maybe Monty or Jani can fill it in.  All of these names live on all over the place, such as in the MySQL and InnoDB documentation, bug reports, and mailing list messages.  See:</p>
<ul>
<li><strong>bitch.mysql.fi</strong> &mdash; English, of course.</li>
<li><strong>hundin.mysql.fi</strong> &mdash; <a href="http://translate.google.com/#de|en|h%C3%BCndin">German</a></li>
<li><strong>hynda.mysql.fi</strong> &mdash; <a href="http://translate.google.com/#sv|en|hynda">Swedish</a></li>
<li><strong>narttu.mysql.fi</strong> &mdash; <a href="http://translate.google.com/#fi|en|narttu">Finnish</a></li>
<li><strong>tik.mysql.fi</strong> &mdash; <a href="http://translate.google.com/#sv|en|tik">Swedish</a></li>
<li><strong>tramp.mysql.fi</strong> &mdash; English, probably.  Similar in meaning to some slang uses of &#8220;bitch&#8221;.</li>
</ul>
<p>There are a few honorable mentions, which I&#8217;m not sure are variants of &#8220;bitch&#8221;, but very well could be:</p>
<ul>
<li><strong>donna.mysql.fi</strong></li>
<li><strong>mashka.mysql.fi</strong></li>
<li><strong>mishka.mysql.fi</strong></li>
</ul>
<p>It&#8217;s funny to see how those names live on in &#8220;infamy&#8221; on Google. Try searching for any of them like &#8220;<a href="http://www.google.com/search?q=%2Bmysql+%2Bhundin">+mysql +hundin</a>&#8220;.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jcoledotus.wordpress.com/637/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jcoledotus.wordpress.com/637/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jcoledotus.wordpress.com/637/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jcoledotus.wordpress.com/637/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jcoledotus.wordpress.com/637/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jcoledotus.wordpress.com/637/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jcoledotus.wordpress.com/637/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jcoledotus.wordpress.com/637/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jcoledotus.wordpress.com/637/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jcoledotus.wordpress.com/637/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jcoledotus.wordpress.com/637/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jcoledotus.wordpress.com/637/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jcoledotus.wordpress.com/637/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jcoledotus.wordpress.com/637/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.jcole.us&#038;blog=30683698&#038;post=637&#038;subd=jcoledotus&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://blog.jcole.us/2010/10/12/on-early-mysql-development-hostnames/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/37cd63a9fd0344804fd6a991a55c283a?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=R" medium="image">
			<media:title type="html">jeremycole</media:title>
		</media:content>
	</item>
	</channel>
</rss>
