Tuesday, June 13, 2006

Mac OSX vs Linux/FreeBSD

A few years ago, (sometime in 2002/2003), Apple Computers released the latest version of their Mac operating system. The Apple mac is a favourite platform for the artsy, graphics types. I really can't tell why because the availability of good software for that platform is difficult to find. In any case, the latest Mac is very different under the hood from previous versions. The engine is now Unix based. The name of the code that runs the new Mac platform is darwin which is based on FreeBSD and tries to maintain compatibility.

What made the new version of the operating system
historic was that it was a completely new product. Not an upgrade of version 9, but a version built from scratch. The new Mac OSX was based on a free BSD version of Unix, namely FreeBSD.

For the most part, people don't care much about operating systems, other than when they obstruct productivity. An operating system should make it easy to manage programs and files. It should allow programs to play fairly together and manage resources so that things run smoothly without too much hassle. Most Mac people don't know what's going on in their computers so when things go wrong, and inevitably they do, all they can really do is switch everything off, sigh, and then turn everything back on again, hoping that the ghost would have died with the lack of electricity. Windows people do the same thing.

The new Macs are actually a treat for Unix people to use. In fact, Apple has released a server version of the operating system. This is new. The old Mac OS was nowhere near a server class machine. Now the operating system, because it's based on FreeBSD, a mature server operating system to begin with, has entered into the server world in full maturity. Unlike Windows that has grown painfully into a server operating system, causing many a system administrator grief and indigestion, the Mac didn't even have to go through puberty.

What a waste though. Giving this much power, to a group of users whose main purpose is to draw pretty pictures and organise pictures of family vacations or pets is regrettable. It's almost like giving that retired ninety year-old a La
mborghini so that they can drive a block or two to do some grocery shopping. The latest version "Leopard" is a real treat with features that make working with the desktop much easier. I predicted that the ease of use of the desktop would become the primary feature that would make any operating system attractive. Right now, it's difficult to say who's winning between the new Mac and Linux systems with compiz/beryl. More about Linux later, or perhaps in another article.

So, what makes the Mac usable? The reason I predicted that improvements in the desktop would determine usability is because, as prices for disk drives dropped, and portable storage devices like USB keys became in rampant use, then the tendency to save everything followed next. The clear desk policy that some organisations have for their office environment obviously cannot work for the electronic desktop. So, after a few years in an organisation, a lot of stuff get accumulated. All this stuff has interesting sounding names like file01.doc, file03.doc, dog_pictures.jpg, house.txt and so on and so forth. Traditionally, to find anything, you needed to make sure that you used a good naming
convention. If the name you gave your file was not descriptive enough then you'd have to open each and every file to view its contents. In the old DOS world, this was impossible to do and many of us still name our files as though we were limited to an eight character file name.

So now the electronic desktop is cluttered with so many files; documents, pictures, emails, web links and everything we think is precious and don't want to lose. When it comes to finding anything, our best friend nowadays is the search button.

The Mac has made finding files an easy thing to do. Rather than list names for you, the new spotlight application shows you the contents in a
very easy to view format. You can flip through documents in a folder much faster than reading the name and trying to figure out what exactly you were thinking when you made up that name. In addition to this, it has a quick format to organise your desktop so that clutter is reduced. As I write this, I have approximately one hundred icons on my desktop. Some of them are important. Folders with stuff that I'm supposedly working on. Others are documents that I downloaded from the web which I have the intention of reading, but really don't want to keep after I've digested the content. Others are waiting to be classified and moved. While others still are waiting to be backed up and then removed from the system permanently. I'm a busy guy, seemingly.

The new Mac also provides you with multiple desktops.
Like me, once you open applications, you never really close them. You just minimize them for later use. I've found this especially useful with Firefox. This application seems to take a long time to launch and has personality issues. The multiple desktop idea is a good one. Someone once asked me when I'd use multiple desktops. A good question. I actually had to think about it for a while before replying. Well, normally I like to keep my email open all day. I don't want to close it. In addition to that, I normally open more than one web browser window so that I can look things up on the Internet and not have to close the window. So, I keep those regular applications open on one desktop. Then on a different desktop, if I'm working on a document, I'll open it there and work on it there. Since I'm a Linux desktop user, I will have more than one console window open. It's helpful if you are looking up help in one command (man pages) and run the actual script in a second window. So I have a lot of windows open at the same time.

If you use Microsoft Windows, organising open windows can be a nightmare. As soon as the taskbar (along the bottom normally) starts filling up with those little buttons, the names of the open applications become illegible and you have to hover your mouse over each and every one of them in order to see what's open. In Windows, as in Linux, I prefer to use the Alt+Tab key sequence to see what's open and move from application to application. In the Mac, you can now open up a number of desktops and organise your work into more logical areas. You don't have to open everything in one single desktop.

I believe that the Linux solution to the desktop clutt
er and ultimately the search for document problems is also quite elegant. A desktop manager that I use is called compiz. It can be found at http://www.compiz-fusion.org/. It is highly configurable, but the setting that I like the most is the desktop cube. With the desktop cube, you can spin the cube around. Here's a picture with the cube rotating.


What do you think? Pretty cool stuff. You can arrange your applications along any of the four sides, not the top or bottom (which would have been nice). To see your applications, you can spin the cube. Amazingly, if you're playing a video while the cube is spinning, the video continues to play, so if you have a transparent cube, you can watch the video from the back!

In addition to this view, you can also see all your desktops horizontally across the screen as in the following image:

In this image, you can see all the desktops and you can drag applications from one desktop to another. I've configured my computer so that when I move my mouse to the top-left corner of the screen, I switch to this view automatically. In addition to this view, I can see all my windows on a single desktop. On my system, I've configured the F10 key for this functionality. On pressing F10, all the open applications are collected and arranged so that I can pick the one that I want. If I click on an application that's currently on a different desktop, my cube spins around and takes me to the correct desktop.

One of the things that I don't like about the new Macs is that the file system is no longer case sensitive. You have to remember this if you're building web applications for that platform. You have to remember that you can't just move an application to Linux where this case sensitivity is enforced. While being lax about it on a Mac, your application might break in Linux. Windows doesn't care either. I wonder if this was a good decision.

So in conclusion, the Mac has come a long way. It's internals are much more interesting than the desktop. The latest version makes working with many documents easier. The spotlight program makes searching for documents a breeze. You can now search by actually flipping through and viewing contents. It's not the same as an icon view, but a real display of the actual document allowing you to page through it. Linux doesn't have an application like this, and Windows is even further behind. The desktop, though clean, still needs more candy. Running a plain desktop on such a beautiful and powerful machine is really sad. Linux runs on poor hardware, but even with the demands of compiz, the desktop is quite beautiful.

That's all for now. I'll get into some PHP discussions next.