Thursday, February 24, 2005

The power of the segfault

Segfault. No one likes to see their work go down in flames as an application crashes. As a user you don't know if your work was lot, but your mode of concentration is killed and it is just a depressant.

Looking back over the years without realizing it at the time, but whenever I would encounter an application that would segfault on me I would begin to look for an alternative. The more it segfaulted on me the more I would look. Maybe I didn't loose any data, but I will not honestly know. Some examples:

Windows (1997-1999)- Not much to say here, after a year or two of this I switched over to Linux full time. Why? The great driver support? Fantastic multimedia capabilities? It was free? Well maybe that last one, but at the end of the day it didn't segfault on me.... ever.

Gaim (1999) - It segfaulted so often that I made my own instant messanger called Kaim with one of the primary "features" being that it didn't segfault. Even today it still segfaults. Kinda sad.

KDevelop (1999) - It would crash on my leaving my projects in unstable states. I quickly abandoned it and now only use the command line (the problems in kdevelop I have sense found out have long ago been fixed).

Konqueror (KDE 2.x) - Using it as a file manager it or some plugin (thumbnail?) at the time would segfault on me. I used the command line more and only recently have again started using Konqueror as a filemanager trusting it more and more ( i.e. it doesn't segfault ).

Mozilla (2000-2003?) - It crashed on me... a lot, so I didn't use it. Nuff said. (go Konqueror!)

Doing a quick poll around I have found many similar stories from other people of how they no longer use application X because it crashes.

What do these all have in common? Several key things:

1) Applications can *not* segfault if they want to keep their user base or grow. If you discover a segfault in your application it should be made a top priority to fix it. Extra effort should be made to protect against segfaults. Simple checks throughout your code to check pointers before use in function should always be done.

2) Applications that do segfault will be abandoned. Not only will they be abandoned, but users will share their distrust of that application with other users. And just as damming is that users that give up on an application are highly unlikely to go back to said application and even if they do it will be very slowly. So even if you fix your application it will be very hard to earn your users trust back.

3) There is one thing that can save applications. A slightly new look/direction and a new name. Sounds silly you say? Take a look at the browser you are probably using. If you are using Firefox, ask yourself why Firefox suddenly took off. Why didn't Mozilla have half the numbers Firefox did? It was because of word of mouth. As Mozilla was still being developed it was in an unstable state. So users that tried it out (like me) got a little sour taste and decided they didn't really want to use it. Not only that, but we then didn't tell other users about Mozilla. With Firefox they took the already heavy developed, debugged engine, *removed features* and put a new name on it... and it took off like a rocket. This time people checked out a "new" application and were blown away. Nice, clean, and it didn't crash. Because it was "new" to the user they were able to put aside their feelings about Mozilla and look at it new. And of course they then told all their friends how great it was. Yes Mozilla was great too, but only a little better then the previous version, which was only a little better then then one before it. Firefox was brand new and fantastic out of the gate.

So what does this mean for KDE?

1) We should ship releases without any open segfaults or as few segfaults as possible.

2) Rebranding can be very powerfull. If Gnome changed there name and changed to a less "ugly" default theme* (they have already changed their focus to be heavily user oriented) they could easily capture many new users simply because people would go and try it out for the "first time". Konqueror the web browser and Konqueror the File manager should be clearly separate applications and not marketed together (even if on the backend they are). You could even give them two new names. People would check them out as new applications. I know that there is some work in this direction in kdenonbeta and i think it is a good idea.

Are there any application in KDE that you no longer use because it segfaulted on you in the past?

* Personal rant here. Every gnome developer I know does not use the default gtk theme because they like something else more and yet they force the default theme upon all their users. Is that ironic? Can they really be that stupid?

Friday, February 18, 2005

Why Microsoft's market share wont grow

Recently in a interview with Microsoft's CIO Ron Markezich he said the following quote:

"Our users are the admins of their machines. They can load whatever software they want on their machines..."

At first this comment might not seem like such a big deal, but it shows a fatal flaw at Microsoft. Users should be able to operate applications without requiring system level access and users should never be able to cause application problems for any other user on the system. Allowing applications to requiring administrator access to the computer you are using is a fatal flaw to all of Microsoft's operating systems. Until that problem is fixed, Microsoft will never be able to capture more of the computer market.

