Xen versus VMware for me

I've recently spent some time thinking about virtualization technology,in particular how I feel about Xen versus VMware. In theory the choiceshould be a slamdunk for me, because VMware requires evil binary kernelmodules and I have usually avoided that sort of thing even when it wassomewhat painful (eg, I don't use ATI's binary X drivers). In practice,though, I am only distantly lukewarm on Xen and much more interested inVMware.

The simple summary why this is is that Xen is


An interesting Bourne shell limitation

Presented in illustrated form, on at least Solaris 8, FreeBSD, andOpenBSD:

$ exec 9>/dev/null$ exec 10>/dev/nullexec: 10: not found

(And the shell exits.)

The genuine Bourne shell only allows redirection to (or from)single-digit file descriptors; if you give multiple digits, itinstead gets parsed as ' exec 10 >/dev/null '.

(The limitation has been faithfully copied by at least some Bourne shell


A gotcha with inetd/xinetd and popular UDP services

We have historically had a small problem with our inetd s: every sooften when we attempted to restart it with a SIGHUP to make it pick up aconfiguration change, it would fail to bring up an important UDP-basedservice we need, reporting a failure to bind to the UDP port.

(We saw the same problem with xinetd ; I'm using ' inetd ' as as ageneric term.)

What was probably happening is that when this would happen, inetd hadjust spawned the program to handle


Solving an automounter timeout problem with brute force

Our central mail machine runs various cron jobs as part of its work.Starting recently, every now and then a cron job (or a command run outof an alias) would randomly die with an error like:

sh: /cs/foo/adm/script: cannot execute

(Where /cs/foo is NFS mounted through the automounter, and the cronentry just runs that script.)

I am pretty sure that this is a gift from the Solaris 8 automounter.

Our central mail machine is pretty old


What I really want from an automounter

As peculiar as it sounds, I don't like the automatic mounting andunmounting of NFS filesystems. I don't have unreliable NFS fileserversand I don't like the various side effects of not having everythingmounted; pretty much the only thing it seems good for is making oursystems slower and more fragile.

However, one thing that the automounter is good for is maintaininga nice, organized list of NFS mounts in a format that can be easilydistributed around without problems, and even automatically gettingit right


Another issue with C's volatile

I think that part of the issue with volatile is that it can beused for at least three different things:

  1. stuff that can change behind the compiler's back (eg flags set ina signal handler), where mostly you need the compiler to not cachevalues loaded from volatile variables.
  2. hardware registers, where reads and writes have side effects, soyou need the compiler to do all loads, even apparently pointlessones (as John Mashey and MIPS found out in the early ages ofoptimizing compilers being used on

Fixing up .rpmnew files

For some reason, rpm in Fedora Core 6 (and I believe Fedora Core 5 too)has become overly twitchy about replacing configuration files; a lot ofthe time it will write .rpmnew files instead of just replacing the oldversion of the file even if the old file is unchanged and the new andthe old file are completely identical.

While I think this is multiarch stuff in action, I still have toclean it up every so often. I use a little scriptlet for this,usually typed at the command


Weekly spam summary on Janury 6th, 2007

This week, we:

  • got 12,487 messages from 217 different IP addresses.
  • handled 16,802 sessions from 997 different IP addresses.
  • received 224,173 connections from at least 71,302 different IPaddresses.
  • hit a highwater of 23 connections being checked at once.

The university came back from vacation this past Thursday, andof course the spammers never went on much of one to start with.I suspect that volume


Henry Spencer on C's volatile

Henry Spencer sent me a reply to my previous entry on volatile that corrects some of my (mis)information, and I amputting it here with his permission:

I fear you've miscalled this one. ANSI C pre-dates aggressive memorycontrollers in consumer CPUs , but it had extensive participation bypeople in the supercomputer world as well, and such things were commonthere long ago.

The key issue you've missed is that ANSI C doesn't really acknowledge theexistence of a "compiler".


The scars of my NPTL experience

It's only recently that I've realized how jumpy about certain thingsmy NPTL (the 'native Posix thread library' for Linux) experience stillmakes me.

NPTL was the new, improved Linux threading library, supplantingthe old and less efficient 'pthreads' library. To get its goodperformance it needed some kernel support, kernel support thatwas only added in the Linux 2.5 development kernels (and thenin Linux 2.6 when 2.5 turned into 2.6).

However,