PHP 5

As you surely know, PHP 5 has been released. Actually, it’s already 5.0.1.

What you also may know is that Gentoo’s dev-php/mod_php package was promoted from -x86 to ~x86. This means from broken to unstable in Gentoo-terms.

This means that I can now make some tests with PHP5 which I already began doing: I’ve upgraded PHP on our developement server to 5.0.1 and it’s working quite well so far. The only problem I’ve come across is this stupid code in a osCommerce installation:

class something{
  function something{
    // do something
   $this = null;
  }
}

New or old object model in PHP: This is just something you don’t do. Not in PHP, and certainly not in any other language. You should not assign anything to this, self or even Me (or whatever the implicit pointer to your own object is called in your language).

Strange preconfiguration

Ever since I’ve updated our in-office Gentoo-Box to Samba 3, I had very bad performance (throughput wise). And with bad performance I mean at most 200 KBytes/s on a 100MBit network.

For quite some time I thought that it must be my client machine, so I rested the case. Till today, where someone else complained about really bad performance. So I began investigating.

At first I had one of our ultra-cheap switches in mind, so I tested the performance using FTP. Too bad: full speed there, so it must be a Samba problem.

What was really strange: Write performance to the server was great. It was just reading that took so incredibly long. So, armed with this information I did some googling and found … only vague stuff. While there are some people with the same problem as myself, they are always told that it must be a hardware or windows problem (the two easy solutions) and there was no further discussion in all cases.

Somewhere I found the tip to set the following in smb.conf for maximum performance:

socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

I went and looked, but the setting was already there. Too bad. The next thing I did was to comment the line out and restart samba:

#socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

And you will not believe it, but it helped. The server is back to its old performance with 8 Mbytes per second which is a good value considering the cheap equipement involved.

Problem solved. Culprit: Strange preconfiguration by Gentoo. Why this helped? No idea! Why the wrong setting in the first place? No idea either. Why the wrong tip to put this option into smb.conf? Don’t ask me. I’m just happy, it works again.

Gentoo and Jabber

Already in 2002 I did my first experiments with jabber and I really liked what I saw when still reading the documentation. Setting up the server was a real pain, but eventually I got it working.

Then came the thing with our server and having in mind the hard work needed for setting up jabber, I deceided not to rebuild the jabber-configuration – even more so because aim-transport still does not support those fancy iChat-AIM-Accounts while Trillian does.

But today after having seen that iChat in Tiger is going to support jabber, I finally deceided that adding my beloved server back would be a cool thing…

And the whole adventure turned out to be another point where Gentoo shines above all other distributions: The ebuilds for jabber and the two transports I am using (AIM and ICQ) where already beautifully preconfigured. And not only that: They where current too (hint to debian… ;-) )

One thing did not work at the beginning: I could not register with the AIM-Transport. A quick glance at the configuration file of aim-t showed me that the preconfigured config file uses another port (5233) than the recommended settings in the main configuration file (5223).

All in all it took me about 10 minutes to get my old jabber installation back. With current versions of all the tools involved and without writing own startup scripts or other fancy stuff. This is one of the reasons I really like Gentoo

Oh… and in case you ask: My Jabber-ID is pilif@chat.sensational.ch. It’s not listed in the global user directory.

And if you’re asking what client I’m using: Though its interface may need some improvement, jajc is in my oppinion the best client you can get if you are using windows

PHP scales well

I think PHP scales well because Apache scales well because the Web scales well. PHP doesn’t try to reinvent the wheel; it simply tries to fit into the existing paradigm, and this is the beauty of it.

Read on shiflett.org after a small pointer by Slashdot into the right direction. This guy really knows what he is writing – or at least it seems to me as I think exactly the same way as he does (which is a somewhat arrogant way of saying things, I suppose :-)).

All-time favourite Tools

Who doesn’t have them? Those all-time favourite tools. It’s not just software, it’s passion. Those tools are tools that you always have to use. Tools where all objectivity seems to fade away when it comes to making recommendations. Tools where you actively monitor (or even participate in) the developement. Tools where you, though they are free, gladly donate some money. Tools you love.

