Navigation:

Search



Related Articles

Our Friends

Articles Linux Overview
 

Linux Overview

Not Just a Corporate Buzzword

This was written by Benjamin McMillan and given on Wed Sep 03 2003.

Table of Contents


1. Basics
1.1. What is Linux?

Although most people refer to Linux as an operating system, it really isn't. Specifically, Linux is just the core of the operating system, called the 'kernel', which runs the applications and interacts with the hardware. The Linux kernel was originally written by Linus Torvalds in 1991, but now includes code from thousands of programmers worldwide. This kernel is then combined with many applications and utilities and collectively form the OS commonly known as Linux (or GNU/Linux).

1.2. What are 'distributions'?

There are many applications (aka, packages) out there. Some do the same things as others, and most are available in different versions. Companies such as Red Hat, Mandrake, Gentoo, etc take the kernel and package it with their own choice of applications. The big companies also usually modify the kernel and write custom applications (mostly configuration utilities). These companies also spend a lot of time writing installers, so that installing Linux isn't as hard and scary as it used to be.

These compilations of applications, installers, and kernels are called distributions. There are dozens of distributions available and most are free to download. Some can be purchased, although you usually are paying for the packaging, printed documentation, and tech support.

Different distributions are geared for different kinds of users. Mandrake is great for previous Windows users who are new to Linux. Red Hat is also good for these types of users, although it suits the more advanced users a little bit more than Mandrake. Red Hat has many different versions, just as Microsoft has many different versions of Windows, all to suit different users. The "enterprise" editions are especially designed for businesses installing it on servers and such, whereas the normal "desktop" editions are for normal (web surfing, word processing, etc) users. Some versions are especially designed for international users. Some distributions are meant to fit on (and totally run from) a floppy or a CD.

The most well-known distributions are (in no particular order): Red Hat, Mandrake, SuSE, Gentoo, Slackware, Debian, Knoppix

1.3. GPL

Linux and many of the applications that come with the 'Linux' operating systems are released under the Gnu Public License. This means you can do whatever you want with them - use them, copy them for a friend, change them, etc. However, do not falsely claim that you wrote the entire app or kernel, and any changes that you've made need to be shared with the community. This makes it possible for everyone to contribute.

1.4. Who operates, owns, controls Linux?

Unlike Windows, which is controlled by Microsoft, Linux is not owned or controlled by a large corporation. In fact, there is no single entity in charge of Linux. Instead, Linux is by and for hobbyists, hackers, and professionals worldwide.

However, Linus does own the name, "Linux," and Larry Ewing the official mascot,"Tux."

2. Why Linux?
  • Have you ever used Unix and liked its simplicity and power?
  • Do you enjoy [the idea of] reading source code of programs to see how they function?
  • Do you have a class need for a good C, C++, gcc, make environment?
  • Do you want to run a great website with just a few simple (yet powerful) tools (vi, make, perl, apache, etc)?
  • Do you not want to use monopolistic over-bloated buggy and expensive proprietary OS's?
  • Do you like to have many different ways to do anything?
  • Do you want to be cool?
  • Do you believe you can evolve into a superior technical lifeform?
  • Do you want any kind of technological job 10+ years from now?

If ANY of these applied to you, Linux is for you.

3. Linux Basics
3.1. Kernel

As said before, the kernel is the middle-man between hardware and software. It is the kernel that is responsible for handling memory, processes, hard disk I/O, ethernet activity, etc. If you use a wireless card, your kernel must be able to support the chipset of that card (prism2, orinoco, etc).

When somebody says they are recompiling their kernel, it is usually because they bought a new gadget, patched the kernel to protect themself from an exploit, or just need a new feature (like iptables support). Typical Linux kernels are usually 1-4mb in size. Some people try to enable support for only those things they already have, and nothing else, to try to reduce the filesize(so they can fit it on a floppy). Other people enable support for anything they think they might want in the future to avoid having to recompile their kernel.

