<?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>thecrumb.com &#187; apache</title>
	<atom:link href="http://thecrumb.com/tag/apache/feed/" rel="self" type="application/rss+xml" />
	<link>http://thecrumb.com</link>
	<description>developer &#124; thinker &#124; tinkerer</description>
	<lastBuildDate>Sat, 04 Feb 2012 01:28:22 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Enable Sendfile Off &#8211; Apache Config Headache</title>
		<link>http://thecrumb.com/2009/11/14/enable-sendfile-off-apache-config-headache/</link>
		<comments>http://thecrumb.com/2009/11/14/enable-sendfile-off-apache-config-headache/#comments</comments>
		<pubDate>Sat, 14 Nov 2009 14:56:50 +0000</pubDate>
		<dc:creator>Jim Priest</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[ColdFusion]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[virtualbox]]></category>

		<guid isPermaLink="false">http://www.thecrumb.com/?p=976</guid>
		<description><![CDATA[I&#8217;ve been working on setting up a VM running a LAMP stack along with ColdFusion 9  (which I&#8217;ll blog about soon).  I&#8217;ve got everything up and running and was tinkering around making some updates to our TACFUG site but was &#8230; <a href="http://thecrumb.com/2009/11/14/enable-sendfile-off-apache-config-headache/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been working on setting up a VM running a LAMP stack along with ColdFusion 9  (which I&#8217;ll blog about soon).  I&#8217;ve got everything up and running and was tinkering around making some updates to our TACFUG site but was running into this weird issue that my CSS would not update &#8211; I would make a change and it wouldn&#8217;t show up in the browser.</p>
<p>I disabled all my browser cache and tried it in Chrome &#8211; same issue. I tried adding a UUID to the CSS call to force the browser to reload.</p>
<p>Then I thought it might be a ColdFusion issue so I spent some time in the Administrator turning all the options on/off (lots of new stuff in CF9!).  That didn&#8217;t work either.</p>
<p>Finally I pinged Twitter and John Mason helped me figure out that it was actually an Apache issue. His first thought was it was some caching module but looking in <em>mods-enabled</em> I didn&#8217;t see anything cache related. We were both searching on Google and found a few posts where people had similar issues and mentioned adding a line to their config file:</p>
<blockquote><p><strong>EnableSendfile Off</strong></p></blockquote>
<p>I have no idea what this does &#8211; but I opened up my apache2.conf file, scrolled to the bottom and added it.  Restarted Apache and my CSS was now refreshing!</p>
<p>The Apache docs mention that in some circumstances you may need to disable this:</p>
<blockquote><p><em>This directive controls whether <code><a href="http://httpd.apache.org/docs/2.2/programs/httpd.html">httpd</a></code> may use the     sendfile support from the kernel to transmit file contents to the client.     By default, when the handling of a request requires no access     to the data within a file &#8212; for example, when delivering a     static file &#8212; Apache uses sendfile to deliver the file contents     without ever reading the file if the OS supports it.</em><em>This sendfile mechanism avoids separate read and send operations,     and buffer allocations. But on some platforms or within some     filesystems, it is better to disable this feature to avoid     operational problems:</em></p>
<ul>
<li><em>Some platforms may have broken sendfile support that the build     system did not detect, especially if the binaries were built on     another box and moved to such a machine with broken sendfile     support.</em></li>
<li><em>On Linux the use of sendfile triggers TCP-checksum     offloading bugs on certain networking cards when using IPv6.</em></li>
<li><em>On Linux on Itanium, sendfile may be unable to handle files     over 2GB in size.</em></li>
<li><em>With a network-mounted <code><a href="http://httpd.apache.org/docs/2.2/mod/core.html#documentroot">DocumentRoot</a></code> (e.g., NFS or SMB),     the kernel may be unable to serve the network file through     its own cache.</em></li>
</ul>
<p><em>For server configurations that are vulnerable to these problems,     you should disable this feature.</em></p></blockquote>
<p><em><br />
</em></p>
<p>So hopefully this will prevent someone from going through the same headaches I did.  Now I have to get busy now that everything is working!</p>
]]></content:encoded>
			<wfw:commentRss>http://thecrumb.com/2009/11/14/enable-sendfile-off-apache-config-headache/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

