New Year’s resolution

My New Year’s resolution for 2012 was:

  1. Lose some weight.
  2. Save the galaxy from the Reaper invasion.

I achieved some progress on the first part and lost a few kilos so far. Naturally not as many as I hoped for but my weight is definitely going down.

I have however fulfilled the second part by finishing the single player campaign of Mass Effect 3 today. The Galaxy is once more save. No reapers, no Sith and nothing else lurking out there.

Let’s hope that will change soon. 🙂

Posted in Real Life, Video Games | Comments Off on New Year’s resolution

RAIDframe to the Rescue

One of the hard disks in my NetBSD server developed problems … again. This time it was one of the Western Digital VelociRaptors which I use for performance reasons.

The good news is that I didn’t notice for almost two weeks because NetBSD RAIDframe handled the situation smoothly. It kicked the broken disk out of the RAID array, reported the problem in the nightly e-mails (which I somehow missed) and kept the machine up and running. Well done RAIDframe, have a cookie!

Posted in NetBSD | Comments Off on RAIDframe to the Rescue

NetBSD-friendly Web Videos

Watching videos online has become very popular in recent years. Large video web sites as Youtube or Netflix are responsible for a lot of the Internet traffic these days. The predominant technology for delivering video over the Internet is still Adobe Flash. Unfortunately the Flash Player isn’t only renown for its poor security record and adverse effects on browser performance it is also available for only a small number of platforms (Windows, Mac OS X and a few Linux platforms). There are other browser video plugins like Microsoft’s Silverlight and RealPlayer. But they are available for even less platforms and not widely deployed.

Of the above video solutions only Flash works under NetBSD’s amd64 and i386 ports, but often not very well. While NetBSD 6.0 should improve that situation with the updated Linux emulation Flash will still be limited to the x86 ports. So how can you create a web page with an embedded video that is NetBSD-friendly despite all these technology problems?

Fortunately the new upcoming HTML5 standard can help here. Although it is still under development a lot of its aspects are already supported by modern browsers. One of them is the video element. It allows to embed a video into a web page with only a few lines of HTML code. Here is a simple example for a video element:

<video height="320" width="240">
<source src="my-video.ogv" type="video/ogg" />
</video>

This allows video playback in e.g. Firefox under NetBSD without any extra plugins. There is however one small problem: there is no single video file format that is supported by all browsers. Safari, Internet Explorer 9 and most mobile browsers only support MP4 files. Firefox and Opera however only support OGV files. Only Google Chrome supports both video file formats.

Fortunately the HTML5 video element allows you to specify multiple different video file format. Here is an improved version of our example:

<video height="320" width="240">
<source src="my-video.ogv" type="video/ogg" />
<source src="my-video.mp4" type="video/mp4" />
</video>

In this case the browser can pick either the MP4 or the OGV video file. There are various programs for creating video files in MP4 or OGV format. If you are lucky your video editing software will already support generating MP4 files. If it doesn’t you can try the ffmpeg program to convert the video file into an MP4 file. Although ffmpeg can generate OGV files as well I would recommend ffmpeg2theora for this job. It can read the same file formats and generates OGV files whose audio information is correctly played back by Firefox.

If you create a web page with video using the above recipe it will work on a large number of platforms. Playback of this video has been tested with Firefox (NetBSD, Mac OS X, Linux, Windows), Safari (Mac O X), Internet Explorer 9 (Windows), Opera (Linux) an HTC Desire Z under Android 2.3.3, an iPhone 4 and an iPad. Only an iPhone 3GS refused to play the video simply because the video’s resolution isn’t supported on that hardware.

Posted in NetBSD | Comments Off on NetBSD-friendly Web Videos