However, there is a way to enable support for a new feature or gadget without recompiling your kernel (and thus forcing you to reboot into that new kernel). You can either build support into the kernel, or as a module. Modules are separate from the kernel, and can be loaded and unloaded at will. All you have to do is tell the kernel config utility that you want that driver compiled as a module (outside of the kernel), run "make modules modules_install" and voila. Load that module("modprobe ewmodule") and magically you have support for that new device. No reboot was required. This saves a lot of time and trouble.

3.2. Filesystem

The Linux filesystem is a lot different than that of Windows. Windows uses drive letters for drives (hard drives, CD roms, floppies, etc) and partitions for those drives. C: is the root for the primary (and maybe only) hard drive or partition. D: is the root for the secondary hard drive. So on and so forth. Linux, on the other hand, has only 1 root. The root directory is "/". Everything resides in this root.

                                  / (root)
                                  |
+------+-----+------+-----+-----+-----+-----+-----+-----+------+-----+
/boot  /bin  /home  /mnt  /lib  /var  /usr  /dev  /etc  /proc  /root /tmp

There are more dirs than those listed above, but that's most.

/home is where users' home directories are located. /home/daevux will be where user daevux will put all their files, pictures, etc.

/mnt is where you would "mount" a drive, partition, or any other storage device. For instance, /mnt/cdrom is the most typical place for where you would "mount" your cdrom drive. First, what is "mount" ? When you mount a drive, you are telling Linux to get that drive ready for I/O. Linux then determines what filesystem the drive is formatted with(iso9660 for CDs, vfat for Windows drives, smbfs for samba shares, etc), then figures out how it should interact with it accordingly.

/etc is where most system-wide configuration files are kept. For instance, /etc/apache/conf/apache.conf is the configuration file for Apache.

/boot is where the kernel is kept, as well as any bootloader (grub, lilo).

/lib contains the libraries needed for certain programs to be run. This is also where kernel modules are kept.

/var is usually for log files, sometimes tmp files, email spools, etc.

/usr is where applications and user utilities are located, in addition to A lot more stuff.

/root is the home directory for the root user.

/tmp is for temp files.

/bin (and /sbin) contains basic system utilities (bash, cd, dd, halt, etc)

/dev and /proc are not real directories. /proc includes system information (a lot of statistics, etc). /dev includes "pointers" per se to hardware devices. /dev/mouse is a pointer to your mouse. /dev/hda1 is a pointer to the first partition on your primary hard drive. There's also stuff like /dev/zero, /dev/null, and /dev/random.

3.3. Permissions/Users

Linux (like most modern OSs) is multiuser. This means that many users can use the system, even at once.

First and foremost, there is only 1 root. This is the ultimate superuser of the machine. root can do anything and everything. Keep root's password safe!

Then there are normal users. Users can belong to certain groups, which determine that user's capabilities. For instance, a user in the wheel group is allowed to "su" (switch to root mode) on a Gentoo system (I don't know if this is true for all distros). Most users should be included in the group, "users".

Every file and directory in Linux has attributes that determine who can read, write, and execute it. For instance, file xyz.txt might have have permissions that look like this (using ls -o): -rwxr-xr-x . the first character determines what type of object it is (file, dir, sym link, etc). - means it is a file. d will mean it is a directory. The next 3 characters are for user, the next 3 for group, the next 3 for all users. This particular file can be read and executed by the user who owns it, the users in that user's group, and everyone. However, only the user who owns it can write/modify it. The "chmod" command changes those permissions (but must be run by either the user who owns it, or root). The "chown" command changes the ownership of the file.

3.4. CLI/Shells

What good is the operating system if you can't interact with it? This is where the command line interface (CLI) comes in. This is a generic term used to describe a text-based way of interacting with programs, as opposed to using GUIs. It is the simplest way to interact with Linux.

Shells are various programs that provide this functionality. The most popular shell is bash, but some others are csh, ksh, tcsh, and zsh. They basically take your commands, process them, execute the program you called, and display that program's output. They do much more than this, but you get the gist of it.

For instance, you might see something like this:

daevux@feynman daevux $

This is a bash prompt. The first word before @ is the username, the word after the @ is the computer's [host]name, and the 3rd word is the current directory. Bash is popular partly because it does (by default) tab completion and keeps a command history.

