iprog.com

xen 3.2 freezing under load

For a number of weeks now I’ve been fighting a Xen host (dom0) that’s been freezing up periodically. It’s been a complete freeze of the Linux kernel, dom0, all domU’s, everything. SysRq doesn’t work either.

Today I finally found a reliable way to reproduce it.

Read more...

0 comments

Compiling mod_xsendfile for OS X

Today I needed to compile mod_xsendfile for OS X on Intel. The standard command for this,

apxs -cia mod_xsendfile.c

resulted in a module that was for i386 only.

Apache on Leopard (untested on Tiger) doesn’t appreciate this, throwing this error:

4/7/08 5:08:08 PM org.apache.httpd[ 15990] httpd: Syntax error on line 116 of /private/etc/apache2/httpd.conf: Cannot load /usr/libexec/apache2/mod_xsendfile.so into server: dlopen(/usr/libexec/apache2/mod_xsendfile.so, 10): no suitable image found. Did find:\n\t/usr/libexec/apache2/mod_xsendfile.so: mach-o, but wrong architecture

Turns out the solution is pretty simple. Just change the command to apxs to this:

apxs -cia -Wc,"-arch x86_64 -arch ppc -arch i386 -arch ppc64" -Wl,"-arch x86_64 -arch ppc -arch i386 -arch ppc64" mod_xsendfile.c

This will generate a fat-binary for all four current Mac architectures.

11 comments

paging: blog writers: hello !?!

one of my pet peeves is a blog that doesn’t have links to view previous pages of content. it works like this:

something i’m reading has a link to some random blog. i follow it, find the article interesting, and wonder what else of interest might be on this blog. so, i go to the home page and start reading. typically i get to read 5-10 articles and then get to the bottom of the page.

first tip: if your blog only shows one or two articles per page, change it. i don’t want to click and wait that often — i’ll end up leaving.

at the bottom i frequently find, well, nothing. i’m looking for a ‘next page,’ ‘more articles,’ ‘older entries,’ or something of the sort. i am amazed at how often there’s nothing there. sometimes i simply close the window at this point. occasionally i scroll back to the top looking for the links there, although i almost never find them.

i have, on occasion, gone digging into the archives section. even then, it’s usually impossible to find a way to get to a substantial portion of older content. the site i was just at showed about 10 articles for a given month, then an incomplete list of links to some more articles from that month (including duplicate links for all the articles above). still no pager though.

lame. don’t make visitors work that hard to read your site. if your blog or other content-drive site doesn’t have the ability to easily page through older content, you’re losing readers. fix it.

0 comments

spotlight fun in leopard

i upgraded to mac os x 10.5 shortly after it came out. one of the biggest areas of improvement is with spotlight. mostly it’s just much, much faster.

given its speed, i often use spotlight to launch less frequently used applications. today i went to launch locomotive.

cmd-space – l – o – c – o

that’s as far as i got before locomotive was the top hit, ready to launch. that’s great. more amusing, however, was what was right below it:

definition: adjective. crazy.

made me smile.

0 comments

active_scaffold overrides

the active_scaffold plugin for rails can be useful at times. as is typical of a large library, when it doesn’t do quite what you want, you have to start overriding parts of it.

unfortunately, there aren’t a lot of documented options to doing this with active_scaffold—at least not in the published docs. the code comments discuss more available options. so, what follows is an attempt to document some of those options.

Read more...

1 comment