Saturday, May 27, 2006

Distribution Confusion

One of the most overwhelming aspects of Linux for a former Windows user is the "distribution" phenomenon. You can't just walk into a store and buy--or go online and download--Linux. Instead, you have to choose a "distribution", which is conceptually nothing more complicated than a brand or "flavor".

Windows, of course, comes in a few different "flavors" -- Windows 2000, Windows NT, Windows XP Professional and Home, for example. Initially these different "editions" were nothing more than new versions and updates. These days, however, Windows comes in some more complicated flavors, such as Windows XP Tablet PC edition, Windows XP Media Center edition, and so on. Each edition comes with its own set of capabilities and its own limitations.

Linux, on the other hand, comes in a bewildering array of flavors, called distributions. If you find the link to DistroWatch in the right sidebar, you can see over 100 different distributions tracked (although some of these are for a related operating system, BSD). Each distribution builds on the same architecture (the same, or similar, kernel and shell), but there are significant differences among them. The chief differences include
  • Platform: Some distributions are designed to run on non-Windows computers, such as Macintosh. There are distributions that run on legacy computers like the Commodore Amiga. Other distributions are tailored to notebook and tablet computers. There are even distributions that run on handhelds (although they are more properly viewed as emulators since they sit on top of the native handheld operating system). Some distributions simply won't run properly on certain computers, for reasons that are not always clear. This is why starting with a live CD version may be best.
  • Size: One of the advantages of Linux is its scalability. There are Linux distributions that can run on the oldest, smallest, and slowest computers available. Other distributions are monster systems that run best on powerful computers with large amounts of storage. If your older computer is running too slowly or running out of memory, you might find a smaller Linux distribution to be just the trick to bring it back to life.
  • Features: The primary difference among distributions is the "packages", or software programs, that come along with them. Some distributions include only the operating system and a bare minimum of programs; others have a full panel of both open-source and proprietary software included. Some distributions even include commercial software, although these distributions generally must be purchased, rather than downloaded for free. If you're looking to get up and running with a full set of software right away, one of the more full-featured distributions may be right for you.
  • Software installation: Because of the open-source nature of Linux, there are a number of ways to find and install software once you've installed the operating system. Some of these are a bit cumbersome (compiling and installing the source, for example), while others are simpler (installing binaries directly). Each distribution has its own particular way of installing software, and some ways are more user-friendly than others. Many programs have to be specially-built for a particular distribution; you will find that the more popular distributions have more software pre-built (as "binaries") than the less-popular distributions.
Choosing a Distribution
The debate about which distribution is "best" is lively, and, as yet, unanswered. I will not even attempt to take a position on the issue. The best recommendation I can give is that the less familiar you are with computers, the more you should stick with the "larger" distributions. The DistroWatch website includes a "Page Hit Ranking" sidebar that lists how frequently each particular distribution's page is accessed on the website, which serves as something of a surrogate for how popular the distribution is.

Each distribution's website gives information about the philosophy behind the distribution, the packages that are included, and some of the hardware limitations and bugs they've found. If there is a known issue regarding a component on your own computer, you would be advised to stay away from the distribution until it's addressed.

Once you find a distribution that seems to be a good fit, try downloading the "Live CD". This is a version of the distribution that runs completely on one bootable CD (or, more often, DVD). You will find links to an "iso" file, which you can download and burn directly onto a disc. Boot with the disc in the drive, and you will load the new operating system instead of Windows. You can then try it out to make sure your hardware is compatible. You might need to do some configuration from within the OS to make sure all of your hardware is recognized.

You can even try downloading several live discs to see the differences between different distributions. The only costs will be the time spent downloading and the cost of the blank disc. Many power Linux users actually have multiple distributions installed on the same computer, to take advantage of the strengths and weaknesses of each. You'll probably want to stick to one at first.

Taking the Plunge
Once you've found the distribution you like, it's simply a matter of downloading it from the website. Many websites also have mirrors, which are exact copies of the website in other locations. Instead of going to the main website, you can go to a mirror site closer to you--this will unload the main website and probably give you a faster download time.

Distributions generally come in CD or DVD form. If you have a DVD burner, the DVD iso is usually a better bet, since most distributions will fit on one DVD. If you opt for CD's, you may need to burn and install several CD's worth of data. If you choose, you can also purchase a pre-burned CD or DVD -- follow the links from the DistroWatch website, or find a software retailer for the full retail package.

One caution: when you're looking to download the distribution, beware of "alpha" or "beta" releases, "release candidates", or "unstable releases". These are all code-words for test versions. You will want to find the "stable release".

Installing Linux is a whole separate process, and we'll discuss that in upcoming days.

Regards.

Friday, May 26, 2006

What is an OS, anyway?

Most average Windows users probably have very little idea what an operating system is, let alone how much the operating system influences what they can and can't do with their computers. An (admittedly oversimplified) introduction, then, might be helpful.

