1.2 Getting Linux

Getting Linux

For the beginning of the course, the student will be using a Knoppix live CD.  This will let you work in a Linux environment without having to install anything.  Later, there will be instructions on how to install Linux.

There are several methods to obtaining a Linux distro to work through the course with, each with their own advantages and disadvantages. The simplest is to obtain a live CD, which will run Linux using only the CD and a computer's RAM. The disadvantages are that the CD drive must be bootable and one can still mount and alter (erase, corrupt, etc.) hard drives.

Another method is to run a virtual machine from an already installed operating system. This will allow for a quarantined Linux without altering an already present operating system. However, It does require enough resources to run both operating systems. VirtualBox and images for various Linux distros are freely available.

Doing a full install of a Linux distro is also an option. There are many distros that have very user friendly graphical installers along with thorough installation guides. This method is more permanent and less flexible. To keep an old operating system from being overwritten it will require more skill. .Due to the more technical and permanent nature of this method, it will not be covered until later in the course.

Recommended: Virtual Machine

Virtual machines will allow for a quick and simple setup. Virtualbox is freely available at virtualbox.org for Windows, OSX, and Linux. Download, install, and open it.

Minimally, you'll need 512M of RAM, but in reality, you should have enough RAM to comfortably run the host operating system as well as the guest operating system, which will differ depending on which operating systems are being used. Processors follow the same rule: enough speed for both operating systems. Multicore processors will be a blessing here. There should also be enough disk space for both operating systems to use. Plan for several gigabytes to be used by each operating system.

One can find many premade images to load at virtualboxes.org/images/. Be sure to note the usernames and passwords that go along with the images. Once you've downloaded an image, unzip it and add it as a virtual machine by selecting the .vdi file when creating a new virtual machine.

Because premade machines are sometimes set up in ways that won't work for a specific system (due to incompatable boot options, etc.), an alternative is to place a Live CD .iso into the virtual machine's fake CD rom drive. This will automatically configure the system at boot and is a bit more reliable than a premade virtual machine. The downside is that the OS starts fresh every time it's booted, so no changes are saved.

Open VirtualBox and follow along with this video.

As seen in the video, VirtualBox can have several virtual machines installed, allowing you to have multiple Linux distros. Repeat the steps in the video to add additional virtual machines.

Live CD

There are many Live CDs available. One prominent example is Knoppix. This section will go over how to obtain and boot into Knoppix.

One detail to note when downloading a live CD or an installation CD is the architecture.  Programs that are compiled for one architecture will not work on another.  Most desktop computers run on the x86 or x86_64 architecture.  Look up what architecture your processor uses to be sure. Pre-Intel Macs use the PPC architecture.  Other architectures are mostly for servers or embedded devices.  If you need one of those, you'll know it.  Knoppix will run on any x86 architecture.  For the duration of the course, it is assumed the student is on an x86 computer. Other Live CDs are available for other architectures. Aside from an x86 processor, you'll need 120 MB RAM (500MB is recommended) and a CD rom. No disk space is required as all files are read from the CD.

To obtain a Knoppix CD:

Alternatively, Live CD isos may also be placed in a virtual CD rom drive in a virtual machine for the ease of a Live CD combined with the compartmentalization of virtual machines until you're ready to perform a virtual or actual install. This is also a viable alternative to premade virtual machines which may not work out of the box.

Getting used to Linux

Now that you're in Linux, there are a few things you'll have to get used to.

 

Course Conventions

This course will use several conventions:

Though GNU/Linux is the de jure proper naming convention for the operating system to be discussed, this is shortened to Linux for both ease and because it has become the de facto name for GNU/Linux.  For more background information about this, see the GNU Operating System website.

Text that is to be entered on the command line will appear as follows:

$ ls -a

# vi fstab

Text that the user will fill in appropriately will be in italics and optional text to be entered will be in [square brackets].  This mirrors conventions used in the man page synopsis section.

Examples will usually use the traditional placeholders of foo, bar, baz, and qux. These are not actual files and should always be taken as examples.

Because Linux is case sensitive, some sentences will begin with a lower case letter to preserve correct capitalization of commands and so forth.

Many Linux commands have options that are not covered in this course because they are useful in only certain cases.  If the text says to read the man page, follow instructions.  Man pages need not be memorized, but they will prove extremely useful while learning about commands. Man pages serve as an excellent reference for those well on their way toward mastery.