<?xml version="1.0" encoding="utf-8"?>
<!-- generator="wordpress/1.5.1.3" -->
<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/"
>

<channel>
	<title>explanatory gap</title>
	<link>http://www.enac.northwestern.edu/~tew</link>
	<description>t e whalen -- research engineer -- psychology -- northwestern university</description>
	<pubDate>Thu, 07 Jul 2005 15:32:04 +0000</pubDate>
	<generator>http://wordpress.org/?v=1.5.1.3</generator>
	<language>en</language>

		<item>
		<title>fixing nagios on debian</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2005/01/17/fixing-nagios-on-debian/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2005/01/17/fixing-nagios-on-debian/#comments</comments>
		<pubDate>Mon, 17 Jan 2005 23:57:26 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
	<category>Clustering</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2005/01/17/fixing-nagios-on-debian/</guid>
		<description><![CDATA[I had trouble with CGI access to Nagios after an apt-get upgrade on my debian box.  I kept getting the error &#8220;It appears as though you do not have permission to view information for any of the services you requested&#8221;.  The key is to remember to check that all the configuration files are [...]]]></description>
			<content:encoded><![CDATA[<p>I had trouble with CGI access to <a href="http://www.nagios.org/">Nagios</a> after an <code>apt-get upgrade</code> on my debian box.  I kept getting the error &#8220;It appears as though you do not have permission to view information for any of the services you requested&#8221;.  The key is to remember to check that all the configuration files are readable by the <code>nagios</code> user, since when it&#8217;s running as a CGI, it doesn&#8217;t have the same access as it does when running as a daemon.</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2005/01/17/fixing-nagios-on-debian/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>path python module</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/12/03/path-python-module/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/12/03/path-python-module/#comments</comments>
		<pubDate>Fri, 03 Dec 2004 22:38:40 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>Python</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/12/03/path-python-module/</guid>
		<description><![CDATA[I don&#8217;t think I&#8217;ve mentioned the path python module in detail before, so I will now.

It&#8217;s amazingly useful, and so much more intuitive than the standard library equivalents (os.path, etc.).  If you&#8217;re like me, and you never got the hang of iteration or recursion in bash scripting, this module is for you.

I&#8217;m using it [...]]]></description>
			<content:encoded><![CDATA[<p>I don&#8217;t think I&#8217;ve mentioned the <a href="http://www.jorendorff.com/articles/python/path/">path python module</a> in detail before, so I will now.</p>

<p>It&#8217;s amazingly useful, and so much more intuitive than the standard library equivalents (os.path, etc.).  If you&#8217;re like me, and you never got the hang of iteration or recursion in bash scripting, this module is for you.</p>

<p>I&#8217;m using it to iterate over all directories on the server with a &#8216;preproc.log&#8217; file in them and collecting information about some of the files within.</p>

<pre><code>
import time
import path

DAY = 24 * 3600 # seconds
NOW = time.time()



globs = (("run*_raw+orig.BRIK", 21), # glob, max age
         ("p*_auto+tlrc.BRIK", 28))

def age(f):
    return int(NOW - f.atime) / DAY

p = path.path("/home")
for preproc_file in p.walkfiles("preproc.log"):
    p_dir = preproc_file.parent
    for glob_pattern, max_age in globs:
        for f in p_dir.files(glob_pattern):
            if f.islink():
                # ignore symlinks
                continue
            elif age(f) > max_age:
                print f.size, f
 </code></pre>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/12/03/path-python-module/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>helpful hint</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/11/23/helpful-hint/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/11/23/helpful-hint/#comments</comments>
		<pubDate>Tue, 23 Nov 2004 22:59:47 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/11/23/helpful-hint/</guid>
		<description><![CDATA[If it&#8217;s a big pain when a workstation&#8217;s ssh keypair gets lost, back it up.



#!/bin/sh

HOSTNAME=`hostname`
sudo cat /etc/ssh/ssh_host_dsa_key > ws_keys/ssh_host_dsa_key.${HOSTNAME}
sudo cat /etc/ssh/ssh_host_dsa_key.pub > ws_keys/ssh_host_dsa_key.pub.${HOSTNAME}
sudo cat /etc/ssh/ssh_host_rsa_key >    ws_keys/ssh_host_rsa_key.${HOSTNAME}
sudo cat /etc/ssh/ssh_host_rsa_key.pub > ws_keys/ssh_host_rsa_key.pub.${HOSTNAME}

chmod go-r ws_keys/*.${HOSTNAME}



]]></description>
			<content:encoded><![CDATA[<p>If it&#8217;s a big pain when a workstation&#8217;s ssh keypair gets lost, back it up.</p>

<pre style="width: 100%; font-size: x-small">
<code>
#!/bin/sh

HOSTNAME=`hostname`
sudo cat /etc/ssh/ssh_host_dsa_key > ws_keys/ssh_host_dsa_key.${HOSTNAME}
sudo cat /etc/ssh/ssh_host_dsa_key.pub > ws_keys/ssh_host_dsa_key.pub.${HOSTNAME}
sudo cat /etc/ssh/ssh_host_rsa_key >    ws_keys/ssh_host_rsa_key.${HOSTNAME}
sudo cat /etc/ssh/ssh_host_rsa_key.pub > ws_keys/ssh_host_rsa_key.pub.${HOSTNAME}

chmod go-r ws_keys/*.${HOSTNAME}

</code>
</pre>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/11/23/helpful-hint/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>caretaker indirection</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/11/22/caretaker-indirection/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/11/22/caretaker-indirection/#comments</comments>
		<pubDate>Mon, 22 Nov 2004 20:55:42 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/11/22/caretaker-indirection/</guid>
		<description><![CDATA[We&#8217;ve got a &#8220;data archive&#8221; here, where we store all of our raw fMRI data, for safe-keeping.  Unfortunately, it&#8217;s hard to allow the kind of fine-grained access control which would allow people to insert new data but disallow alteration or removal of data.

The solution I&#8217;ve come up with is to use a caretaker pattern, [...]]]></description>
			<content:encoded><![CDATA[<p>We&#8217;ve got a &#8220;data archive&#8221; here, where we store all of our raw fMRI data, for safe-keeping.  Unfortunately, it&#8217;s hard to allow the kind of fine-grained access control which would allow people to insert new data but disallow alteration or removal of data.</p>

<p>The solution I&#8217;ve come up with is to use a <a href="http://c2.com/cgi/wiki?CaretakerPattern">caretaker pattern</a>, which means a program on the server side which creates, unlocks, and re-locks the appropriate directory.  The workstation prepares the new data and then calls out (via ssh and sudo) to the caretaker, which prepares the new directory.  The data is copied over, and then the caretaker re-locks the directory.</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/11/22/caretaker-indirection/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>let&#8217;s go zipf</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/11/15/lets-go-zipf/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/11/15/lets-go-zipf/#comments</comments>
		<pubDate>Mon, 15 Nov 2004 18:56:04 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>Data Storage</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/11/15/lets-go-zipf/</guid>
		<description><![CDATA[

Check out that curve!  Woo!  I&#8217;ve got your logarithm right here!
]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.enac.northwestern.edu/~tew/wp-content/du-04-11-15.png" alt="" /></p>

<p>Check out that curve!  Woo!  I&#8217;ve got your logarithm right here!</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/11/15/lets-go-zipf/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>i2o, adaptec, raidutils, and 2.6.x</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/i2o-adaptec-raidutils-and-26x/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/i2o-adaptec-raidutils-and-26x/#comments</comments>
		<pubDate>Wed, 10 Nov 2004 23:08:14 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
	<category>Data Storage</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/i2o-adaptec-raidutils-and-26x/</guid>
		<description><![CDATA[I&#8217;m getting hit with Debian bug #278239.  What&#8217;s happening is I upgraded the kernel on the server to 2.6.x (which gave a significant performance boost) and the standard dpt_i2o module has been subsumed by the i2o_block and associated modules. I guess the kernel headers changed too, along with the device names/numbers associated with managing [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m getting hit with <a href="http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=278239">Debian bug #278239</a>.  What&#8217;s happening is I upgraded the kernel on the server to 2.6.x (which gave a significant performance boost) and the standard <code>dpt_i2o</code> module has been subsumed by the <code>i2o_block</code> and associated modules. I guess the kernel headers changed too, along with the device names/numbers associated with managing and mounting the array.  This breaks the standard compilation of <a href="http://packages.debian.org/testing/admin/raidutils">raidutils</a>, which means I get the error</p>

<p><code>
File /dev/dpti17 Could Not Be Opened
</code></p>

<p>I haven&#8217;t recompiled my raidutils yet, hoping for a swift resolution of the bug.</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/i2o-adaptec-raidutils-and-26x/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>new machine, and x86_64 joy</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/new-machine-and-x86_64-joy/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/new-machine-and-x86_64-joy/#comments</comments>
		<pubDate>Wed, 10 Nov 2004 08:03:46 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
	<category>Clustering</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/new-machine-and-x86_64-joy/</guid>
		<description><![CDATA[So, I transplanted the brains of one of my workstations today, taking out an aging k7 and stuffing in a new Athlon 64.  This required some re-jiggering of my previous availability calculations, since the bogomips are low on these new Athlons.  I decided to run a quick benchmark on all the machines and [...]]]></description>
			<content:encoded><![CDATA[<p>So, I transplanted the brains of one of my workstations today, taking out an aging k7 and stuffing in a new Athlon 64.  This required some re-jiggering of my <a href="/~tew/archives/2003/05/16/how-available-is-my-cluster/">previous availability calculations</a>, since the bogomips are low on these new Athlons.  I decided to run a quick benchmark on all the machines and use that value &#8212; but what benchmark to use?</p>

<p>I settled on <a href="http://www.tux.org/~balsa/linux/benchmarking/articles/html/Article1d-3.html">whetstones</a>, a benchmark with <em>gravitas</em>.  Also, it can measure double-precision floating-point arithmetic, the same kind of operations most of the computing we&#8217;re doing does do.  My new machine has 31% fewer bogomips than my previous champ, but can do 50% more whetstones.</p>

<p>I&#8217;m just running the old Debian i386 on this machine, since the speed boost is substantial, even without re-compiling everything over to 64 bits.  I&#8217;ve installed <a href="http://www.debian.org/ports/amd64/">debian-amd64</a> on a spare partition, and I&#8217;ll play with it a little when I get a chance.  Rebuilding everything and setting up a special distribution system for the x86_64 stuff is a bit of a pain, though.  I might wait until I&#8217;ve got another 64-bit machine before I go too far with it.  I don&#8217;t think the man-hours saved by moving up to 64-bit exceed the number of hairs I&#8217;d pull out of my head doing it, figuratively speaking.</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/11/10/new-machine-and-x86_64-joy/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>curse you, heisenbugs!</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/11/05/curse-you-heisenbugs/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/11/05/curse-you-heisenbugs/#comments</comments>
		<pubDate>Fri, 05 Nov 2004 22:26:37 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/11/05/curse-you-heisenbugs/</guid>
		<description><![CDATA[So.

Dell Precision Workstation 350 has a problem when running Linux kernels in the 2.6.x series with the keyboard and busmice.  If you boot them up without touching a key (say in GRUB, for instance) you&#8217;ll get a message like i8042.c: Can't read CTR while initializing i8042 in your dmesgs.

This makes the keyboard and mouse [...]]]></description>
			<content:encoded><![CDATA[<p>So.</p>

<p>Dell Precision Workstation 350 has a problem when running Linux kernels in the 2.6.x series with the keyboard and busmice.  If you boot them up without touching a key (say in GRUB, for instance) you&#8217;ll get a message like <code>i8042.c: Can't read CTR while initializing i8042</code> in your dmesgs.</p>

<p>This makes the keyboard and mouse not respond.  If, while trying to debug this problem, you touch a key sometime between POST and when the kernel tries to initialize the i8042, you won&#8217;t have this problem.</p>

<p>One workaround is to touch a key between POST and initialization every time the machine boots. Another workaround is to add <code>acpi=off</code> to your kernel bootup arguments, say in GRUB or LILO.  I understand that you could also pass <code>i8042.noacpi=1</code>, according to <a href="http://marc.theaimsgroup.com/?l=linux-kernel&amp;m=109508824931419&amp;w=2">the linux-kernel mailing list</a> &#8212; but I haven&#8217;t tried this.</p>

<p>This is very annoying.</p>

<p>Also, this does not seem to affect Dell Precision Workstations 360.</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/11/05/curse-you-heisenbugs/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>going gentle into that good night</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/08/23/going-gentle-into-that-good-night/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/08/23/going-gentle-into-that-good-night/#comments</comments>
		<pubDate>Mon, 23 Aug 2004 21:56:55 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/08/23/going-gentle-into-that-good-night/</guid>
		<description><![CDATA[Yet another drive in yet another raid array has failed on me.  This one is less important, though, so we&#8217;re not replacing it.  And also, $300 for a 78 GB drive is just crazy.  We&#8217;re going to let the hot spare rebuild the array, and the plan is that when the next [...]]]></description>
			<content:encoded><![CDATA[<p>Yet another drive in yet another raid array has failed on me.  This one is less important, though, so we&#8217;re not replacing it.  And also, $300 for a 78 GB drive is just crazy.  We&#8217;re going to let the hot spare rebuild the array, and the plan is that when the next disk fails, we&#8217;ll shrink the container.  The analogy is that instead of replacing the flat tires on this automobile, we&#8217;re going to turn it into a tricycle, then a bicycle, then a unicycle, and finally a no-cycle.</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/08/23/going-gentle-into-that-good-night/feed/</wfw:commentRSS>
	</item>
		<item>
		<title>still fighting the good fight</title>
		<link>http://www.enac.northwestern.edu/~tew/archives/2004/08/19/still-fighting-the-good-fight/</link>
		<comments>http://www.enac.northwestern.edu/~tew/archives/2004/08/19/still-fighting-the-good-fight/#comments</comments>
		<pubDate>Thu, 19 Aug 2004 15:49:23 +0000</pubDate>
		<dc:creator>tew</dc:creator>
		
	<category>General</category>
		<guid>http://www.enac.northwestern.edu/~tew/archives/2004/08/19/still-fighting-the-good-fight/</guid>
		<description><![CDATA[Yesterday, I swapped around yet another spare drive in my RAID enclosure, hoping, on the advice of the Adaptec techs, that this would stop my irritating runs-for-24-hours-and-then-dies problem.

It did not.  Now, I&#8217;m left with the conclusion that I&#8217;m facing a situation like that described in Adaptec knowledge base article #2328, which tells me I [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.enac.northwestern.edu/~tew/archives/2004/08/18/what-does-this-mean/">Yesterday</a>, I swapped around yet another spare drive in my RAID enclosure, hoping, on the advice of the Adaptec techs, that this would stop my irritating runs-for-24-hours-and-then-dies problem.</p>

<p>It did not.  Now, I&#8217;m left with the conclusion that I&#8217;m facing a situation like that described in <a href="http://adaptec-tic.adaptec.com/cgi-bin/adaptec_tic.cfg/php/enduser/std_adp.php?p_faqid=2328">Adaptec knowledge base article #2328</a>, which tells me I need to backup my RAID, format all the drives, rebuild the array, and restore the data from backup.  Does anyone have 1.4 terabytes of storage they can lend me?  Next year, this will not be a problem, because we&#8217;ll all be running around with USB keychains with that much space.  Right now, though, it&#8217;s problematic.</p>
]]></content:encoded>
			<wfw:commentRSS>http://www.enac.northwestern.edu/~tew/archives/2004/08/19/still-fighting-the-good-fight/feed/</wfw:commentRSS>
	</item>
	</channel>
</rss>
