No comments

I have had many requests to enable comments on my blog, but the reality is not so simple… In fact, it would not be enable comments but rather implement comments. During the development of the Tree Framework (on which my blog runs), I had a primitive commenting system working, but for the version that I fielded, I decided not to use it because it was insecure. I do realize a blog without comments is not really a blog, but the Web is a wild place, and leaving a website on its own with unprotected HTML forms is asking for trouble. Spiders can generate canned spam comments faster than I can delete them.

But rest assured, comments are on the top of my priority list, and I have identified a very neat way of securing the whole thing: ReCaptcha. For those too lazy to click the link, ReCaptcha is a system that aims at validating whether the user submitting a form is human or not by having them solve a captcha; a test computers are notoriously bad at. We have all encountered such a thing when registering on a website, but ReCaptcha adds to the concept by using character blocks from books that are undergoing digitization. When the computer is unsure of the result of an OCR (optical character recognition), it submits the ambiguous text to the ReCaptcha system so a few humans can confirm the answer. What an ingenious way to harvest brain processing power.

Oddness and superficiality

The person that sits behind my cubicle just asked a newcomer whose voice I do not know how she was. She replied positively and returned the question just to receive the answer she was probably expecting: ” Fine, fine, the long week-end is coming.”

I have never heard anyone saying their day was “pretty shitty as usual” or “was fine until I met you” and probably never will, at least not in this environment. If you are not willing to respond with a negative, it makes the question invalid, since the same answer will implicitely ensue. It turns it into a statement, a statement of politeness.

When I approach someone, I try to avoid this idiom and come up with another way of being polite. Asking questions whose answer you do not care about because you already know is quite rude in my opinion, yet, I hear this one going through every single hour…

For my own posterity

I doubt very much my descendants will ever look into what I did with my free time during the course of my existence. Chances are it will not interest them, because few people enjoy listening to elders talk, especially about programming. But for myself, for my own posterity, I though it would be great to have a paper copy of all my projects. Not only to add a fair amount of resiliency to my backup system but also for history’s sake. Some will build murals with photos of the many vacations they went on. I printed hundreds of pages of uncommented code, organized them in nice binders with a cd-rom copy and stored them on shelves. Now anyone can browse through, and see for themselves that it was true I wrote 35 pages on a communication protocol that will never see the light of day just for the fun of it.

Most parents do keep some tracks of their children’s evolution, but the bookkeeping comes to an end once they quit the family’s nest. After which, it becomes financial institutions who remain keen at maintaining an history of one’s existence, a financial history. Although most of us do fancy looking at the many drawings we made when we were in pre-school, we have to admit that they all looked alike and were of relatively poor historical value (unless you grew up to be a graphic artist). What is the most interesting is the intellectual work that comes later-on, those painful essays in high-school, when producing a 150 work text was a chore. If you actually abstract the constant boredom while doing them, you can easily go back trough time and get a glimpse of how you thought back then, how different you were.

By printing my projects, I will be able to repeat the exercise a few years down the line, albeit with a much deeper analysis, as I never pretented to be a writer, but I do pretend to be a progammer and looking at how I programmed in the past, can surely help me improve even more in the future. Even now, I do go back to my previous creations, mostly to dig out a solution on a pattern I remember dealing with in the past. My work is evolutive and most of the ideas that I am implementing as I write these lines were though of a few years ago during the course of another project. Sadly, those ideas very often came with the realization that the work I did up to that point was inherently flawed, and ended up causing the abortion of that current project in most cases; I suppose it was a necessary step. After all, the relativity theory came from Newton’s celestial mechanics, which in turn was built upon the work of many the many obscure astonomers of those ancient times. The human race thinks upon its own intellect and creates upon its previous creations. We are long past the times where seing a boulder going down a slope gave someone the spark of genius that was the wheel. Things are much too complicated nowadays and history helps us avoid repeating the same mistakes, but it also helps us avoid reinventing the wheel every time.

How I came to virtualize my router

A year or two ago, I took it upon myself to reverse the trend of computer proliferation in my life. I offloaded the free support that I used to provide to my friends to other knowledgeable friends, I got rid of many machines that were just sitting there for the looks (they were running Folding@Home) and finally centralized all my activities on one laptop instead of having both a desktop for power and a laptop for mobility.

All was great, and the return in time was direct and fast. The amount of effort invested every month maintaining hardware and software went down dramatically. I once read that you need one technician per 50 machines, which makes sense if the people using computers are not so savvy. But you sometimes still need a few machines, be it for testing, running platform dependent software, or just fooling around with another OS. For that problem I found virtualization to be the solution. While it will spawn a host of new difficulties, it does cut down on the hardware woes and once you tame it, it shows lots of potential; so much that in the process of making physical machine virtual, I had the idea of applying the same philosophy to that grey and blue Linksys box that breaks from time to time and requires its fair share of maintenance and configuration.

So there I am with a router that does not exist physically. Friends come to my place and look for the device to hook their laptop to (no wireless for now), but they get directed to my lab machine. They then give me an “are you sure?” look, but hook the cable anyway, and then proceed to using internet, charmed by the “magic black box” phenomena.

Making a router virtual, while not so trivial, does have a few advantages:

  • One less computer if you use a machine that is on anyway (lab computer in my case).
  • You get to use better routers like Smoothwall, m0n0wall or Fresco without a standalone computer.
  • Less power consumption.
  • You can backup your router.
  • Essentially free
  • It is a fun project.

The setup is actually quite simple, I will not go through the whole process command by command (I’ll keep that for later) but here is an overview of what you will need.

  • Time
  • Patience
  • A computer with enough network interfaces.
  • An OS (I use Ubuntu 8.04).
  • A router distro (Smoothwall, m0n0wall, Fresco, etc.)
  • VirtualBox (Or any other emulation/virtualisation software you migh prefer).
  • Bridge Utils or any other bridging software.

And here is what you will do:

  1. Bridge all your network interfaces but leave one outside the bridge, it will be the outside interface. Make sure other programs cannot use it !
  2. Install VirtualBox.
  3. Map you bridge and outside network interface with virtual interfaces on VirtualBox.
  4. Virtualize the router distro on VirtualBox
  5. Configure the router like is was a real one.
  6. Unplug your old router, put it back in its box and keep it just in case…
  7. Admire your work.

As for wireless support, I do not yet possess a wireless adapter that is compatible with madwifi and can be used in master mode; it is on the way. However, I am unsure whether I will be able to bridge to it or not as I have come across many forums posts of people trying without success. If it is a no go, then maybe making the wireless network a different subnet and routing traffic will do the trick…

Cable management

I recently found a nifty solution for the crippling problem of cable management. It might not be suitable for super computers but it does work for my desk.

It was built by screwing Ikea Antonius coat hangers to the underside of the desk using long enough wood screws. To give it a bit of stability, I used a hollow tube (like piping cut to length) for the hangers to sit on.

Here are a few pictures:

Simple and inexpensive…

Due to popular demand, here is a diagram I cooked up in paint that better explains the mounting mechanism. I have no particular suggestion for the length of the pipe except that it should be long enough for the hanger to clear the table (so you can slide the cables in). If my memory is correct, mine are 8cm. As for the screw, just make sure it is long enough so it can drive a good 2cm in the table.

Sorry for the lack of information, next time, I will be more thorough in my description and will take more pictures.