Fixing bugs of TikiWiki

Just now I did some hacking of TikiWiki on the LAKA site. First I added a feature - now RSS feeds from news articles can be selected by topic. Then I put two rss aggregators on the main Wiki page of the site - one with all articles on 'LAKA' topic and the other one for all articles.
In the process I discovered a bug in Tiki RSS lib that did not allow two RSS feeds to be put on the same Wiki page. I traced the call to a 'include()' directive that should have been 'include_once()'. This also caused another bug to appear there - variable $rsslib had to be declared global in the same module.
Now I only have to create some way to make a feed for 'all topics except LAKA'. That will be harder.

PS. Restoring Mailman and Postgresql was a snap. Today seams to be a better day for me :)

Reinstalling laka.lv

Today I ventured into the most annoying adventures a system administrator can face - reinstall. Fortunately this was a planned one, so I had just made all backups.
Problems started even before I did - all air circulation devices were broken in the company that collocates our server, so it was very hot there. I am not afraid of some heat unless it cooks my servers, so I went on with the reinstall.

While I was on the way to the location I asked the kind people there to make some kind of temporary banner page on one of their servers to say something like 'LAKA is being repaired now, come back in a few hours'. While they were doing that, it was needed to restart their corporate firewall as it stopped responding. And then ... the firewall didn't come up. Dong! Now imagine three men in a hot and tight server room struggling to untangle cables to get that firewall box out in the open to see what happened to it. Juk! After dissection the firewall claimed that it suddenly needed a video card. It's clear that the CMOS battery is dying on that thing. The way of least resistance was chosen (as people from all levels of the building were rushing in the server room every 5-7 seconds) and the Internet was returned to the people, and me as I was just going to finally start reinstalling our server.

As usually with 7+ year old hardware, the CD-ROM gave out in the worst possible case. Luckily there were some spares around. This servers case is something really interesting - it actually has a button to open the side of the case. Like a case eject :).

Installing Debian was uneventful showing the high level of this distro. In parallel I helped one guy to try to install SMB printer in Gentoo and soon I had to arrive to a conclusion that Gentoo sucks - nothing worked without a bit of tinkering. Even after installing ppds for the printer I had to unzip and install them manually. Juck!

Reinstalling needed programms was fast and seamless. The biggest problem was restoring the data. Unfortunately I made a full backup of the whole disk an that was a big problem. I mean 800 Mb is big if your downlink is less then 50 KB/sec :(. I spend a hour cutting out all the stuff I needed to revive the web and shell users. That was 150 Mb. Not wanting to waste my time waiting I wanted to put it on the download and head home to finish the thing remotely, but there was another problem lurking in the firery shadows - the firewall didn't want to give me back my IP.

I left hosters deal with that problem. When I left they were telephoning the authors of the firewall. Half an hour after I got home, the server was back online and I could start copying the reduced backup. Restoring Web and mysql services was a snap even considering migration to Apache 2 and MySQL 4 in the process. It just worked :)

After that I realized that I had screwed the user ids by copying old /etc/passwd and /etc/shadow over the new ones. Doh! I was save by some mysterious force that made backups right after the installation. I spend 20 minutes inching back into control of the system (I lost root and ssh would scream in panic because /etc/passwd had 0600 mode :P) and another 15 to carefully carry old users over to the new system.

Then I recovered a lost MySQL root password by looking at backup of my .mysql_history file. Doh!

Now I'll need most of the rest of the backup to get mail and postgresql back up. More waiting :(

Edit: Now this is getting ridiculous - the server that has the backup just shut down on his own. Ridiculous!

Testing Gnome based blogging

Today I tried out a few Gnome based blogging programms. Unfortunately I am still wrinting this in the web interface of the blogger.com. Why?

1. Gnome-Blog: a nice panel applet, one click blogging, looks perfect, but show an obscure error when trying to connect to blogger.com :( Bug reported, lets go on.

2. BloGTK: standalone programm, too many buttons for anything, no autologin, asks to enter 'url to the system' giving an obscure example with xmlrpc in it. could not figure out the correct url, gave up, reported a bug :P

3. theres is not 3 !!! only two gnome based blogger supporting tools exist and both were unable to work for me.

sometimes life just sucks :)

