Blogroll is back – on steroids

I finally got around to adding an excerpt of the list of blogs I’m regularly reading to the navigation bar to the right.

The list is somewhat special as it’s auto-updating: It refereshes every 30 minutes and displays a list of blogs in descending order of last-updated-time.

Adding the blogroll was a multi step process:

At first, I thought adding the Serendipity blogroll plugin and pointing it to my Newsgator subscription list (I’m using Newsgator to always have an up-to-date read-status in both Net News Wire and FeedDemon) was enough, but unfortunately, that did not turn out to be the case.

First, the expat module of the PHP installation on this server has a bug making it unable to parse files with the unicode byte order mark at the beginning (basically three bytes telling your machine if the document was encoded on a little- or big-endian machine). So it was clear that I had to do some restructuring of the OPML-feed (or patching around in the s9y plugin, or upgrading PHP).

Additionally, I wanted the list to be sorted in a way that the blogs with the most recent postings will be listed first.

My quickly hacked-together solution is this script which uses a RSS/Atom-parser I took from WordPress, which means that the script is licensed under the GNU GPL (as the parser is).

I’m calling it from a cron-job once per 30 minutes (that’s why the built-in cache is disabled on this configuration) to generate the OPML-file sorted by the individual feeds update time stamp.

That OPML-file then is fed into the serendipity plugin.

The only problem I now have is that the list is unfairly giving advantage to the aggregated feeds as these are updated much more often than individual persons blogs. In the future I will thus either create a penalty for these feeds, remove them from the list or just plain show more feeds on the page.

Still, this was a fun hack to do and fulfills its purpose. Think of it: Whenever I add a feed in either Net News Wire or FeedeDemon, it will automatically pop up on the blogroll on gnegg.ch – this is really nice.

On a side note: I could have used the Newsgator API to get the needed information faster and probably even without parsing the individual feeds. Still, I went the OMPL-way as that’s an open format making the script useful for other people or for me should I ever change the service.

Horror Movies and LCDs

Have you ever tried watching a horror movie on a LCD screen?

I’m telling you, it sucks.

Movies in general and horror movies in specific may contain dark scenes with very little contrast.

That’s perfectly ok – especially in the horror genre where you expect a certain creepyness which is best achieved with dark shots.

Now the problem is that LCDs (the non-glossy editions in particular) suck at displaying black.

What you are seeing is not black – it’s more like a blue-greyish bright surface – bright enough to suck up all the other dark tones that may be on the screen.

The effect is even worsened by watching the movie in a dark room. When there’s ambient light, it’s much better. But when it’s dark around you, there’s nothing you can do to fix it:

Increasing the screens brightness will make the black glow even brighter, sucking up more surrounding areas. Turning the brightness down will make the black darker, but you’ll lose the surrounding areas to the darkness too.

I tried a display on a ThinkPad T42p, a Cinema Display and the display of my MacBook Pro. None of them is particularly better or worse – they plain suck.

This is why I always buy DLP projectors. The black really is quite black there (it’s still not perfect – I imagine laser projectors will rule here).

The solution the industry is throwing at this is the glossy displays. But where the non-glossy ones suck at horror movies in a dark room, the glossy ones suck at the rest – like working in the office, working outside and even watching a movie in a bright room.

To actually see something of the higher contrast these glossy displays are said to provide (to actually see something at all – I mean besides yourself), you either need to be in a completely dark room or to turn up the brightness very high which will be quite unpleasant for your eyes (I get a bad headache after working more than 30 minutes on my Cinema Display when I turn the brightness all up).

Can’t wait for laser projectors, non-reflecting glossy displays (can a thing like that even exist?), hologram projectors, neuronal interfaces or something completely different. Till then, I guess I’ll have to turn on the lights in my room when watching a dark movie.

Amazing Ubuntu

I must say, I’m amazed how far Ubuntu Linux has come in the last 6 months.

When I tried 5.10 last october, it was nice, but it was still how I experienced Linux ever since I tried it out on the desktop – Flaky: WLAN didn’t work, DVDs didn’t work, Videos didn’t work (well… they did, but audio and video desynched after playing for more than 10 seconds), fonts looked crappy compared to Windows and OS X and suspend and hibernate didn’t work (or rather worked too well – the notebook didn’t come up again after suspending / hibernating).

I know, there were tutorials explaining how to fix some of the problems, but why working through tons of configuration files when I can also just install Windows or OSX and have it work out-of-the box?

