NetBSD 5.0 changes, link to Pypes
Published: August 22, 2008Tags: programming pypes python unix netbsd
Well known German NetBSD guy Hubert Feyrer (personal website in English or German) made an entry in his NetBSD blog the other day discussing some user-visible changes in the upcoming NetBSD 5.0. It looks like something of a mixed bag to me, although it's mostly good.
On the good side: audit-packages and download-vulnerability-list are scheduled to become part of the base system, which I'm very pleased by. I think this functionality is fantastic and amazingly rare (only FreeBSD has something similar, to my knowledge), so I'm glad to see it made easier. /tmp will now be per-user via the use of magic symlinks, which is fairly boring but I suppose has positive security implications. The old DHCP client has been replaced by a simpler one which uses about 50% as much memory - the absolute saving is quite small (1058 vs 548 Kb), but if there is no loss of functionality or stability then it makes sense to do this. Finally, the bootloader will have a config file. I've never had to need to configure the bootloader (which is delightfully simple) past its defaults, but this harms nobody is actually something I had simply assumed was already there. All in all some nice, simple changes - evolution, not revolution, as the OpenBSD folks are fond of saying.
On the bad side: NetBSD will soon have a webserver in the base system. Hubert himself says "Seriously, I have no idea why this is" and I couldn't agree more. The only other OS I've known which does this is OpenBSD (which comes with a heavily patched version of Apache 1.3.x), and I've never really enjoyed it. Frankly, a webserver has no place in the base system of an OS. It's something that belongs squarely within a packaging system, like pkgsrc or ports.
Not only is this decision aesthetically displeasing, but the choice of webserver itself borders on the surreal. The OpenBSD folks at least have some excuse for shipping a webserver, in the sense that they are acting in keeping with their "theme" of being a high-security OS by shipping a version of Apache which they feel is more secure than the off-the-shelf version (the Apache devs have refused to put some of the OpenBSD security patches into the official Apache). NetBSD 5.0 will ship with, wait for it, the bozotic HTTP server: a small and low-featured webserver that is somewhat similar to Acme software's thttpd, with the primary difference that about one thousandth as many people have ever heard of it. I suppose one could make the argument that NetBSD are sticking to their own "theme" by shipping a very small, simple, minimal-dependency web server that would probably be ideal for embedded devices, but I don't quite buy that - bozohttpd is available in pkgsrc and long has been, which makes the situation different to OpenBSD because their customised Apache is not in their ports tree.
I just don't see the point in this. Not that I have a problem with bozohttpd itself - small and simple servers like it and thttpd were an inspiration for me when I was working on comanche - but of all the servers to jam somewhere one doesn't belong, why pick one that so few people are familiar with and will be happy with? It's much harder to find support for bozohttpd and it's much harder if not actually impossible to get it to do things that a lot of people used to Apache are going to want it to do, i.e. any sort of dynamic content faster than CGI. I can't see it getting used much, if at all, so why bother putting it in? It's such a small thing in itself that it would seem ridiculous to call it bloat, but it sets a precedent of letting in stuff that nobody needs which, if maintained for a few release cycles, could lead to genuine bloat.
Unrelated link drop:
An entry in someone's Livejournal about "Pypes", an interesting Python object that overloads the | operator (usually used to perform bitwise or operations on integers) to apply a function passed to the constructor. The effect is that you can mimic the familiar and much loved "pipe" syntax of Unix shells. A brief taste:
>>> double = Pype(map, lambda x : x * 2)
>>> sum = Pype(reduce, lambda x,y: x+y)
>>> range(7) | double | sum
42
Interesting and clever stuff!