{acmey:gtg051h:!}

This is another shell (ksh). Slightly different than bash. Of course, there is much more difference between the shells than just how the prompt is formatted.

3.5. X-Windows

X-Windows is for wussiess. Just kidding. X basically allows you to use Linux in a much more friendly, graphical environment. XFree86 is what most Linux users use; it is the free implementation of X. There are other implementations, but XFree86 is the most mature and popular. X is also a server/client app, meaning you can run X programs remotely.

4. Applications
4.1. Window Managers

X is no good without a window manager running on top of it. Window managers operate between X and the graphical programs you want to run. They do stuff like draw the borders around your programs, manage their placement, draw titlebars, etc. Some WMs are very simple, some are very complex.

4.1.1. KDE

More than just a WM, KDE is a desktop environment. It resembles Windows a lot. There is a panel at the bottom, with buttons that execute programs and expand menus. Also in this panel is a task area, which keeps track of which programs are open/minimized. Sound familiar? This is the best WM to use for those new to Linux. Many distros come with this by default.

KDE uses the Qt engine.

4.1.2. Gnome

Gnome is another WM/DE (desktop env). The same comments for KDE also apply here. Refer to the screenshots to see the differences.

Gnome uses the GTK[2]+ engine.

Note: Gnome (GTK) and KDE (Qt) applications can be run in any WM, not just the ones they were written for.

4.1.3. Fluxbox/Blackbox

This WM is for more experienced users - those that are annoyed by DEs. Fluxbox and the WM it was based off of, Blackbox, are minimalistic to some degree. This means that it only does what is needed. Nothing more. There is the toolbar, which only includes iconified (minimized) programs, the time, and the workspace name. There is also the slit, where you can put dockapps - small graphical programs that monitor time, CPU, Memory, I/O, Network, etc. Most people that use these WMs rely on keybindings to open programs - in addition to a small menu. A major selling point to these window managers is that they're very fast and very stable. Fluxbox, unlike Blackbox, also heavily uses tabs - so that you can group windows together.

4.1.4. Enlightenment

Enlightenment is a popular window manager, with an almost cult-like following. It is the inspiration for many current window managers. The window manager however hasn't seen a new release in nearly two years, and is dying out. It is kind of like Blackbox, but more graphics heavy (prettier) with cool effects.

4.1.5. Window Maker

Window Maker offers a lightweight alternative to GNOME and KDE. It provides a look-and-feel that mimics the NEXTSTEP user interface, but can be themed any way you like. Features such as the Dock and Clip make Window Maker a popular choice among system administrators.

4.2. Office/Productivity
  • OpenOffice
  • KOffice
  • Abiword
  • GnuCash
  • Siag
4.3. Editors
  • Vi/ViM
  • Emacs
  • Pico/Nano
  • SciTE
4.4. Web Browsing
  • Mozilla
  • Konqueror
  • Lynx
4.5. Email/News
  • Evolution
  • Sylpheed
  • KMail
  • Pine
  • Mutt
  • Tin/SLRN/Pan
  • KNews
4.6. Other Internet Stuff
  • Gaim
  • Everybuddy
  • XChat
  • BitchX
  • Kismet
  • P2P stuff
  • gFTP
4.7. Multimedia
  • GQView
  • xv
  • gPhoto2
  • XMMS
  • Timidity++
  • XawTV
  • TVTime
  • MPlayer
  • Xine
  • VLC
  • gCombust
  • gRip
4.8. Games

Sorry, no games for Linux. Just kidding :)

  • GnuChess
  • Quake1-3
  • Halflife
  • TuxRacer
  • BZFlag
  • Dopewars
  • Foobillard
  • Unreal
  • UT2003
  • RTCW
  • Freecraft
  • Freeciv
  • Penguin-command
  • GLTron
4.9. Servers/Databases
  • MySQL
  • PostgreSQL
  • Apache
  • Postfix
  • Sendmail
  • Qmail
  • Samba
  • Cups
  • ProFTPd
  • BIND
6. Screenshots

Screenshots can be seen at http://benmcmillan.com/lugpres .