Title: Linux Guide to Linux Certification, Third Edition
1Linux Guide to Linux Certification, Third Edition
- Chapter 2
- Linux Installation and Usage
2Objectives
- Install Red Hat Fedora Linux using good practices
- Outline the structure of the Linux interface
- Enter basic shell commands and find command
documentation - Properly shut down the Linux operating system
3Installing Linux Preparing for Installation
- All OSs require a minimum set of hardware
components to function properly - Can be obtained from manual or file in DVD of OS,
or from vendor website - Each individual hardware component should be
checked against the Hardware Compatibility List
(HCL) found on the vendors Web site
4Installing Linux Preparing for Installation
(continued)
Table 2-1 Fedora 13 hardware requirements
5Installing Linux Preparing for Installation
(continued)
- Need to identify software that will be used in
the Linux operating system - Computers host name
- Network configuration parameters
- Specific software packages to be installed
- Create preinstallation checklist to document
hardware and software information
6Table 2-2 Sample preinstallation checklist
7Installing Linux Installation Methods
- DVD media
- FTP server
- HTTP Web server
- NFS server
- SMB server
- Packages on hard disk
- CD-ROM media
8Starting the Installation and Checking Media for
Errors
- Boot from first Red Hat Fedora Linux DVD
- A Welcome screen is displayed, can select option
- Default graphical installation
- Installation with basic video driver
- Rescue installed items
- Boot from local drive
- Memory test
- Check media for errors prior to installation
- Optional, but recommended
9Starting the Installation and Checking Media for
Errors (continued)
Figure 2-1 Beginning a Fedora installation
10Starting the Installation and Checking Media for
Errors (continued)
Figure 2-3 Testing DVD media
11Choosing the Language, Keyboard, and Storage Type
- Allowed to choose installation language
- Choose keyboard configuration
- Keyboard model and layout automatically detected
- Select types of storage devices used to host the
Linux OS - For internal or locally attached hard drive
installation, select Basic Storage Devices - For installation on SAN or DASD, select
Specialized Storage Devices
12Choosing the Language, Keyboard, and Storage Type
(continued)
Figure 2-4 Selecting an installation language
13Choosing the Language, Keyboard, and Storage Type
(continued)
Figure 2-5 Verifying keyboard configuration
14Selecting a Host Name, Time Zone, and Root
Password
- Supply a host name that will identify system on
the network - By default use localhost.localdomain
- Important to select correct time zone for the
local system - Authentication Users log in via valid user name
and password - Configure two user accounts
- Administrator account (root) full rights to
system - Regular user account
15Selecting a Host Name, Time Zone, and Root
Password (continued)
Figure 2-7 Selecting a host name
16Selecting a Host Name, Time Zone, and Root
Password (continued)
Figure 2-8 Selecting a time zone
17Selecting a Host Name, Time Zone, and Root
Password (continued)
Figure 2-9 Setting a root password
18Configuring Storage Devices
- Most common storage devices for storing Linux OS
are hard disks - Parallel Advanced Technology Attachment (PATA)
- Serial Advanced Technology Attachment (SATA)
- Small Computer Systems Interface (SCSI)
- Each hard disk is divided into partitions
- Partitions formatted with filesystems
- Maximum four primary partitions
- Extended partition can be divided into logical
drives
19Configuring Storage Devices (continued)
Table 2-3 PATA hard disk configurations
20Configuring Storage Devices (continued)
Table 2-4 Example of a partitioning scheme for a
primary master IDE hard disk
21Configuring Storage Devices (continued)
- Filesystems can be accessed if attached (mounted)
to a directory - Minimum of two partitions
- Partition for root directory
- Partition for virtual memory (swap memory)
- Area on hard disk used to store information
normally residing in physical memory (RAM) - Automatic or manual partitioning
- Better to manually partition
22Table 2-5 Common Linux filesystems and sizes
23Configuring Storage Devices (continued)
- Different types of filesystems
- Ext2 used on most Linux computers
- Ext3, Ext4 performs journaling
- Vfat compatible with Windows FAT filesystem
- REISER performs journaling
- Journaling keeps track of the information
written to the hard drive
24Configuring Storage Devices (continued)
Figure 2-10 Selecting a partition strategy
25Configuring Storage Devices (continued)
- When creating a partition, specify the partition
technology - For standard disk partitions need to provide
information regarding size, filesystem type,
encryption options and mount point - Instead of standard partitions, can create
volumes that span multiple disks - Logical Volume Manager (LVM)
- Redundant Array of Inexpensive Disks (RAID)
26Configuring the Boot Loader
- Boot loader program started by BIOS at system
startup - Loads Linux kernel into memory from hard disk
- Can also boot other existing OSs
- GRand Unified Bootloader (GRUB) boot loader
configured during Fedora Linux installation - Dual booting choose OS to boot at startup
27Configuring the Boot Loader (continued)
Figure 2-14 Configuring a boot loader
28Configuring the Boot Loader (continued)
- Boot loader usually resides on the MBR or on
first sector of / or /boot partition - Kernel parameters information passed to Linux
kernel via the boot loader - Large Block Addressing 32-bit (LBA32) enables
Large Block Addressing in boot loader - For large hard disks not fully supported by the
BIOS
29Selecting and Installing Packages
Figure 2-15 Selecting system role and software
repositories
30Selecting and Installing Packages (continued)
Figure 2-16 Selecting individual packages
31Completing the Firstboot Wizard
- Complete the installation
- License agreement
- User accounts and authentication
- Date and time
- Network Time Protocol (NTP)
- Confirmation of hardware to be used
- Log in with user account for daily tasks
- Use Network Login authenticate users based on an
external database
32Completing the Firstboot Wizard (continued)
Figure 2-18 Creating a regular user account
33Completing the Firstboot Wizard (continued)
Figure 2-19 Choosing authentication options
34Completing the Firstboot Wizard (continued)
Figure 2-20 Advanced authentication options
35Completing the Firstboot Wizard (continued)
Figure 2-21 Setting the date and time
36Completing the Firstboot Wizard (continued)
Figure 2-22 Viewing the hardware profile
37Basic Linux Usage Shells, Terminals, and the
Kernel
- Terminal channel allowing users to log on to the
kernel locally or across a network - Shell user interface which accepts user inputs
and transfers them to the kernel - BASH Shell (Bourne Again Shell) default Linux
shell - Command line shell
- Linux allows multiple terminals, each with its
own shell
38Basic Linux Usage Shells, Terminals, and the
Kernel (continued)
Figure 2-23 Shells, terminals, and the kernel
39Basic Linux Usage Shells, Terminals, and the
Kernel (continued)
- Graphical interface
- Start GUI environment on top of BASH shell
- Or, switch to a graphical terminal
- e.g., GNOME Display Manager (gdm)
- From the local server, use key combinations to
change to separate terminal - Command-line terminal may be accessed from GUI
environment - Command line prompt
- Root user
- Regular user
40Basic Linux Usage Shells, Terminals, and the
Kernel (continued)
Table 2-6 Common Linux terminals
41Basic Linux Usage Shells, Terminals, and the
Kernel (continued)
Figure 2-25 Accessing a command-line terminal in
a GUI environment
42Basic Shell Commands
- Commands indicate name of program to execute
- Case sensitive
- Options specific letters starting with -
appearing after command name - Alter way command works
- Arguments specify a commands specific working
parameters
43Basic Shell Commands (continued)
Table 2-7 Some common Linux commands
44Shell Metacharacters
- Metacharacters characters with a special meaning
- e.g.,
- Refers to a variable
- Avoid use of metacharacters when typing commands
unless using their special functionality - Single quotation marks protect metacharacter
from being interpreted specially by the shell
45Shell Metacharacters (continued)
Table 2-8 Common BASH Shell metacharacters
46Getting Command Help
- Manual (man) pages most common form of
documentation for Linux commands - At command prompt, type man followed by command
name - Contain different sections
- Searchable by keyword
- Info pages set of local, easy-to-read command
syntax documentation - At command prompt, type info followed by a
command name
47Getting Command Help (continued)
Table 2-9 Manual page section numbers
48Shutting Down the Linux System
Table 2-10 Commands to halt and reboot the Linux
operating system
49Summary
- Prior to installation
- Verify hardware requirements using HCL
- Create preinstallation checklist
- DVDbased installation
- Easiest
- Most common
50Summary (continued)
- Installation prompts for language, host name,
date, time zone, keyboard layout, user account
configuration, storage configuration, boot loader
configuration, and package selection - Users must log in to a terminal and receive a
shell before they are able to interact with the
Linux system and kernel
51Summary (continued)
- From any type of terminal you can enter commands,
options, and arguments at a shell prompt to
perform system tasks, obtain command help, or
shut down the Linux system - The shell is case sensitive and understands a
variety of special characters called shell
metacharacters, which should be protected if
their special meaning is not required