LINUX: Easy Linux For Beginners, Your Step-By-Step Guide to Learning The Linux Operating System and Command Line (2015)
Chapter Three: Linux Installation
In this chapter, we will discuss about finally installing Linux in your computer. Depending on how you want your setup to be, you can either wipe your hard drive clean and replace your existing OS with Linux or keep your existing OS and share the disk with Linux. The latter will take a few more steps to do the hard disk partitioning.
Linux on Your PC
For beginners, there are two ways on how you can test the waters with Linux.
First, you can get a Linux Live CD. If you want to leave your current OS untouched but you want to try out Linux first, then this is the best option. Using a Live CD will allow you to boot from a CD/DVD or USB drive and use Linux. Once you’re done, remove the CD/USB and reboot the computer to use your current OS. When you’re running the Live CD, you might notice it to be a little slow since the OS is loading from the drive. You can get Live CDs from Knoppix http://knoppix.net/get.php or from Ubuntu http://www.ubuntu.com/download/desktop/try-ubuntu-before-you-install.
Second, you can directly proceed to installing Linux on your computer, either on its own or shared with your existing OS.
The steps discussed in the succeeding sections apply to both using Live CD and those installing Linux.
Before proceeding with the installation, it will be a good idea to check your PC’s hardware first. You may check the hardware vendor’s site to check the compatibility list.
- DVD Drive: To install Linux, you must have a DVD drive and your computer must be able to boot from the drive. If your hard drive controller is IDE/ATA or USB DVD, this will work in Linux.
- Hard Drives: This is not necessary if you will be using the Live CD. If you will be installing Linux, it is ideal to have at least 4GB of disk space. Linux supports IDE and SCSI hard drive controllers.
- Keyboard: All keyboards work with Linux.
- Monitor: Most distribution installers can detect modern monitors. If you find that it does not display well, choose a monitor type and a specific resolution (1024x768).
- Mouse: PS/2 or USB mouse works with Linux.
- Network Card: Installers can detect most network cards. If you find that you are having problems with one, find additional information online.
- Processor: Minimum processor speed required is 700 MHz. New processor speeds nowadays are way more than this value. In terms of speed, the higher the number, the better.
- RAM: The bigger RAM, the better. Minimum required is 512MB. Check the corresponding RAM for your specific distro – others might require a bigger RAM allocation.
- Sound Card, Video Card, Printer: Make sure that these are compatible with Linux. Refer to the hardware vendor’s site for more information.
Next, make space for Linux.
If you opt to install Linux without removing your current OS, note that your existing operating system uses the whole hard drive. This means that Linux and your current OS needs to share the hard drive so that the two operating systems can co-exist. You will need to partition and divide the hard drive. If you choose to take this route, make sure to take a backup of your system because there is the risk of wiping out the data on the drive.
To facilitate partitioning, you can get hard drive partitioning products that runs on Windows or you can use a GUI called QTParted that comes with most Linux distributions. Some distributions (like openSUSE or Xandros Desktop) can reduce Windows partition and automatically create partitions for Linux. In case your distribution of choice offers this feature, you will no longer need a partitioning tool.
Here are the partitioning steps for Ubuntu:
Once Ubuntu boots up and the GUI desktop appears, follow the following steps to reduce the size of the Windows partition:
1. Click on System➪Administration➪GParted from the Ubuntu desktop. The GParted window will appear, and will show the drives it finds on your PC. The first hard drive that you will see will have a device name /dev/sda, the next one will be named as as /dev/sdb, and so on.
2. On the right side of the GParted window, choose the hard drive from the list of devices.
3. Choose the partition you want to resize. You need to look for the largest partition.
4. Select Resize/Move from the GParted menu.
5. Indicate the new size for the partition and then click Resize/Move. Indicate a size such that will give you 4GB or more of free disk space after the partition.
6. Click Apply to begin the applying the changes that you made.
After you get the free space required on your hard drive for Linux, you may now start installing your choice of Linux distribution.
Go to the Linux distribution site and download the distro file. The file that you downloaded will come with the installation steps. In this section, let’s talk about the general installation steps for any Linux distribution.
Step 1: Prepare your CD/DVD installer or Live CD. Download a copy of the distribution you plan to install and burn it into a CD/DVD.
Step 2: Ensure that your PC can boot from CD/DVD drive. If in case your PC still boots from the hard drive when you have a CD/DVD in the drive, change your Boot Devices first. Go into BIOS and change the order of boot devices – choose CD/DVD drive as the first boot option.
You can do this by rebooting your PC and pressing a key (F2 or Del on most computers) to go into the Setup menu. Verify the key for your computer brand and model. Once you’re done assigning CD/DVD drive as the first boot option, put the disk in the drive and reboot your computer.
Step 3: If you are using a Live CD, reboot your computer. The computer will then boot up and load the OS from your Live CD.
If you are installing Linux, step 3 is to partition your drive. One of the options for partitioning was described in the previous section.
Once you already have the partitions in place, boot your computer from the CD/DVD drive and proceed with the installation. While installation procedures vary depending on the distribution, these are usually easy and straightforward steps. Refer to the installation screens that come with the documentation and you should be done in an hour or two.
There will be a few configuration steps as part of the installation such as setting the date and time, language, and selecting the software packages to install.
Once the installation is done, reboot your computer.
We all want a smooth-sailing installation but in case things don’t go your way, here are some initial troubleshooting tips that you can check.
Installer fails to start X Window
X Window is the graphical user interface included in many Linux distributions. If in case the installer did not detect the video card or for any other reason that the installer fails to start X, you can opt to do text mode installation.
Refer to the table below for some of the different ways on how you can access the text mode installation screen.
How to Access Text Mode Installation
Default is text mode
Type in text when you see the boot: prompt
Press F3 and use the arrow keys to select the Text-Mode option. Press Enter.
Default is text mode
Press on the Shift key while rebooting from the CD/DVD drive. Choose Rescue Console. Type quick_install when you see the bash prompt.
Table 2: How to Access Text-Mode during installation
Is your distro not in the list? Find out how you can start text-mode installation for your distribution online.
The text mode installation screen is similar to the installation screens in which you have to respond to the prompts to perform the installation. Once you are in text mode, read the prompts carefully and follow the instructions.
X is not working after installation
If you happen to see the GUI during the installation but after the first reboot you are confronted with a grey screen or a black screen with an X in the middle, here are some steps that you can use to troubleshoot.
1. Reboot the PC. Press Ctrl+Alt+Delete.
2. Once the PC is booting up, press the A key if the distribution uses GRUB (GR and Unified Bootloader). For LILO, skip this step. The GRUB boot loader will then display a command line for the Linux kernel and will ask you to add what you want.
3. For GRUB, type a space and then word single. Press Enter. If using LILO, type Linux single then press Enter. The Linux kernel will boot in a single-user mode with the following prompt:
Once you see this prompt, you can now start to configure X.
Depending on the distribution you are using, X uses a configuration file to setup your display card, monitor, and resolution. The problem sometimes happens when the X configuration from the Linux installer is not right.
Solve this problem by creating a working configuration file:
1. Type the following command:
Once you enter this command, the X server will create a configuration file. You’ll see the screen go blank and then display several messages.
2. Use vi, a text editor and edit the file///etc/xorg.conf.new. Insert the linebelow afterSection "Files":line
When using Fedora, you also need to change /dev/mouse to /dev/input/mice.
3. Start the X font server by typing the command below:
4. Type the line below to start the new configuration file.
X -config ///etc/xorg.conf.new
Once you see the blank screen with an X cursor, the configuration file is working fine.
5. Use Ctrl+Alt+Backspace to stop the X server
6. Type the command below to copy the config file to the /etc/X11 directory:
cp ///etc/xorg.conf.new /etc/X11/xorg.conf
7. Type the wordreboot or press Ctrl+Alt+Delete to reboot the computer.
The login screen should come up if the config file change went well.
Most, if not all, Linux distributions have a solid community online. If you encounter problems during the installation, search for the problem, describe it in detail, or use the actual error message as your search keyword. You will find the information that you need and if not, you can always post in the forums and the community will be ready to help.
Visit the following forums for more information:
Linux Mint: http://linuxmint.com/forum/
In this chapter, we discussed about the Linux installation proper. Now that you have Linux in your PC, we’ll do a walkthrough of your first Linux experience.