Thu, 26 Jan 2006
I have to admit, it's getting better,
a little better, all the time ...
OK, things are getting a bit better here. I am still pretty busy, though, so I am only posting an image taken few days ago when Iva tried to use her toys with snow instead of the sand.
Sun, 15 Jan 2006
I am sorry, but I will probably not have time to write anything to this blog in the next few weeks. In short, I am a full-time father now while trying to do at least part of my regular job as well.
Thu, 12 Jan 2006
Yes, Slashdot can be sometimes skewed, but I think most of the time it is skewed the opposite way the author of the "paper slashdot" thinks - there are gadgets advertisements pretending to be a normal story, there are stories which are meaningful for U.S. citizens only, and so on. Not "news for nerds".
Perhaps a distributed moderation not only for user comments, but for the stories themselves should be created? I mean something like K5 had for years. What do you think about the selection of stories on /. ?
Wed, 11 Jan 2006
Using BerkeleyDB in Perl
I have rewritten parts of the software for access terminals so that it uses BerkeleyDB for the internal communication and data storage. It used SysV IPC before - semaphores for locking and shared memory segments for data transfer. SysV IPC has a drawback that the key value has to be set explicitly, so that if multiple installations of the same software are to be run on one host, the keys have to be carefully set to different values.
Since I use BerkeleyDB Hash database as cache of allowed cards, I have decided to use the BerkeleyDB for other things as well - the Queue database instead of SysV SHM as a queue of operations, and a dummy Hash database in the Concurrent Data Store mode for locking.
There is a minor glitch in the Perl bindings to BerkeleyDB - when this module is used with Recno or Queue databases tied to a Perl array, the shift operator does not work as expected: It returns and removes the first value of an array, but does not shift the indices of the array members:
@a = (1, 2, 3); shift @a; # Expected: @a = (2, 3); # Actual results: @a = (undef, 2, 3);
The renumbering would be too expensive in BerkeleyDB by default, so I expect it has been omitted for performance reasons. The solution is to use the Recno database opened with -Property => DB_RENUMBER option, which does exactly what is expected. I hope I will get time to submit a patch to the (rather incomplete) BerkeleyDB.pm documentation.
Mon, 09 Jan 2006
My car is back
My car is finally back, with working ignition computer and airbag control unit. It is quite a different driving than driving that old Favorit. They only wanted me to pay for the airbag control unit I have ordered, and nothing else. I know firmware upgrades can go wrong any time, so I do not blame the servicemen for this glitch.
On Wednesday, the HDD in my workstation crashed - firstly it looked like a flaky cable (I rebooted the system), but after few minutes (while doing an emergency backup) the drive disconnected from the bus and never came back. I tried to do a classical refridgerator resuscitation, but I was only able to make the drive visible on the bus, but it did not spin up.
Fortunately, I had a few weeks old backup on my secondary HDD (did you know that cp -lR and a local rsync can make a decent HDD-based backup system?). O&G managed to deliver a new HDD the next day, so I am moving my system back to the usable state.
It is interesting how a not so big company like O&G can often provide better support/replacement parts than big players like HP, IBM, or even SGI, and for much less money.
In the meantime, the same drive in Odysseus failed the S.M.A.R.T. self-test. I have removed it from the RAID-5 array and inserted it back, and it synchronized itself correctly. A subsequent self-test was OK as well (and no sectors were relocated), so I hope the drive will work correctly. I already have a set of new HDDs and a 3ware SATA controller for Odysseus, but I simply do not have time to do the upgrade.
Wed, 04 Jan 2006
Driving the dustbin
As I wrote few days ago, my car is being repaired, they are trying to resuscitate the injection computer after the unsuccessful firmware upgrade. They lent me a Škoda Favorit, age of which I estimate to 15+ years (it is the older series of Favorit). The life with this dustbin^Wcar is often really interesting ...
Firstly they put the new winter tyres on this car. However, one tyre was faulty, and I had to change it. Interesingly enough, the car had a spare tyre and tools. However, the lifter was broken, so I had to call the owners for help anyway. They arrived, even though it was in the evening, they changed the wheel, and took the faulty one for repair. So now I have one front wheel with a winter tyre, and the other one with the universal one.
I have realized that the spare tyre had too low pressure. So I wanted to inflate it. However, the cap has not been removed for a long time, and I was not able to unscrew it by hand. Fortunately they had pliers inside the car.
After the Christmas, we wanted to visit my parents. I wanted Pavlína to drive, so that I could drink some wine with my father :-). However, we realized that the driver's seat cannot be fixed in the front position, so she could not reach the pedals. I had to drive then. Fortunately we have found about it on the way there, before I had a chance to drink any alcohol.
The dash-board lights are only partly working, so in the evening I can see what time is it, but not what speed I am driving at.
Also the properties of one winter tyre and one unviversal tyre on the front wheels are interesting, especially these days, when I often have to drive on a snowy road. I have checked that hard braking on the snow is OK (fortunately), but accelerating or parking in the deeper snow can be problematic sometimes - because of the balance gear, one wheel starts to skid. I was even not able to drive up to the not so steep hill on the way from my parents' house.
I hope I will have my own car back soon ...
Tue, 03 Jan 2006
I have implemented a program for recognizing scanned forms, which can be used in IS MU (our information system) to recongnize and evaluate the exam forms. It seems some students are too stupid to read the instructions and fill in the form in an appropriate way:
... or this one:
Interestingly enough, my program, even though it is not designed to recognize a hand-written text, did recognize the digit "3" in the image above. However, it is sad that university students are too dumb to fill the form according to the instructions.