Now, yesterday, I installed Ubuntu 6.06 on my Thinkpad T42.

Actually, I tried updating my 5.10 installation, but after doing so, my network didn’t work any longer. And in comparison with Windows and OSX and even Gentoo Linux where the fix is obvious or well documented with useful error messages, I had no chance in fixing it in Ubuntu on short notice.

Seeing that I had no valuable data on the machine, I could just go ahead with the reinstallation.

WPA still didn’t work with the tools provided by default. Now, we all know that WEP is not safe any more and in my personal experience is much flakyer than WPA (connections dropping or not even getting up). How can a system like Linux which is that security-centered not support WPA? Especially as it also works better than WEP.

To Ubuntu’s credit I have to say, that a tool, NetworkManager to fix WPA on the desktop was released post-feature-freeze. If you know what to do, it’s just a matter of installing the right packages to get it to work (and fixing some strange icon resource error preventing the gnome applet from starting).

Aside the connectivity issue (you won’t read any praise for NetworkManager here as a tool like that is nothing special in any other OS which is designed for desktop-use), the Ubuntu Experience was a very pleasant one.

Syspend to RAM worked (Hibernate didn’t – it doesn’t even hibernate). Fonts looked OK. And best of all:

I was able to play Videos (even HD with sufficient performance) and watch a DVD. Hassle-free.

Granted, I had to install some legally not-so-safe packages (with the help of EasyUbuntu which does the hard work for you), but you’d have to do that on any other system aswell, so that’s ok IMHO.

This was a real plesant experience.

And in the whole process I only got three or four meaningless error-messages or stuff not-working silently which is supposed to work according to the documentation.

I’m good enough with computers to fix stuff like that and I had enough time to do it, so I’m not very upset about that, but I’ll only recommend Ubuntu as a real desktop OS once I can install it on a machine and connect to my home network without cryptic error messages and as cryptic fixes (that NetworkManager-bug).

Still: They’ve come a really long way in the past 6 months. Ubuntu is the first Linux distribution ever that manages to play an AVI video and a DVD without forcing me to tweak around for at least two hours.

Computers under my command (3): terra

Final Fantasy VI (known as Final Fantasy 3 in the US) begins with two guys and Terra using some mech-like device to raid a town with the objective to find a creature referred to as an Esper.

You soon learn that Terra is in fact wearing a device inhibiting her free will and that she would never do something like that out of her free will – quite to the contrary.

When the three people find that Esper, the two soldiers die at its hands, but Terra survives.

The rest of the game evolves about her, the balance between magic and technology, love and humanity.

Terra is the main character in what I think is the best Final Fantasy ever done, probably because it’s in a way similar to Chrono Trigger (which is the second-best RPG ever done): Good thought-out characters, very free progression in the game (once the world ends, which is about half into the game), nice graphics and one hell of a story.

What really burns this game and especially Terra into your mind though is her theme sound. Even on the SNES it sounds really nice and in the end it’s what made me really interested in game soundtracks.

Also, I’ve blogged about a remix of that theme song. You should probably go ahead and listen to that to understand why FF6 is special to me and to everybody else.

Even after not having played FF6 for more than two years now, I still can’t get that theme song out of my head.

The computer terra is a fan-less media center PC by hush technologies. It’s running Windows XP Media Center edition and it’s connected to my video projector.

I’m also using it to manage my iPod (and I’m using a script to rsync the music over to shion both for backup and SlimServer access) and sometimes to play World of Warcraft on.

Even though the machine is quite silent, I can’t have it running over night, so it hasn’t that big an uptime: It’s right next to my bed and the sound of the spinning hard-disk and the blue power indicator led both keep me from sleeping at night.

Ever since I’m using the machine, I had small glitches with it: Crashes after updating the graphics driver (fixed via system restore), segmentation faults in the driver for the IR receiver, basically the stuff you get used to when you are running Windows.

I’m not complaining though: Even though the installation is fragile, my home entertainment concept depends on terra and usually it works just fine.

And after all, the original Terra was kind of fragile too (mentally and physically), so it’s just fitting that the same applies to the computer named after her.

PS: Sorry for the bad picture quality, but I only found Terra on a black background, so I had to manually expose her. Problem is: I know as much about graphics software as a graphics designer knows about programming in C. Anyways: It turned out acceptable IMHO.

Nice summer

This is what the Bundesamt für Meteorologie und Klimatologie (basically the official entity to tell us and the world how the weather in Switzerland is) has to say about the upcoming weather.

