<?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>kill the radio &#187; lighttpd</title>
	<atom:link href="http://blog.killtheradio.net/tag/lighttpd/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.killtheradio.net</link>
	<description>or die trying</description>
	<lastBuildDate>Thu, 15 Dec 2011 20:21:43 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>lighttpd out, nginx in</title>
		<link>http://blog.killtheradio.net/technology/lighttpd-out-nginx-in/</link>
		<comments>http://blog.killtheradio.net/technology/lighttpd-out-nginx-in/#comments</comments>
		<pubDate>Mon, 09 Mar 2009 20:27:45 +0000</pubDate>
		<dc:creator>Andrew Lyon</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[beeets]]></category>
		<category><![CDATA[lighttpd]]></category>
		<category><![CDATA[server]]></category>

		<guid isPermaLink="false">http://killtheradio.dev/?p=30</guid>
		<description><![CDATA[So As some of you know, a while ago I switched from Apache to lighttpd&#8230;I mean, youtube uses it right? No doubt a highly modified version. Not long after I get it set up just perfectly, I started reading ALL the horror stories about memory leaks. Now granted I didn&#8217;t run into any memory leaks, [...]]]></description>
			<content:encoded><![CDATA[<p>So As some of you know, a while ago I switched from Apache to lighttpd&#8230;I mean, youtube uses it right? No doubt a highly modified version. Not long after I get it set up just perfectly, I started reading ALL the horror stories about memory leaks.</p>
<p>Now granted I didn&#8217;t run into any memory leaks, but I&#8217;m not going to bet for something that is consistently failing all around me. Then I heard of Nginx. Keep in mind this all happened at least a month ago&#8230;I just haven&#8217;t had time to blog at all. Anyway, it&#8217;s supposedly faster than lighty, it&#8217;s actually stable and doesn&#8217;t need rebooting every night, and it&#8217;s russian.</p>
<p>So being the tinkerer at hear that I am, I decided to install it on the beeets.com server. Well, the syntax in in the config file was a bit of a learning curve. It&#8217;s sort of like C but not as friendly. A space in the wrong place will make it fail. Needless to say, I got it all configured though. FastCGI, PHP, URL rewriting, client-side caching, and if I need it later on, a kickass reverse proxy.</p>
<p>So I guess this is me saying a few months later than nginx totally kicks ass. It benchmarks so much better than Apache, and it&#8217;s russian.</p>
<p>I think the next think I&#8217;ll be tinkering with (fucking up) will be MySQL replication. From what I read, it&#8217;s better than clustering for a few reasons. You can do things with replication you can&#8217;t do with a cluster. The problem is there will definitely be some gnarly code tweaks because nothing supports it by default, at least not that I know of. Oh yeah, plus there&#8217;s like, no documentation on writing a PHP app for a replicated database. I know, read from the slave, write to the master, but if you write to the master and immediately need to read a generated value (last id) then you have to read from the master since you can&#8217;t rely on the slaves to be kept instantly up to date. That&#8217;s a fun code change.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.killtheradio.net/technology/lighttpd-out-nginx-in/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Throw apache to the wind?</title>
		<link>http://blog.killtheradio.net/technology/throw-apache-to-the-wind/</link>
		<comments>http://blog.killtheradio.net/technology/throw-apache-to-the-wind/#comments</comments>
		<pubDate>Sun, 18 Jan 2009 20:24:51 +0000</pubDate>
		<dc:creator>Andrew Lyon</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[fastcgi]]></category>
		<category><![CDATA[hosting]]></category>
		<category><![CDATA[lighttpd]]></category>
		<category><![CDATA[modproxy]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://killtheradio.dev/?p=26</guid>
		<description><![CDATA[So after hours of searching and tweaking, I finally got the answer I never wanted: it&#8217;s not possible to have apache serve mod_fastcgi requests through it&#8217;s own reverse proxy (ie load-balance mod_fastcgi). I know this is incorrect. But it had taken me so long and wasted so much time getting to the point where I [...]]]></description>
			<content:encoded><![CDATA[<p>So after hours of searching and tweaking, I finally got the answer I never wanted: it&#8217;s not possible to have apache serve mod_fastcgi requests through it&#8217;s own reverse proxy (ie load-balance mod_fastcgi). I know this is incorrect. But it had taken me so long and wasted so much time getting to the point where I was almost as clueless as when I started, that I took drastic action.</p>
<p>I installed <a href="http://www.lighttpd.net/" target="_blank">lighttpd</a>. I already had the FastCGI setup running, not to mention I got a new Linode for testing remote PHP. The only problem was that I couldn&#8217;t load balance between my slack box (web server) and my new linode (debian app server). BTW I chose <a href="http://www.debian.org/" target="_blank">Debian</a> because the image was smaller and from what I know, it&#8217;s essentially the same as Slack. I really haven&#8217;t had ANY problems moving to it yet, and let&#8217;s face it, Deb is a lot more standard. Installing PHP was a bitch, but that&#8217;s what apt-get is for (no, I compiled PHP&#8230;but I&#8217;ll be damned if I&#8217;m going to hand compile all the stupid dependencies).</p>
<p>Anyway, within 20 minutes, lighttpd had PHP running through FastCGI load balanced between two servers. Needless to say, I fell in love. Not to mention all the information I was inundated with along the way about how small and lean lighttpd is swayed this choice a little.</p>
<p>So as far as I know, <a href="http://www.beeets.com" target="_blank">beeets</a> is running great on both of its &#8220;new&#8221; servers and loving it.</p>
<p>There was a bit of trouble getting used to the new URL rewriting scheme, but generally instead of doing apache&#8217;s</p>
<p>RewriteCond blahblah !-f</p>
<p>You can just do url-rewrite(&#8216;(images|css|js)&#8217; =&gt; &#8216;$0&#8242;)</p>
<p>(this is a horrible oversimplification, but you get the idea)&#8230;you write the URLs you DON&#8217;T want to be rewritten to $0. Works wonders.</p>
<p>All that&#8217;s left is some cache-control headers (I&#8217;m crazy about them, if you can&#8217;t tell yet), and some speed testing. I&#8217;m excited to see if lighttpd is actually faster than apache under ab.</p>
<p>Next up, <a href="http://www.capify.org/" target="_blank">Capistrano</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.killtheradio.net/technology/throw-apache-to-the-wind/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