Imagine, for the moment, that you're in a restaurant. Your server arrives and presents you with a menu of all of the restaurant's offerings. You look through the menu, decide what you would like to have, and inform the server -- who scurries off to the kitchen to place your order. After a short delay, your food arrives -- hopefully what you ordered, but not necessarily.

Without knowing it, you have used a form of operating system, although it had little to do with computers. Let's look at the steps involved:
  1. You, the user, chose what you wanted from a menu of options.
  2. The server ensured that your selections were legitimate and complete, and corrected you when necessary.
  3. The server communicated your selections to the kitchen.
  4. In the kitchen, the chef matched your selections with pre-built recipes.
  5. After selecting the recipes, the chef carried out the instructions in the recipes -- finding ingredients, mixing them in proper ratios, cooking or chilling them, etc.
  6. Once the instructions were complete, the chef gave the results to the server.
  7. The server brought the results to you, the user.
The operating system (OS) of your computer performs the same functions. When you sit down at the computer, the operating system presents you with a series of options -- you can run programs, copy or delete files, etc. Whether the operating system uses icons that you can drag back and forth or commands that you type in, the OS still translates your requests into a series of instructions that can be carried out by the computer.

Most operating systems (including Windows and Linux) consist of several "layers", or components. In Linux, these components consist of:
  • The "kernel" -- the basic rules the computer follows to interact with all of the hardware on your computer. In our restaurant example, the recipe book is the restaurant's "kernel".
  • The "shell" -- the fundamental means of interacting with the kernel and the computer's components. In our restaurant, the menu is the restaurant's "shell"
  • The "desktop" -- the interface that allows the user to interact with the operating system's shell. The restaurant's server performs the function of the OS desktop, helping you to navigate the options presented in the menu. Of course, you don't need a desktop on a computer any more than you need a server in a restaurant -- if you're willing to read your menu items directly to the kitchen, you might also be willing to use the shell to enter commands directly.
Windows has a similar architecture, although the components are integrated far more than in Linux, so you may not recognize them individually.

Replacing the operating system on your computer is like a restaurant changing its offerings. It will need a whole new set of recipes (kernel) and a new menu (shell). Once you've changed all of this, you will probably need all new waitstaff (desktop). You can, of course, make the new waitstaff look and operate very much the same way the former staff worked.

When you change from Windows to Linux, you will need to install a new kernel, a new shell, and a new desktop. Most of the time, these all come together in one package. Once you're done, you'll still be able to perform the same general functions you did before, but things will look and work a little differently. And, just as your favorite meal might disappear from a restaurant that changes its menu, you probably won't be able to run your favorite Windows applications once you switch to Linux (there are, however, some nice conversion utilities that we'll discuss in the coming days to help with this).

So why do we have operating systems at all? Unless you want to go into the kitchen and cook the food yourself, the operating system is going to save you a lot of time and effort. The OS confers two principal benefits:
  1. It makes your job easier as a user. You can configure your operating system once, and then every program you run within the operating system will (probably) conform to your configuration. Otherwise, you'd have to configure every program you run to know what kind of printer you have, what time zone you live in, and what colors you like to use on the screen.
  2. It makes the programmer's job easier. The programmer doesn't have to know what kind of monitor or printer or disk drive you have to write your word processor. All the programmer has to know is that you have these things. The job of the operating system is to find out what kind of components you have, and then provide a link from the software to those components. Otherwise, the programmer would have to write software for every possible component into every program. With an operating system, this software is written once, and every program "borrows" it.
The next time you order food online, consider that you've just used two operating systems. And bon appetit.

Regards.

Tuesday, May 16, 2006

Why switch to Linux?

The first question any home user contemplating switching to Linux should ask is, "Why bother"?

Most people are intrigued by the fact that it's "free", but if you already have a working OS on your computer, then you don't particularly need another free operating system.

Why I switched
I initially wanted to see what all the fuss was about. I read up on Linux on the internet, and found the concept of an open-source operating system fascinating. The main reason I switched, though, is that my Windows OS has become so corrupted by installing and uninstalling software, crashing software, and occasional power outages that there are certain software packages it won't even let me install anymore, let alone run. So it was a matter of either reinstalling Windows to clean things up, or try something different. I chose the latter.

First I downloaded a "Live" CD, just to see what things looked like. The concept here was interesting, too -- the idea of running an operating system completely from a disc, without changing anything on the hard disk or having to repartition or reinstall anything. The Live CD ran well, although without any significant write access anywhere, there wasn't much one could do with it. It was more of a proof of concept -- the OS would, indeed, work on my system.