It shows a certain nicety in this summer: It’s neither just hot (like 2003) nor just cold (like all other years for the last 10 years or so). There are hot days like last week, but there are also the cooler ones like just now where it’s raining at comfortable 22 degrees celsius.

And just when you have enough cool weather and want the sun back, it’s turning around again just to get colder when it’s getting too hot.

I wish every summer could be like this.

Computers under my command (2): marle

While everyone keeps calling her Marle, she is actually the princess Nadia of the Kingdom of Guardia in what many people are calling the best console RPG ever made, Chrono Trigger

Chrono Trigger was one of the last RPGs Squaresoft ever did for the SNES and it’s special in many ways: Excellent Music (by Yasunori Mitsuda), excellent graphics, smooth game play, really nice story and: Excellently done characters.

Robo, Frog, Lucca, Marle, Crono, Magus and Ayla – every one of them has its very own style and story. Aside from Crono which is quite the ordinary guy, every one of them is special in its own kind.

The server marle is special on its own way too.

It’s not as outstanding as shion, but it’s special in its own way: It was the first 64Bit machine running a 64Bit OS I’ve ever deployed.

The OS was Gentoo linux (as usual) and the machine itself is some IBM xSeries machine equipped with a 3Ghz Xeon processor and 2GB of RAM, so basically nothing you need 64 Bit for.

It still was an interesting experiment to get the machine to work with a 64 Bit OS, though all that went completely uneventful.

Ever since deployed, marle is running at a customers site without crashes or other problems.

marle ~ # uptime
     11:56:13 up 265 days, 44 min,  2 users,  load average: 0.00, 0.01, 0.00

Not much happening there currently I guess. Also, it’s amazing how quickly time passes – installing that machine feels like it was only yesterday.

More disk space needed

Can somebody explain me, why my Mac OS X needs 4 TB of diskspace to encrypt my home directory which currently is about 15 GB in size?

Before I got this message, it wanted me to free another 1KB, btw. When I did that and retried, this message popped up. Unfortunately, I can’t reproduce that other message though.

Computers under my command – Issue 1: shion

Picture of the "real" Shion Uzuki

After yesterdays fun with one of my servers, I thought I could maybe blog about some of them – especially when they are kind of “special” to me.

Of course, the first machine I’m looking at is my PowerPC Mac mini which I called “Shion”, after the girl Shion Uzuki of the Xenosaga trilogy.

I don’t really have a very advanced naming scheme for my servers, but the important ones get names I tend to remember.

First it was people from Lord of the Rings (with Windows servers having names belonging to the evil people). Then, after I ran out of names, it was places in LotR and after I run out of those too, I began naming (important) servers after girls in console RPGs.

And of all the names, I guess shion is a very fitting name for a server. In the game, Shion is a robotics engineer and the inventor of that android called KOS-MOS.

And in my network, shion has a special place:

I initially bought the machine to run a SlimServer on it as my previous NSLU solution was not really usable as hardware for the heavy, perl-based slim server.

After I replaced the slim-server, I obviously installed a samba server on shion to serve the non-music files as-well. Back then, I only had one external drive connected to the server.

Next thing to get installed was OpenVPN which I used for quite a nice configuration allowing me transparent access from and to the office.

Shortly after that, I finally found a USB ethernet adapter which made shion replace my ZyAir access point. I also had to buy a USB hub back then and I decided to use the remaining two ports of that to plug in additional hard drives, leading to shion’s current disk space capacity of roughly 1.2 TB.

Then I installed mp[3]act (I’ve also blogged about it) and shortly after replaced it with Jinzora due to mp[3]act being quite bug-ridden and not in development any longer. (update 2013: links removed – mp[3]act is now pointing to a porn site and Jinzora is gone)

In all that time (one year of operation), shion never crashed on me. Overall, the stability of my home network went through the roof since switching all tasks over to her: No more strange connection losses. No more rebooting router and cable modem when lots of outgoing connections are active. No more inexplicable slowness in the internal network.

Shion does a wonderful job for me and I would never ever go back to any less flexible or stable solution.

Lately, I thought about maybe ditching her for a more powerful intel-based Mac Mini, but in the end shion is fast enough for my current purpose and I could never ditch a machine as nice as this one.

Flexible, Stable, Fast, Quiet and quite inexpensive. A machine worthy of being referred to with a name and a female pronoun.

Linux, PowerPC, gcc, segmentation fault

If you ask of me me to name the one machine in my possession I love the most, that’ll be my Mac Mini.