Introduction to Web Services for Remote Portlets

Introduction to Web Services for Remote Portlets

Untill now Service Oriented Arhitecture, UDDI or WSDL have been only buzzwords to me.

Imagine a web portal - this blog, for example. There small modules on the right showing few last blog items, favorite links and other stuff. These can be called 'portlets' (portal applets). If wanted to add there something like a weather report, where you could enter you ZIP code and get a weather report for your area, I would have to do two things:

  • Find a place to gather the weather data from

  • Write bunch of scripts to take data from that place and integrate it into my blog and also a much larger bunch of code to provide you an input form to enter your ZIP code and for my website to preserve that value

To solve the first problem there is the UDDI - a registry of premade portlets. To solve the second problem there is WSRP - an interface for integrating a remote applet into a web page (a portal) in a standart way. This would mean that I would only need to write one tag in my page and the web server (or, usually, the application contaner, like JBoss) will do the rest of conversion and intergation work.
Those corporate programmers are getting lazy by the day :D

LWN: LWN.net Weekly Edition for April 21, 2005

LWN: LWN.net Weekly Edition for April 21, 2005

Note: This page is currently only available to LWN subscribers (*hint*, *hint*)

This issue of LWN has a great insight into Bdale Garbee's thoughts about Branden and the future of Debian. I am a bit more optimistic then Bdale on this. I think that there is a definite need for a single project leader for Debian. This practise has been proven right by many open source projects (both successful ones with leader and unsuccessful ones with such). A leader provides focus and the trouble spot to prod the inactive parts of the project. Also public representation is a critical part of a leaders duty.
I see Project Scud as a great proding for the stallemate in the top leadership structure of Debian.

Anyway, I hope we will discuss it more troughtly at Debconf5.



Another good article is an introduction to kprobes - great stuff I must say. Now I really better understand how to debug the kernel if I'll ever need to.


Article about Progeny's Componentized Linux makes me think how I could use that for my side-work. More about that later. Creating a custom distribution from premade 'components' using a tool called 'component compiler' within 20-30 minutes. I've been planning to create such framework at my previose workplace (LinTech). Great minds think alike :)

Software patents

I have been involved in the discussions about software patents in Europe since the beginning. Today I feel that I need to summarize my idea about them.

The IT industry is about the author, about author controlling, selling (or sharing) his work. To insure that the author is in control, the copyright is used. Software patents override copyright. They take the power from the authors and put it in the hands of lawyers. And we - authors - do NOT like that!

5nizza & Cosmos

My Azureus just gave me something else to blog about: two wonderful new musical groups that I started to like recently - 5nizza and Cosmos.
Cosmos is a latvian project - five guys singing good old songs without music creating the melody by intermixing their voices. Imagine five beautiful voices singing together everyone of them having a different rythm and pitch, but all combining together perfectly.
5nizza is a similar russian project, but there are only two people in the group and they do use music for the backing. 5nizza also writes all of their songs which is a nessesity as both singers sing almost at the same time, one frequently continues a word that the other one has begun. The text is also nicely composed to have multiple meanings depending on where you divide the words or phrases. An example of such style you could see in a Ramshtein song - "Du hast mich (You hate me) .... Du hast mich gefragt (You asked me)"

Note to self: I really hate German spelling :P

Start with a killer

To start the blog not with an obligatory 'Let's start this' post, but with something worth reading, I want to present the mighty nildience (null audience) the best Linux audio playing app: Amarok.

  1. Collection of your music based on the top directory - i.e. you just say 'my music is in /home/aigarius/mp3' and it rebrowses that dir each time it starts to find new music.
  2. Automatic rating based on play/skip ratio - just listen to what you like and skip songs you don't like and soon Amarok will be able to tell the difference.
  3. Get lyrics in 1 or 2 clicks - I love this feature.
  4. Control the player regardless of your current app - shortcuts with 'Windows' key work everywhere.
  5. Very nice playlist management within your music collection.
  6. Least played songs - either to try something long forgotten or to free your hard drive.
These are the features I like the best about Amarok. Please comment on what you like to find in your audio player.