In unix user applications and preferences are not allowed to interact with other users applications or settings. The user "bjohnson" on a Unix system typically will have write permissions to the their home directory /home/bjohnson and to /tmp for temporary storage. /tmp is almost always cleared on boot and sometimes more frequently. Application settings are placed in hidden files (such as .mozilla ) in users home directory. A user can even install applications into their bin/ directory in their home directory (such as /home/bjohnson/bin). On a users desktop no application by default is allowed to run with root privileges (root is Unix's administrator user account). Any tools that helps to configure hardware will prompt the user for the root password and temporarily have root access to make the system changes. Because of this a user can do just about anything without harming other users or the system itself. Users can only hurt themselves, such as accidentally deleting all their files, but the system will prevent them from deleting all the files on the computer.

On a Microsoft operating systems things work a little differently. Only recently have users been given the equivalent of a home directory. User bjohnson's home directory now is located in: C:\Documents and Settings\bjohnson\. But bjohnson isn't limited to having only write access to that directory, but many more. In Microsoft Windows there are a number of different temporary directories. Applications can and often do place files all over the system including the systems library directory under the assumtion that they have access. Unfortunately not every windows application out there works with more then one user. Windows applications save their settings in the system wide registry. If one user sets the system wide settings to an incorrect value then every users has a problem. Because of that users must reley upon applications uninstallers to remove its settings from the registry, but often leave a few behind. This leads to registry that grows and grows over time and the only option is to reinstall the operating system. Too many applications can only be installed in C:\Program Files\. Even if you can install an application into a users home directory the application will still want to place some libraries into a system library directory. Many applications at run time want write access outside of the home and temp directories forcing users to give all their applications access. Some windows application that run in the system tray have administrator access when there is no reason they should, leaving an easy to exploit way for users to crack the system and get administrator access. A good example include some anti-virus software which runs all the time in the system tray. The system-try GUI application should be a client and connect to service which is running with administration rights. GUI applications that have administrator rights are one of the easiest things to crack giving any process administration right and control over the computer. On a Microsoft's system a user can very easily cause harm to the system and other users. Some simple examples include installing thousands of fonts in the system folder or putting millions of entries in the system registry. Both are perfectly allowed as a user, but causes the system and other users harm.

By now it should be clear that a user having only write access to essentially one directory (their home directory) is a good thing. Here are some more advantages:

  • When doing a backup in Unix one simply makes a copy of an entire users directory. No hunting around for Microsoft Outlook files somewhere in C:\WINDOWS\, making sure to grab the background that was put in C:\ or grabbing the Adobe plugins from C:\Program Files\Adobe\Plugins\.

  • Fixing application that users broke (by messing with the settings or installing a broken plugin) is also much easier. All that is needed is to remove all the settings for that application (in unix that is typically one file) or just removing the plugins. This will revert the application back to its initial state.
  • Users love to download little applications, utilities, and games. If users only have write access to one place these applications can't leave junk all over the system and are forced to only clutter up the users home directory. Administrators then have a easier job of maintaining the systems and let the users manage their home directories.

So what does the original quote have to do with all of this? Until Microsoft internally force their own developers to use an user account and not be give administrator access there will always be problems with applications requiring to do whatever they want. If developers have administrator access they wont fix Microsoft's applications, and if Microsoft's applications don't play nicly with multiple users (or access to only one directory) then third party developers will never bother to fix their applications. Much worse is that until users only have access to their home directory they (or much more likely spyware) can corrupt the system. And corrupted systems are expensive to fix.

It can be argued that this problem for Microsoft is good for Linux because it is now known that Vista will not force users to only write to home directories and virus's/bugs/spyware will continue to exists and be permitted to corrupt the rest of the system and user accounts. Even worse, applications will continue to litter the filesystem and registry forcing complete re-installs of Windows every six months to keep the system clean. On enterprise systems for Microsoft Windows to continue to grow it must be able to handle more then one user. Until Microsoft Windows only allows users to write to their home directory Windows can't replace Unix, and its market share can't grow like their sharholdes wish it would.

Wednesday, February 02, 2005

CPU Fan noise

Over the past year or so I have been upgrading my computers to use quiet components with very satisfactory results (Sonata case's seagate drives, etc). I recently had to purchase a CPU fan. Attempting to find reviews of CPU fans is hard. Even the reviews from just six months ago are outdated and I was hard pressed to find the fans for sale anywhere. But more then looking for a good fan I wanted something that would be quiet. Finding that kind of information was turning into a very big and annoying task, until I discovered that on they allow you to search the CPU fans by noise level! How fantastic! I was quickly able to find very quiet fans that they had instock and quickly determine what one was best for me. So if you are looking to replace your CPU fan or get a new one that is quiet check out newegg which include that information and let you search on it.

Popular Posts