But, this is the blog that will take the place of the Updates section on the wiki.
It turns out that putting RewriteRules inside a vhost entry for Apache is tricky, and I haven’t gotten the hang of it yet. Maybe I’ll figure it out… later.
It also turns out that mod_fastcgi + PHP-FPM + APC is an AWESOME combination. My favorite thing about FPM is the request backlogging. Under all previous PHP handlers–CGI, DSO, SuPHP, and previous FastCGI implementations–if all your worker slots were full, and another request came in, that request was out of luck and would be served a 500 error (or 503 or sometimes 508), even if it would have gotten a successful reply if it’d come in 5ms later.
FPM has backlogging turned on by default, and the number of requests that can be backlogged is configurable. This means you can set a sane number of workers for your system so you don’t completely destroy it (say, the lower of CPUs * 2, or physical RAM / RAM requirement per PHP process) without having to worry that when traffic spikes above that number, that visitors (or, more likely, search engines) will get the dreaded Internal Server Error.
For the first time, the wiki now has ‘pretty’ URLs. I never got Apache rewrites working under Ubuntu, mainly due to my own ignorance. I’ve learned how to do it correctly, and it’s working on this server beautifully. All of the doku.php?id=blah is gone; it’s just pages with names. It’s beautiful. Really, really pretty.
Things yet to do: I want to set document indexes (the proper directive name now escapes me) so Apache always looks for index.php by default (if that’s the right thing), and get all the .htaccess rules moved into the vhost so overrides can be disabled. This will obviate a lot of directory traversal and file statting on Apache’s part. By ‘a lot,’ I of course mean a trivial amount given the amount of traffic I’m getting. It’s just neater, tidier that way, and I will learn a lot along the way.
It is bedtime. More tomorrow. Not that you can see it yet, since this blog isn’t even Internet-facing yet… I don’t even have a complete strategy for how I’m going to make that happen!
Onward! To sleep!