Strange things happen…

On Fridays, I work from home, to prevent wasting time commuting. So today, I started out fresh, ready to rock and roll. But alas, I was off to a slow start.

To access my company’s resources, I use a Virtual Private Network (VPN). In particular, I use the VPN client software from Cisco on Ubuntu GNU/Linux. This piece of software has the tendency to break on every kernel update, however 😦 Yes, you guessed right, this week I received a kernel update to 2.6.24-17.

When I previously upgraded Ubuntu to 8.04, I received kernel 2.6.24-16 and then the VPN client broke as well. I had to apply a patch, which didn’t work: it couldn’t apply all changes. I then manually fixed the code to make sure all the changes in the patch were applied. And then the VPN client finally worked.

So I expected another one of those sessions. But this time, googling turned up nothing. Since I’m close to a deadline, I decided to simply restart my computer and choose the 2.6.24-16 kernel from the GRUB boot menu. Since it used to work with this kernel, I expected it to work now. But no such luck. I still got an error about the Connection Manager being unable to read the connection entry.

Getting a bit desperate, I redid the VPN client installation. Now it worked 😀 Feeling lucky, I rebooted into kernel 2.6.24-17, and it still worked. Sometimes I just don’t understand computers…

Update 2008-08-15: Check out this page with Unofficial Cisco VPN Client Updates for Linux.

Broken windows

In my previous post, I told you that I encountered some non-optimal code. (Yes, really!) You might wonder what I did about that. Well, I fixed it, of course.

Should I have left it alone? After all, I was in the process of implementing this super-critical feature that this super-important client needed super-urgently. Did I waste time on something not-so-important?

Well, yes and no. Yes in the short term, for sure. But I like to think no in the long term. And I’m in for the long haul. I work on a software product, not a project, so I can actually afford to take a long term view.

I’m not alone on this one. The excellent book The Pragmatic Programmer talks about this as well. The authors call it fixing broken windows after a landmark sociology study:

Consider a building with a few broken windows. If the windows are not repaired, the tendency
is for vandals to break a few more windows. Eventually, they may even break into the building,
and if it’s unoccupied, perhaps become squatters or light fires inside.

Or consider a sidewalk. Some litter accumulates. Soon, more litter accumulates. Eventually,
people even start leaving bags of trash from take-out restaurants there or breaking into cars.

But fixing the one broken window prevents other windows from getting broken, claim the authors.

There has been considerable criticism on the broken window hypothesis by other sociologists. And I know of no scientific evidence for the effects of fixing broken windows in software. But the hypothesis makes intuitive sense to me. And so I keep fixing broken windows whenever I encounter them as much as possible.

By the way, if you haven’t read The Pragmatic Programmer yet, then stop wasting your time reading silly blogs, and go buy this book. You will want to keep it along with other classics such as Design Patterns, Refactoring, and The Mythical Man-Month.