Sunday, April 13, 2008

Configuring Daemontools under Ubuntu (upstart)

With the moving of ubuntu from the old fashioned init to the modern upstart, the daemontools svscanboot package doesn't cleanly install. Here's how to fix it. You really do need daemontools if you're going to run djbdns or qmail.

The daemontools-installer package modifies /etc/inittab to cause the svscan/svscanboot process to launch. With upstart, there is no /etc/inittab, instead it is replaced with a collection of config files in /etc/event.d. There's currently a bug for this misbehavior, however it is over a year old, but has the workaround documented.

The solution is to first create an empty, bogus /etc/inittab, then run the installer, and then put a manually created file in /etc/event.d to actually launch svscan.


  1. Create a bogus inittab, touch /etc/inittab

  2. Install the installer, apt-get install daemontools-installer

  3. Fetch the code, get-daemontools

  4. Build the package, build-daemontools (and, of course, install it when prompted)

  5. Create /etc/event.d/svscan

  6. Run initctl start svscan

  7. If desired, rm /etc/inittab



The following is the contents of /etc/event.d/svscan:

start on runlevel 2
start on runlevel 3
start on runlevel 4
start on runlevel 5
stop on shutdown
respawn
exec /usr/bin/svscanboot


Now you will get the desired behavior of svscan starting at boot and being kept running by upstart.

Textbooks Cost Too Much

As someone who must saddle his students with pricey textbooks, I try as much as possible to avoid requiring anything but the barest essentials. However, sometimes there are materials the student needs to have in order to be successful in a class. Frankly making the tradeoff between recommended (i.e. never-bought and never-read) and required (i.e. bought but never-read) texts is a hard one.

I am in full agreement with the following passage from Why Do Textbooks Cost So Much which describes the three party pricing that occurs in healthcare.

Welcome to the world of textbook pricing, where, it would seem, the usual market forces don't apply. The textbook market in no way resembles the trade book market, in which the same person - the consumer - desires the book (the new War and Peace, the latest diet guide or whatever), acquires it, and pays for it, so that price points and competition are crucial. What the textbook market resembles most is the market for health care, in which one entity (the physician/the professor) desires - that is, assigns or prescribes - the product, a second entity (the patient/the student) consumes it, and a third set of entities (insurance companies/parents) foot the bill. Spiraling prices for textbooks, like spiraling medical costs, seem to be the inevitable result.


However, I'm not as negative about the spiraling costs of healthcare that most people are. I believe the US medical system delivers high value for dollar, and the only thing that's really missing is pricing transparency. For example, I actually spent MORE on healthcare than was strictly necessary because the price I thought a particular procedure would cost was actually the "insurance" price, and had I paid directly I would have saved several thousand dollars. I look forward to the day that I can see a plain statement of costs and services from a doctor.