Then I read about an "OS anywhere" system. This centered around a self-booting USB hard drive with a Linux OS that you could carry with you anywhere, and that would run on practically any computer. I thought this sounded great. I tried to build my own with the live CD and a USB HD I put together from a blown-out laptop, and discovered that I had a lot to learn about Linux before I could pull off a stunt like that (I have since successfully done so, although you can buy one much easier).

Finally, I took the plunge. I figured I had enough unused hard drive space around that I could afford to repartition the hard drive. I figured I would try it out from time to time, just for fun.

The first distribution I chose was Mandriva. Unfortunately, after several attempts at installing it, I simply couldn't get it to boot reliably on my system. I then tried OpenSuSE, and it installed without a hitch. I have been using OpenSuSE ever since (about two months as of this writing).

Repartitioning the hard drive was simple, and I haven't missed the space Linux took up. In fact, I had to repartition again to make even more room for Linux -- which is something of a challenge when you have NTFS and ReiserFS sharing the same hard drive (Norton Partition Magic did the best job of anything I tried, although it's very skittish around ReiserFS).

Why should you switch?
If you're even wondering about Linux, and have read this far, you probably have enough interest in switching. Although there are many lively online debates about why Linux is better than Windows, my experience as a home user leads me to the following conclusions:

1) Linux has been much more stable for me than Windows. This is not to say that I haven't crashed Linux -- in fact, as of this writing, I'll probably have to reinstall KDE because of some kind of corruption I've managed to cause. The stability of Linux comes mostly from the lack of the infernal "registry" that causes so much trouble within Windows. You can install and uninstall software much more cleanly on Linux, which means that programs don't interfere with eachother as much. Just beware of "dependencies". If you don't know what these are, you'll soon come to find out.

2) Linux is, apparently, more secure than Windows. I'm a little concerned about this argument, because it seems fallible to me. Linux is affected by far fewer viruses, but it also has somewhat more rudimentary security. In fact, since it's open source, you would think Linux would be very easy to break into if someone really wanted to. I conceive of the difference this way: suppose you live next door to an art museum. You have a rudimentary home security system, and the museum has a state-of-the-art system. Which one is more secure? More people want to break into the museum, but it's easier to break into your house. In the end, it's hard to tell.

3) Linux is infinitely more configurable than Windows. You can choose from several desktops, you can configure those desktops exactly as you like, and you can even "create" your own OS by building your own kernel and packages. Most entry-level home users won't necessarily go this far, but you can if you like.

4) There are a lot of little things you can do with Linux much more easily than in Windows -- particularly file operations (like backing up your system, creating .iso files, archiving, etc.).

5) Most Linux distributions come with an incredible amount of software already included -- and "free". With Windows, all you really get is Windows.

Why *not* to switch
There are some things you should know about Linux before you decide to take the plunge -- some of which I learned the hard way:

1) Linux is not for people who are uncomfortable searching for, downloading and installing software. If you are not proficient in these three steps, or are unwilling to learn, stick with Windows. And good luck.

2) As far as I'm concerned, it is not practical to install and maintain Linux unless you have broadband internet access. Practically speaking, all of your updates and support are going to be on-line, and if you try dialing up, it's going to take forever to get anything done.

3) Linux is an alternative to Windows. It is not a replacement for Windows. Most of your cherished Windows software will not run properly on Linux, even with many of the ever-improving Windows emulators available. There are myriad alternative applications that run in Linux and perform many of the same functions, but, by and large, they do not have as many features as their Windows counterparts. In most cases, this is a good thing. But if you have a mission-critical application that will not run with Linux, don't switch.

4) Installing Linux is easy, but you will be surprised how much time it can take to get the system up and running -- and keep it that way. There's a steep learning curve for Linux, and you should be prepared for it. Do not attempt to repartition your hard drive and install Linux if you only have an hour to devote to the process.

5) If you're one of those "I know I should back up this system, but I probably won't bother", you'll probably not want to try dual-booting Linux. You never know what could happen.

We'll look in future columns at some more basic issues of switching, as well as some things I've found along the way to make it easier.

Regards.

Welcome

Two months ago, I installed Linux on my home PC and booted Windows XP for the last time*. This weblog will document my journey as a relative computer novice into the often bewildering world of open-source OS.

There are some compelling reasons why home users will prefer Linux to Windows, and some real headaches that this leap will create. I hope to document both here from my perspective, and to help others who are making the transition.

Linux is, by its very nature, a collaborative process -- as I hope this weblog will be. You may see things that are controversial, oversimplified, or just plain wrong. I hope you will take the time to respond, correct, and assist as you are able.

Overall, I have enjoyed Linux, although installing and maintaining it has taken significantly more time than I ever anticipated. It may be free (as in beer), but free beer takes far less time to drink (and to recover from the effects).

Thank you for joining me.

*Technically, I have booted Windows twice since installing Linux -- once to convert Email and some other files over, and once to clean up and defragment the hard disk before (unsuccessfully) attempting to read/write NTFS.