Of course, I too know of some tools. And this is my list (in no particular order):

  • Exim is an UNIX MTA (mail server). It is not only extremely configurable, it’s even easy to do so. Back in 2000, Exim was the only MTA capable of being used in a environement where all accounts are stored in a MySQL database. Since then I am using Exim for all my mail serving needs and I still have not stopped discovering new ways the incredibly flexible configuration scheme can be used to do even fancier stuff. But the greatest thing about exim is it’s creator, Philip Hazel. Phil is a ingenious programmer. A really pragmatical one. I love to read his emails on the exim mailinglist. I love to see his solutions that are quite often so much easier than what others suggested but leave nothing to ask for at all. Btw: During summer 2001 I even extended my Accounts-in-MySQL-Configuration and put it on the web as a .txt-File. Oliver Siegmar was convinced enough to build XAMS on it. I really like Exim
  • PostgreSQL came to my rescue when I desperatly needed a RDBMS that really merits that name. I constantly run into limitations of MySQL, so I was on the lookout for a better alternative. With the TOAST tables of PostgreSQL 7.1, it was finally possible to have length-unlimited columns which I needed in the webapplication I was working with (for storing long comments), so it became a real solution. Since then PostgreSQL never failed me or any of our customers. In my journey with PostgreSQL I learned a lot about programming database systems while reading through the posts of people like the ever so conservative Tom Lane and others. What a great community. What a great database server!
  • InnoSetup (and it’s graphical frontend ISTool) is a easy to use and extremely powerful generator for Windows Installations. I know that you are supposed to use MSI these days, but InnoSetup works, has any feature you could dream of and – that’s the point – is terribly easy to use. My journey with InnoSetup is a long one. It began back in 1996, where I was the first translator at all (now long outdated) and it goes on through nearly all releases till’ today. Inno’s programmer, Jordan Roussell is another one of those extremely talented ones. Reading his posts in the support newsgroups is a real pleasure – reading Inno’s sourcecode is very enlightening. How powerful such a little tool can be!

And you? Do you have such tools in your toolbox? Do you use the words love and software in the same phrase? I certainly do!

.Python

This Paper was featured on Slashdot today. It’s about an implementation of Python based on Microsofts CLR. The following quote speaks for itself:

I wanted to pinpoint the fatal flaw in the design of the CLR that made it so bad at implementing dynamic languages. My plan was to write a short pithy article called, “Why .NET is a terrible platform for dynamic languages”.

Unfortunately, as I carried out my experiments I found the CLR to be a surprisingly good target for dynamic languages, or at least for the highly dynamic specific case of Python. This was unfortunate because it meant that instead of writing a short pithy paper I had to build a full Python implementation for this new platform […]

This is very interesting. Imagine having access to all the Tools, Components around .NET from a wonderful language like Python. But it does not end here: As your Python code in the end gets compiled to MSIL, you can even create libraries in Python and share them with users of languages like C#. This is nice!

Too bad I don’t speek Python. But then again: If it’s working with python: What about Perl? PHP? Unix Shell [;-)]?

Apocalypse 12

It seems like Larry Wall has done it again and released Apocalypse 12 (linked to the print view as you definitely want to print it out). The Apocalypses are nothing religious, but Larry Walls ideas and definitions about the next version of Perl (although I am inclined to call it something else as it’s going to be quite different – if it’s ever released).

The Appocalypses are quite nice to read. They are not only great from a technological standpoint but from a linguistic and humorous one too. If you have no problems reading 72 pages of technical definitions on quite a high level, go for it and read it. It’s a real pleasure and I looked forward to this for over a year now

Quote of the day

While reading LWN today, I stopped at the following quote as posted in this weeks PostgreSQL Weekly News:

While there was some subversive discussion about source control
programs arching through the mailing lists this week, those with an eye on
the CVS repository noticed several interesting changes come down the pike.

With the whole war going on about Subversion or arch being better, this phrase is just great.

KDE 3.2 Beta 1

I finally found some time to compile the current Beta Version of the upcoming KDE-Release.

Although it needs quite some more time to start, the overall speed-impression seems much faster.

The user expirience can be explained by one word: slick (very slick, actually).

What a nice work!

I’ll definitely post something more as soon as I finished reviewing it

Many thanks to the KDE-Team for this great release – actually the first one where I not only like the functionality, but also the look of it. Very nice indeed.