It’s an old PPC one, I bought a bit more than a year ago with the intention of installing Linux on it and using it as home-server/router. It’s not the quickest machine there is, but it’s the most quiet and it does its job like no other machine I ever had: Its Samba file server, OpenVPN Gateway, bittorrent client, mp3 streaming server, SlimServer, just all you could ever use a home server for.

From the beginning, it was clear to me: The distribution I’m going to install on the beauty was to be Gentoo Linux. This decision was based on multiple reasons, from hard facts like always current software to soft facts like nice command-prompts.

Basically, the machine just sat there after I installed it, doing its job. Until this week when I wanted to install some software on it – mainly the unrar command to extract some file right on one of the external HDs I plugged in (shion – that’s what the machine is called – is connected to about 1TB worth of external HDs).

Unfortunately, emerge unrar failed.

It failed hard with a SIGSEGV in gcc (or its cousin cc1).

Naturally I assumed there to be some bug in the gcc I originally installed (3.3 something – as I said: I did not touch the installation for a year now) and I tried to reemerge gcc.

… which ALSO failed with a segmentation fault.

I had no interest what so ever in reinstalling the box – I invested much too much time in its configuration. Cron jobs here, certificates there, home grown scripts everywhere. Even with all the backups I had in mind – I did not want to do that kind of job. Besides: Who tells me if it’s really a software problem? Maybe the hardware is at fault which would mean that my work was in vain.

Searching for “gcc segmentation fault ppc” in google is… interesting… but not really something you can do if you actually want a solution for this problem.

In the end, I mentally prepared myself to go on with the reinstallation – still hoping it’d be a software problem.

And by accident, I came across the Gentoo PPC FAQ which I more or less read out of pure interest while waiting for the ISO to be burned.

To my biggest delight, said FAQ was really helpful though as it had a question that went “Why does gcc keep segfaulting during ebuilds?

So it is a kernel problem! Of course I had preemption enabled! And that option – while working perfectly on all my x86 boxes – causes cache corruption on PPC.

Now that I knew what the problem was, I had two possible ways to go on: Quick and dirty or slow, but safe and clean:

  1. Recompile the kernel on the obviously defective machine, hoping the cache corruption would not hit or at least would not lead to a non-bootable kernel to be compiled.
  2. Boot from a Gentoo live-CD, chroot into my installation, recompile the kernel.

Obviously, I took the option 1.

I had to repeat the make command about 20 times as it continued to fail with a segmentation fault here and then. Usually I got away with just repeating the command – the cache corruption is random after all.

I was unable to get past the compilation of reiserfs though – thank god I’m using ext3, so I could just remove that from the kernel and continue with my make-loop.

Rebooting that kernel felt like doing something really dangerous. I mean: If the cache corruption leads to a SIGSEGV, that’s fine. But what if it leads to a corrupted binary? And I was going to boot from it…

To my delight, this worked flawlessly though and I’m writing this blog entry behind the rebooted MacMini-router. This time, even compiling the all new gcc 4.1.1 worked as expected, so I guess the fix really helped and the hardware’s ok.

Personally, I think fixing this felt great. And in retrospect, I guess I was lucky as hell to have read that FAQ – without it, I would have gone ahead with the reinstallation, compiling yet another kernel with preemption enabled which would have led to just the same problems as before.

Maybe the (very talented) Gentoo Hanbook guys should add a big, fat, red (and maybe even blinking) warning to the handbook to tell the user not to enable preemption in the kernel.

I know it’s in the FAQ, but why is it not in the installation handboook? That’s the place you are reading anyways when installing Gentoo.

Still: Problem solved. Happy.

SQLite on .NET CF – Revisited

Another year, another posting.

Back in 2004, I blogged about Finisar.SQLitem which at the time was the way to go.

Today, I am in quite the same situation as I was back then, with the difference that this time, it’s not about experimenting. It’s a real-world will-go-life-thing. I’m quite excited to finally have a chance at doing some PocketPC / Windows Mobile stuff that will actually be seen by someone else than myself.

Anyways: The project I blogged about is quite dead now and does not even support the latest versions of SQLite (3.2 is the newest supported file format). Additionally, it’s a ADO.NET 1.0 library and thus does not provide the latest bells and whistles.

Fortunately, someone stepped up and provided the world with
ADO.NET SQLite, which is what I’m currently trying out. The project is alive and kicking, supporting the latest versions of SQLite.

So, if you, like me, need a fast and small database engine for your PocketPC application, this project is the place to look I guess.