Remove the Confusion - What Is Linux?

Posted by JD 08/26/2010 at 10:00

I’m guilty of oversimplification. We all are. I say that I run Linux. That isn’t really accurate, but it is short and only people in the know really understand what that means. Below I’ll attempt to compare a few well known operating systems to an automobile and the parts inside it.

OS to Vehicle Comparison

I’ve picked 1 specific version of a vehicle, Linux OS and Windows OS to use for comparison.

Part              Vehicle                  Linux                         Windows

Total Name        Ford F-150 Truck         Ubuntu 10.04 x32 Desktop      Microsoft Windows7
                                                                         x32 Home Premium

Engine            Ford V8 4.4L Diesel      Linux Kernel 2.6.24-28        Kernel.xyz build 
                                            No direct access to the      number xxxx. No 
                                            kernel without helper        direct access to  
                                            programs.                    the kernel without 
                                                                         helper programs. 
                                                                         The kernel 
                                                                         provides services
                                                                         to other programs.

Outside Bling     Paint, chrome, flashers  Gnome 3.x, customized GUI     Windows Desktop 
                                           running on top of X/Windows   Program / Explorer 
                                           and a _Window Manager_ like   (1st instance only)  
                                           xfce, fvwm, Icewm ... *wm     This is the GUI - 
                                           Other examples of _Desktop    Start Menu, etc.
                                           Environments_: Gnome, KDE, 
                                           LXDE, XFCE. DEs are a 
                                           convenience and not 
                                           necessary.

Raw Controls      N/A, but directly        GNU CLI programs - ls, df     CMD.EXE and a 
                  controlling the throttle  du, and thousands of         limited set of 
                  with a pair of pliers is  others. Example UNIX         programs - dir, 
                  an example.               "Shells" are bash, sh, csh,  scandisk, chkdsk, 
                                            tcsh, ash, zsh, etc...       nslookup, net use, 
                                                                         route. Any program 
                                                                         that doesn't have 
                                                                         a GUI.

User Control Sytm Steering wheel,          CLI interface                 CLI interface 
                  instruments, peddles,    OR                            (mostly unused) - 
                  gear shifter, radio, etc GUI xfaces                    the old DOS-style 
                                                                         interface
                                                                         OR
                                                                         GUI controls like 
                                                                         Control Panel

So, when someone says they use “Linux”, they could mean the entire OS or they could mean just the kernel. To type this article, I’m currently using
Engine: Linux 2.6.32-22-server #36-Ubuntu SMP x86_64
Outside Bling: LXDE running on Lubuntu 10.04 x64, running openbox WM
User Controls: CLI – 95% of the time.

Obviously, I’m running a web browser, Firefox, to enter this article into the blog system. I edit these directly inside the blog software, not in another system. Firefox is just a program.

I realize that most people use MS-Windows and confuse the GUI with the operating system. The GUI is just a facade used to control the operating system, nothing more. GUIs included with Linux work that way too, but normally, the core operating system controls are fully accessible without a GUI at all. Often, for Linux, the GUI displayed is just to provide a pretty front end to the same, exact, backend CLI program. This means that exactly the same result will happen regardless of whether you use the GUI or the CLI to change OS settings. In the Linux world, the CLI versions of programs tend to have many more options than the GUI does. In my experience, Windows is the opposite. The great thing about CLI programs is that doing the same thing on 1 or 2,000 systems can be automated, since the administrator doesn’t need to point and click to make changes on each system. Windows addresses this with 3rd party tools like SMS for Windows – this is a paid program and very complex. In the Linux world, every system comes with everything needed to remotely control and manage it OR you can have addon programs, also free, that help manage the systems. Obviously, there are paid programs for Linux management too. Usually, those are for mixed environment management and aren’t used in pure Linux companies.

File Systems – Huh?

I didn’t try to explain file systems, but if I did, it would be like the tuner in the radio. Different file systems exist for every operating system. MS-Windows has just a few options, but Linux has 20+ file system options and the person installing Linux can chose which file system(s) she wants to use. Most file systems provide basically the same features, but more and more are coming out with exciting, new features AND better performance characteristics. I’m very excited about ZFS and BTRFS. Most of my systems use EXT3 still, but most of my storage is on JFS which has a 20 year history and reasonable performance. My data is important enough to not risk just for 3% more performance that XFS or EXT4 could provide. Don’t misunderstand, XFS has a long track record too and I wouldn’t worry about data loss with it, but EXT4 has been out for users only about a year. In 4 more years, I may consider changing. There is no substitute for shelf life and millions of users.

What About Distributions?

A Linux Distribution, or Distro, is just a way to package a bunch of different parts and programs together into a more friendly, usable set of computer code. The Linux kernel is the base of any distribution. It is the foundation for a distro, just like the engine is the foundation to the truck example above. The truck doesn’t work without the engine.

The CLI programs, which are usually from GNU.org are critical to a working Linux Distro.

