<?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>mm &#187; Trash Talking</title>
	<atom:link href="http://markmaunder.com/category/trash-talking/feed/" rel="self" type="application/rss+xml" />
	<link>http://markmaunder.com</link>
	<description></description>
	<lastBuildDate>Fri, 30 Jul 2010 05:56:49 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>How to handle 1000&#8217;s of concurrent users on a 360MB VPS</title>
		<link>http://markmaunder.com/2009/how-to-handle-1000s-of-concurrent-users-on-a-360mb-vps/</link>
		<comments>http://markmaunder.com/2009/how-to-handle-1000s-of-concurrent-users-on-a-360mb-vps/#comments</comments>
		<pubDate>Tue, 01 Dec 2009 20:18:17 +0000</pubDate>
		<dc:creator>mark</dc:creator>
				<category><![CDATA[Scaling]]></category>
		<category><![CDATA[Startups]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Trash Talking]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[bitchin]]></category>
		<category><![CDATA[epoll]]></category>
		<category><![CDATA[nginx]]></category>
		<category><![CDATA[performance]]></category>

		<guid isPermaLink="false">http://markmaunder.com/?p=430</guid>
		<description><![CDATA[There has been some recent confusion about how much memory you need in a web server to handle a huge number of concurrent requests. I also made a performance claim on the STS list that got me an unusual number of private emails.
Here&#8217;s how you run a highly concurrent website on a shoe-string budget:
The first thing you&#8217;ll do is get a Linode server because they have the fastest CPU and disk.
Install Apache with your web application running under mod_php, mod_perl ...]]></description>
			<content:encoded><![CDATA[<p>There has been some recent <a href="http://plasticboy.com/archives/2009/11/30/memory-will-be-the-real-performance-bottleneck-on-your-vps/">confusion</a> about<a href="http://groups.google.com/group/seattletechstartups/msg/0105112902829547?hl=en"> </a>how much memory you need in a web server to handle a huge number of concurrent requests. I also <a href="http://groups.google.com/group/seattletechstartups/msg/312e381dbc811271?hl=en">made a performance claim on the STS list</a> that got me an unusual number of private emails.</p>
<p>Here&#8217;s how you run a highly concurrent website on a shoe-string budget:</p>
<p>The first thing you&#8217;ll do is <a href="http://linode.com/">get a Linode server</a> because <a href="http://journal.uggedal.com/vps-performance-comparison">they have the fastest CPU and disk</a>.</p>
<p>Install Apache with your web application running under mod_php, mod_perl or some other persistence engine for your language. Then you get famous and start getting emails about people not being able to access your website.</p>
<p>You increase the number of Apache threads or processes (depending on which Apache MPM you&#8217;re using) until you can&#8217;t anymore because you only have 360MB of memory in your server.</p>
<p>Then you&#8217;ll lower the KeepaliveTimeout and eventually disable Keepalive so that more users can access your website without tying up your Apache processes. Your users will slow down a little because they now have to re-establish a new connection for every piece of your website they want to fetch, but you&#8217;ll be able to serve more of them.</p>
<p>But as you scale up you will get a few more emails about your server being down. Even though  you&#8217;ve disabled keepalive it still takes time for each Apache child to send data to users, especially if they&#8217;re on slow connections or connections with high latency. Here&#8217;s what you do next:</p>
<p>Install <a href="http://nginx.net/">Nginx</a> on your new Linode box and get it to listen on Port 80. Then reconfigure Apache so that it listens on another port &#8211; say port 81 &#8211; and can only be accessed from the local machine. <a href="http://wiki.nginx.org/NginxHttpProxyModule">Configure Nginx as a reverse proxy</a> to Apache listening on port 81 so that it sits in front of Apache like so:</p>
<p>YourVisitor &lt;&#8212;&#8211;&gt; Nginx:Port80 &lt;&#8212;&#8211;&gt; Apache:Port81</p>
<p>Enable Keepalive on Nginx and set the Keepalive timeout as high as you&#8217;d like. Disable Keepalive on Apache &#8211; this is just-in-case because Nginx&#8217;s proxy engine doesn&#8217;t support Keepalive to the back-end servers anyway.</p>
<p>The 10 or so Apache children you&#8217;re running will be getting requests from a client (Nginx) that is running locally. Because there is zero latency and a huge amount of bandwidth (it&#8217;s a loopback request), the only time Apache takes to handle the request is the amount of CPU time it actually takes to handle the request. Apache children are no longer tied up with clients on slow connections. So each request is handled in a few microseconds, freeing up each child to do a hell of a lot more work.</p>
<p>Nginx will occupy about 5 to 10 Megs of Memory. You&#8217;ll see thousands of users concurrently connected to it. If you have Munin loaded on your server check out the netstat graph. Bitchin isn&#8217;t it? You&#8217;ll also notice that Nginx uses very little CPU &#8211; almost nothing in fact. That&#8217;s because Nginx is designed using a single threaded model where one thread handles a huge number of connections. It can do this with little CPU usage because it uses a feature in the Linux kernel called epoll().</p>
<p><strong>Footnotes:</strong></p>
<p>Lack of time forced me to leave out all explanations on how to install and configure Nginx (I&#8217;m assuming you know Apache already) &#8211; but the <a href="http://wiki.nginx.org/Main">Nginx Wiki is excellent</a>, even if the Russain translation is a little rough.</p>
<p>I&#8217;ve also purposely left out all references to solving disk bottlenecks (as I&#8217;ve left out a discussion about browser caching) because there has been a lot written about this and depending on what app or app-server you&#8217;re running, there are some very standard ways to solve IO problems already. e.g. Memcached, the InnoDB cache for MySQL, PHP&#8217;s Alternative PHP Cache, perstence engines that keep your compiled code in memory, etc..etc..</p>
<p>This technique works to speed up any back-end application server that uses a one-thread-per-connection model. It doesn&#8217;t matter if it&#8217;s Ruby via FastCGI, Mod_Perl on Apache or some crappy little Bash script spitting out data on a socket.</p>
<p>This is a very standard config for most high traffic websites today. It&#8217;s how they are able to leave keepalive enabled and handle a huge number of concurrent users with a relatively small app server cluster.  Lighttpd and Nginx are the two most popular free FSM/epoll web servers out there and Nginx is the fastest growing, best designed (IMHO) and the one I use to serve 400 requests per second on a small Apache cluster. It&#8217;s also what guys like <a href="http://wordpress.com/">Wordpress.com</a> use.</p>
]]></content:encoded>
			<wfw:commentRss>http://markmaunder.com/2009/how-to-handle-1000s-of-concurrent-users-on-a-360mb-vps/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Monetization or Cannibalization &#8211; The State of Social Gaming Marketing</title>
		<link>http://markmaunder.com/2009/monetization-or-cannibalization/</link>
		<comments>http://markmaunder.com/2009/monetization-or-cannibalization/#comments</comments>
		<pubDate>Sun, 01 Nov 2009 17:24:14 +0000</pubDate>
		<dc:creator>mark</dc:creator>
				<category><![CDATA[Startups]]></category>
		<category><![CDATA[Trash Talking]]></category>
		<category><![CDATA[social gaming]]></category>
		<category><![CDATA[techcrunch]]></category>
		<category><![CDATA[virtual goods]]></category>

		<guid isPermaLink="false">http://markmaunder.com/?p=361</guid>
		<description><![CDATA[Mike Arrington is a genius. Main-stream journalists sit up, knees together, back straight and start taking notes because this is a master at work. His recent blog entry titled Scamville calls out the most focused on and buzz-worthy companies in the valley for making money from advertising scams and accuses Facebook of encouraging a vile cycle of revenue and crappy marketing. The effect for Techcrunch is that it forces a number of high profile companies to respond and creates a ...]]></description>
			<content:encoded><![CDATA[<p>Mike Arrington is a genius. Main-stream journalists sit up, knees together, back straight and start taking notes because this is a master at work. His <a href="http://www.techcrunch.com/2009/10/31/scamville-the-social-gaming-ecosystem-of-hell/">recent blog entry titled Scamville</a> calls out the most focused on and buzz-worthy companies in the valley for making money from advertising scams and accuses Facebook of encouraging a vile cycle of revenue and crappy marketing. The effect for Techcrunch is that it forces a number of high profile companies to respond and creates a giant political suck-hole that draws you in and spits you out on techcrunch.com. Cha-ching! [It's cynical Sunday - didn't you know?]</p>
<p>There&#8217;s a great show-down video at the Virtual Goods Summit where Mike confronts Offerpal CEO Anu Shukla about this and she delivers a rather colorful response. Video below.</p>
<p>Buried in the comments on TC are a few experienced words from <a href="http://blog.jhong.org/">HotOrNot founder James Hong</a>. Love the hotel pay-per-view analogy:</p>
<blockquote>
<div>
<p>We ran offers like this back in 2005 for a very short period of time at HOTorNOT, that is until we realized what was going on. In a nutshell, the offers that monetize the best are the ones that scam/trick users. Sure we had netflix ads show up, and clearly those do convert to some degree, but i’m pretty sure most of the money ended up getting our users hooked into auto-recurring SMS subscriptions for horoscopes and stuff. When I hear people defending their directory of deals by saying Netflix is in there, i am reminded of how hotel pay-per-view has non-pornographic movies. Sure it gives them good cover, but we all know where the money is made.</p>
<p>In the end, we decided to turn the offers off. Quite frankly, the offers made us feel dirty, and pretty much on the same level as spammers. For us, the money just wasn’t worth it. On top of that, we relied on our goodwill with users and focused on growing by having a product and company that our users liked. Our sense was that using scammy offers would make good money in the short run, but would destroy our userbase in the end. Perhaps apps on facebook don’t feel this pressure because facebook is so huge, and there are always new people to burn.</p>
<p>I’d like to point out that there are some game companies out there who are holding out on using offers to monetize their users. Personally, that makes me 10 times more likely to pull my credit card out for them.</p>
<p>PS. I don’t think the concept of letting people fulfill offers to get credits is structurally a bad one. I for one would like to see the offer networks work together to create some set of public agreement on what types of practices are banned from their network, and perhaps they can evan have some sort of certification logo. These practices will only stop when companies are not competitively crippled by NOT doing them. In effect, we need a nuclear non-proliferation treaty among the offer networks.</p></div>
</blockquote>
<p>For soap opera fans here&#8217;s the war of words at the Virtual Goods Summit between Mike and Anu. [YouTube is currently down - so check back in a few if it doesn't show up.]</p>
<p><center><br />
<embed src="http://www.youtube.com/v/2PhKRCkbX9A&#038;hl=en&#038;fs=1&#038;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed><br />
</center></p>
<p></p>
]]></content:encoded>
			<wfw:commentRss>http://markmaunder.com/2009/monetization-or-cannibalization/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>An ode to the end of Facebook</title>
		<link>http://markmaunder.com/2007/an-ode-to-the-end-of-facebook/</link>
		<comments>http://markmaunder.com/2007/an-ode-to-the-end-of-facebook/#comments</comments>
		<pubDate>Tue, 31 Jul 2007 02:51:12 +0000</pubDate>
		<dc:creator>mark</dc:creator>
				<category><![CDATA[Randomness]]></category>
		<category><![CDATA[Rants]]></category>
		<category><![CDATA[Tech News]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Trash Talking]]></category>

		<guid isPermaLink="false">http://markmaunder.com/2007/an-ode-to-the-end-of-facebook/</guid>
		<description><![CDATA[I rant, Tony rants, Alan ranted.
With surprisingly similar space-time coordinates.
Our love of Facebook is duly recanted.
We&#8217;re no longer Zuckerberg&#8217;s subordinates.
]]></description>
			<content:encoded><![CDATA[<p><a href="http://markmaunder.com/2007/facebooks-getting-out-of-hand/">I rant</a>, <a href="http://www.tonywright.com/2007/facebook-and-misaligned-goals/">Tony rants</a>, <a href="http://asteele.tumblr.com/post/7023383">Alan ranted</a>.</p>
<p>With surprisingly similar space-time coordinates.</p>
<p>Our love of <a href="http://facebook.com/">Facebook</a> is duly recanted.</p>
<p>We&#8217;re no longer <a href="http://www.google.com/search?hl=en&amp;safe=off&amp;rlz=1B3RNFA_enUS177US229&amp;sa=X&amp;oi=spell&amp;resnum=0&amp;ct=result&amp;cd=1&amp;q=mark+zuckerberg&amp;spell=1">Zuckerberg&#8217;s</a> subordinates.</p>
]]></content:encoded>
			<wfw:commentRss>http://markmaunder.com/2007/an-ode-to-the-end-of-facebook/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Facebook&#8217;s getting out of hand</title>
		<link>http://markmaunder.com/2007/facebooks-getting-out-of-hand/</link>
		<comments>http://markmaunder.com/2007/facebooks-getting-out-of-hand/#comments</comments>
		<pubDate>Sat, 28 Jul 2007 07:52:44 +0000</pubDate>
		<dc:creator>mark</dc:creator>
				<category><![CDATA[Tech News]]></category>
		<category><![CDATA[Trash Talking]]></category>

		<guid isPermaLink="false">http://markmaunder.com/2007/facebooks-getting-out-of-hand/</guid>
		<description><![CDATA[Once upon a time I was a Facebook addict. It was an awesome way to reach out to people I haven&#8217;t been in contact with for years, share photos, update your status 80 times a day, etc. But Facebook apps are getting a little out of hand&#8230;

&#8230;and I&#8217;ve always hated that friend detail feature. &#60;/end rant&#62;
]]></description>
			<content:encoded><![CDATA[<p>Once upon a time I was a Facebook addict. It was an awesome way to reach out to people I haven&#8217;t been in contact with for years, share photos, update your status 80 times a day, etc. But Facebook apps are getting a little out of hand&#8230;</p>
<p><img src="/media/facebook1.gif" align="middle" /></p>
<p>&#8230;and I&#8217;ve always hated that friend detail feature. &lt;/end rant&gt;</p>
]]></content:encoded>
			<wfw:commentRss>http://markmaunder.com/2007/facebooks-getting-out-of-hand/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Rob Malda vs Alexa vs Slashdot vs Digg</title>
		<link>http://markmaunder.com/2007/rob-malda-vs-alexa-vs-slashdot-vs-digg/</link>
		<comments>http://markmaunder.com/2007/rob-malda-vs-alexa-vs-slashdot-vs-digg/#comments</comments>
		<pubDate>Mon, 23 Jul 2007 22:17:29 +0000</pubDate>
		<dc:creator>mark</dc:creator>
				<category><![CDATA[Tech News]]></category>
		<category><![CDATA[Trash Talking]]></category>

		<guid isPermaLink="false">http://markmaunder.com/2007/rob-malda-vs-alexa-vs-slashdot-vs-digg/</guid>
		<description><![CDATA[Rob Malda (aka cmdrtaco), the founder of Slashdot.org has written a rather schizophrenic piece on Slashdot about Alexa. He spends most of the article beating up Alexa, but is sure to include 5 links to the website in the article &#8211; two of them specifically asking people to install the Alexa toolbar.
A while ago Digg passed Slashdot in traffic. (I&#8217;ve written about this before) An article covering the phenomenon got Dugg and thousands of Digg users clicked the link to ...]]></description>
			<content:encoded><![CDATA[<p>Rob Malda (aka cmdrtaco), the founder of <a href="http://slashdot.org/">Slashdot.org</a> has written <a href="http://slashdot.org/articles/07/07/23/152243.shtml">a rather schizophrenic piece</a> on Slashdot about <a href="http://alexa.com/">Alexa</a>. He spends most of the article beating up Alexa, but is sure to include 5 links to the website in the article &#8211; two of them specifically asking people to <a href="http://download.alexa.com/?p=Dest_W_t_40_B2">install the Alexa toolbar</a>.</p>
<p>A while ago <a href="http://digg.com/">Digg</a> passed Slashdot in traffic. (<a href="http://markmaunder.com/2007/competitive-intelligence-tools/">I&#8217;ve written about this before</a>) An article covering the phenomenon got Dugg and thousands of Digg users clicked the link to Alexa and installed the Alexa toolbar. Notice the weird spike where the graphs meet. That skewed the Alexa results even further in Digg&#8217;s favor.</p>
<p><img src="http://markmaunder.com/diggAlexa.gif" height="210" width="400" /></p>
<p>So now Slashdot looks even worse to journalists &#8211; most of whom are writing about Digg and calling Rob for background. Which is why Rob can&#8217;t help asking  you to pretty please <a href="http://download.alexa.com/?p=Dest_W_t_40_B2">install the Alexa toolbar</a> to make slashdot look good to journalists again.</p>
]]></content:encoded>
			<wfw:commentRss>http://markmaunder.com/2007/rob-malda-vs-alexa-vs-slashdot-vs-digg/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