Package Manager is a wonderful thing. Different distros use different package managers. For me, the package manager used is the most important decision when I pick a distro. Prior to package managers, everything installed on a Linux system was manually installed and maintained. During installation of the OS, a huge list of packages to be installed was presented to the installer and I’d spend 30 minutes checking / unchecking the pre-built packages to be installed. It was very common to download a .tar.gz, .tgz file and compile the code yourself, then copy the resulting program into /usr/local/bin as the installation. RPM changed that-thanks to Red Hat for that. Then other package managers came along and copied what RPM did and improved it, incrementally. RPM was improved over the years too. Debian has APT, SuSE used to have something different, but seems to have converted to RPM. Package Managers added dependency resolution which pulls any dependent packages down and installs them automatically. I’ve used RPM and APT and TGZ packages. I’ve had issues with all of them over the years. Sometimes the issues were self-inflicted and other times they were caused by the package manager – that’s my story and I’m sticking to it. Anyway, I prefer APT-based distributions. Those include Debian, Ubuntu, Mint, PCLinuxOS, etc…. Around 2000, I was using an RPM-based distro and got into RPM hell where I couldn’t install any more packages or remove any packages. Back then, I was manually installing extremely new, development versions of video and audio editing tools that were not part of the RedHat distro repositories. Back then, the repos were 2 years behind what was currently being released.

After RedHat, I switched to SuSE for a few years and used YAST. I got really busy at work and SuSE worked well enough for my needs. I didn’t touch it much and it just worked, but they were also slow to provide the newest code from developers. Finally, I switched to Ubuntu to have access the newest packages. Sometimes this is bad, but almost 99% of the time, it works well enough. I’ve been running Ubuntu-based installs for about 3 years on my main machines, including servers.

If you learn nothing else, learn that you should limit the repositories used by your installed OS to those provided by the package maintainer group or company. If you go outside those repositories, you risk the stability and even the booting of your system. Installing a few programs directly with .deb or .rpm files that you manually download probably won’t crash your system, but if you do it too much, those risks increase significantly. On servers that run production systems, don’t do it except for the primary purpose of the server. For example, I run an Alfresco installation that is available from alfresco.com as a .deb file. That is the only thing installed on the server that is not from Ubuntu’s repos.

What is the best thing about a package manager? That’s easy. Completely centralized software installation, update and removal control. The package manager centralizes distro updates just like Microsoft Update does for Windows, but it also handles 3rd party software updates from Adobe, Mozilla, Sun, Oracle, anyone with a repository. The repository doesn’t need to be run by the distro team either. You can run your own repository, if you like. This means all your company systems can access LAN-based repositories and you can reduce the WAN bandwidth needed. Once a week, I run these commands on all my Linux/APT-based systems to keep them current with software versions and security patches.

sudo apt-get update && sudo apt-get upgrade

Simply beautiful. That’s it. Everything is handled.

X/Windows is the kernel for graphics and mouse control. Without X/Windows, the interface for all versions of Linux are just 80×25 of text. I don’t know of any exceptions where X/Windows is not critical to a GUI. Without X/Windows, there is no GUI in 99.9999% of UNIX systems.

Window Manager sits on top of X/Windows and controls where and how a program window is placed. It controls the borders around every window displayed and when you click in the boarder areas, it gets those mouse events and raises, lowers, hides, resizes, closes, maximizes, minimizes, …. the windows. If you run Ubuntu, there is a Window Manager, WM. For my LXDE GUI, the WM is named openbox.

Desktop Environments provide a GUI above the Window Manager and usually make it a little more user friendly. The menus at the top and bottom of the screen are the most visible part of these DEs, but app-to-app communication is really where a DE becomes important. Do you drag and drop files between programs? You need a DE for that to work. DEs also bring things that end users expect to simply work like network controls, and sound controls. Each DE brings a group of GUI and backend service libraries that the distro managers try to use. For example, KDE and GNOME are the main libraries used by competing DEs. Just like choosing a package manager, the DE choice is the first thing I look for in a distro. The DE libraries – or lack of any libraries – is the next thing that I choose in a distro based on the number of programs that I run for each DE. Ubuntu is "gnome-based. Kubuntu is “kde-based.” With modern hardware, picking a DE is really a comfort thing. This is not an all or nothing decision, since both libraries can be loaded AND used at the same time. All that having both running does is use more disk storage, uses more RAM, and uses more CPU with you have both running at the same time. Simple. If you really care about this or are running a very low RAM/CPU/Disk system, then you need to be very careful about which DE and which programs you load and use. For most of us, is doesn’t matter that much. Don’t worry, be happy.

Programs are the reason you have a computer. Nobody cares that you have Linux – they care which programs can be run and how well they can get the game, word processor, web site, or some other program to work to create the desired result.

Linux is made up of many parts. There’s the engine, the wheels, the paint, the tailpipe, the fuel, the cockpit controls, the trunk, and the seats. These days, an end user doesn’t really need to know much about the parts. Installing Linux (DE and everything) is easier than installing MS-Windows. It is fewer steps and there aren’t any licensing issues or concerns or cost.

Anyway, I hope this clears up what Linux is and provides a little deeper understanding. Did I get anything wrong? Let me know.

Trackbacks

Use the following link to trackback from your own site:
https://blog.jdpfu.com/trackbacks?article_id=776