Phase 1 |
|
1 |
Introduction |
|
|
1.1 |
Unix
and Linux |
|
|
1.2 |
Unix System Architecture |
|
|
1.3 |
Unix Philosophy. |
|
|
1.4 |
What is Linux? . |
|
|
1.5 |
Using a Linux System . |
|
|
1.6 |
Linux Command Line . |
|
|
1.7 |
Logging Out . |
|
|
1.8 |
Command Syntax . |
|
|
1.9 |
Files. |
|
|
1.10 |
Creating Files with cat . |
|
|
1.11 |
Displaying Files’ Contents
with cat . |
|
|
1.12 |
Deleting Files with rm . |
|
|
1.13 |
Unix Command Feedback . |
|
|
1.14 |
Copying and Renaming Files with cp and mv . |
|
|
1.15 |
Filename Completion . |
|
|
1.16 |
Command History . |
|
|
1.17 |
Exercises . |
|
|
|
|
|
2) |
|
|
|
2.1 |
Files and Directories
. |
|
|
2.2 |
Examples of Absolute
Paths |
|
|
2.3 |
|
|
|
2.4 |
Making and Deleting
Directories . |
|
|
2.5 |
|
|
|
2.6 |
Special Dot Directories . |
|
|
2.7 |
Using Dot Directories in Paths . |
|
|
2.8 |
Hidden Files . |
|
|
2.9 |
Paths to Home Directories . |
|
|
2.10 |
Looking for Files in the System
. |
|
|
2.11 |
Running Programs . |
|
|
2.12 |
Specifying Multiple Files . |
|
|
2.13 |
Finding Documentation for Programs |
|
|
2.14 |
Specifying Files with Wildcards |
|
|
2.15 |
Chaining Programs Together. |
|
|
2.16 |
Graphical and Text Interfaces. |
|
|
2.17 |
Text Editors. |
|
|
2.18 |
Exercises |
|
|
|
|
|
3) |
Work Effectively
on the Unix Command Line |
|
|
3.1 |
Shells . |
|
|
3.2 |
The Bash Shell |
|
|
3.3 |
Shell Commands |
|
|
3.4 |
Command-Line Arguments |
|
|
3.5 |
Syntax of Command-Line Options . |
|
|
3.6 |
Examples of Command-Line Options |
|
|
3.7 |
Setting Shell Variables . |
|
|
3.8 |
Environment Variables . |
|
|
3.9 |
Where Programs are Found |
|
|
3.10 |
Bash Configuration Variables |
|
|
3.11 |
Using History . |
|
|
3.12 |
Reusing History Items . |
|
|
3.13 |
Retrieving Arguments from the History |
|
|
3.14 |
Summary of Bash Editing Keys . |
|
|
3.15 |
Combining Commands on One Line |
|
|
3.16 |
Repeating Commands with for. |
|
|
3.17 |
Command Substitution . |
|
|
3.18 |
Finding Files with locate . |
|
|
3.19 |
Finding Files More Flexibly: find
. |
|
|
3.20 |
Find Criteria . |
|
|
3.21 |
Find Actions: Executing Programs
. |
|
|
3.22 |
Exercises. |
|
|
|
|
|
|
|
|
Phase 2 |
|
4) |
Process Text Streams
Using Text Processing Filters |
|
|
4.1 |
Working with Text Files . |
|
|
4.2 |
Lines of Text . |
|
|
4.3 |
Filtering Text and Piping . |
|
|
4.4 |
Displaying Files with less . |
|
|
4.5 |
Counting Words and Lines with wc. |
|
|
4.6 |
Sorting Lines of Text with sort . |
|
|
4.7 |
Removing Duplicate Lines with uniq . |
|
|
4.8 |
Selecting Parts of Lines with cut . |
|
|
4.9 |
Expanding Tabs to Spaces with expand . |
|
|
4.10 |
Using fmt to Format Text Files. |
|
|
4.11 |
Reading the Start of a File with head . |
|
|
4.12 |
Reading the End of a File with tail . |
|
|
4.13 |
Numbering Lines of a File with nl or cat . |
|
|
4.14 |
Dumping Bytes of Binary Data with od . |
|
|
4.15 |
Paginating Text Files with pr. |
|
|
4.16 |
Dividing Files into Chunks with split . |
|
|
4.17 |
Using split to Span Disks . |
|
|
4.18 |
Reversing Files with tac |
|
|
4.19 |
Translating Sets of Characters with tr . |
|
|
4.20 |
tr Examples . |
|
|
4.21 |
Modifying Files with sed |
|
|
4.22 |
Substituting with sed . |
|
|
4.23 |
Put Files Side-by-Side with paste |
|
|
4.24 |
Performing Database Joins with join
. |
|
|
4.25 |
Exercises |
|
|
|
|
|
5) |
Perform Basic
File Management |
|
|
5.1 |
Filesystem Objects . |
|
|
5.2 |
Directory and File Names . . |
|
|
5.3 |
File Extensions . |
|
|
5.4 |
Going Back to Previous Directories
. |
|
|
5.5 |
Filename Completion . |
|
|
5.6 |
Wildcard Patterns . |
|
|
5.7 |
Copying Files with cp . |
|
|
5.8 |
Examples of cp. |
|
|
5.9 |
Moving Files with mv . |
|
|
5.10 |
Deleting Files with rm . |
|
|
5.11 |
Deleting Files with Peculiar Names. |
|
|
5.12 |
Making Directories with mkdir . |
|
|
5.13 |
Removing Directories with rmdir . |
|
|
5.14 |
Identifying Types of Files . |
|
|
5.15 |
Changing Timestamps with touch . |
|
|
5.16 |
Exercises . |
|
|
|
|
|
6) |
Use Unix Streams,
Pipes and Redirects |
|
|
6.1 |
Standard Files |
|
|
6.2 |
Standard Input . |
|
|
6.3 |
Standard Output . |
|
|
6.4 |
Standard Error . |
|
|
6.5 |
Pipes . |
|
|
6.6 |
Connecting Programs to Files . |
|
|
6.7 |
Appending to Files . |
|
|
6.8 |
Redirecting Multiple Files . |
|
|
6.9 |
Redirection with File Descriptors
. |
|
|
6.10 |
Running Programs with xargs . |
|
|
6.11 |
tee . |
|
|
6.12 |
Exercises . |
|
|
|
|
|
|
|
|
Phase 3 |
|
7) |
Search Text
Files Using Regular Expressions |
|
|
7.1 |
Searching Files with grep . |
|
|
7.2 |
Pattern Matching . |
|
|
7.3 |
Matching Repeated Patterns |
|
|
7.4 |
Matching Alternative Patterns . |
|
|
7.5 |
Extended Regular Expression Syntax
. |
|
|
7.6 |
sed |
|
|
7.7 |
Further Reading . |
|
|
7.8 |
Exercises . |
|
|
|
|
|
8) |
Job Control |
|
|
8.1 |
Job Control. |
|
|
8.2 |
jobs . |
|
|
8.3 |
fg . |
|
|
8.4 |
bg . |
|
|
8.5 |
Exercises . |
|
|
|
|
|
9) |
Create, Monitor,
and Kill Processes |
|
|
9.1 |
What is a Process? . |
|
|
9.2 |
Process Properties . |
|
|
9.3 |
Parent and Child Processes . |
|
|
9.4 |
Process Monitoring: ps . |
|
|
9.5 |
ps Options. |
|
|
9.6 |
Process Monitoring: pstree . |
|
|
9.7 |
pstree Options . |
|
|
9.8 |
Process Monitoring: top . |
|
|
9.9 |
top Command-Line Options . |
|
|
9.10 |
top Interactive Commands . . |
|
|
9.11 |
Signalling Processes |
|
|
9.12 |
Common Signals for Interactive Use
. |
|
|
9.13 |
Sending Signals: kill . |
|
|
9.14 |
Sending Signals to Dæmons:
pidof. |
|
|
9.15 |
Exercises . |
|
|
|
|
|
|
|
|
Phase 4 |
|
10) |
Modify Process
Execution Priorities |
|
|
10.1 |
Concepts . |
|
|
10.2 |
nice . |
|
|
10.3 |
renice . |
|
|
10.4 |
Exercises . |
|
|
|
|
|
11) |
Advanced Shell
Usage |
|
|
11.1 |
More About Quoting . |
|
|
11.2 |
Quoting: Single Quotes. |
|
|
11.3 |
Quoting: Backslashes |
|
|
11.4 |
Quoting: Double Quotes . |
|
|
11.5 |
Quoting: Combining Quoting Mechanisms
. |
|
|
11.6 |
Recap: Specifying Files with Wildcards. |
|
|
11.7 |
Globbing Files Within Directories
. |
|
|
11.8 |
Globbing to Match a Single Character
. |
|
|
11.9 |
Globbing to Match Certain Characters
. |
|
|
11.10 |
Generating Filenames: {} . |
|
|
11.11 |
Shell Programming . |
|
|
11.12 |
Exercises . |
|
|
|
|
|
12) |
Filesystem Concepts |
|
|
12.1 |
Filesystems . |
|
|
12.2 |
The Unified Filesystem . . |
|
|
12.3 |
File Types . |
|
|
12.4 |
Inodes and Directories . |
|
|
|
|
|
|
|
|
Phase 5 |
|
13) |
Create and Change
Hard and Symbolic Links |
|
|
13.1 |
Symbolic Links . |
|
|
13.2 |
Examining and Creating Symbolic
Links . |
|
|
13.3 |
Hard Links . |
|
|
13.4 |
Symlinks and Hard Links Illustrated
. |
|
|
13.5 |
Comparing Symlinks and Hard Links
. |
|
|
13.6 |
Examining and Creating Hard Links. |
|
|
13.7 |
Preserving Links . |
|
|
13.8 |
Finding Symbolic Links to a File
. |
|
|
13.9 |
Finding Hard Links to a File . |
|
|
13.10 |
Exercises . |
|
|
|
|
|
14) |
Manage File
Ownership |
|
|
14.1 |
Users and Groups |
|
|
14.2 |
The Superuser: root. |
|
|
14.3 |
Changing File Ownership with chown . |
|
|
14.4 |
Changing File Group Ownership with chgrp . |
|
|
14.5 |
Changing the Ownership of a Directory
and Its Contents. |
|
|
14.6 |
Changing Ownership and Group Ownership
Simultaneously . |
|
|
14.7 |
Exercises . |
|
|
|
|
|
15) |
Use File Permissions
to Control Access to Files |
|
|
15.1 |
Basic Concepts: Permissions on Files
. |
|
|
15.2 |
Basic Concepts: Permissions on Directories
. |
|
|
15.3 |
Basic Concepts: Permissions for Different
Groups of People |
|
|
15.4 |
Examining Permissions: ls -l . |
|
|
15.5 |
Preserving Permissions When Copying
Files . |
|
|
15.6 |
How Permissions are Applied . |
|
|
15.7 |
Changing File and Directory Permissions:
chmod. |
|
|
15.8 |
Specifying Permissions for chmod
. |
|
|
15.9 |
Changing the Permissions of a Directory
and Its Contents . |
|
|
15.10 |
Special Directory Permissions: ‘Sticky’ . |
|
|
15.11 |
Special Directory Permissions: Setgid
. 73 |
|
|
15.12 |
Special File Permissions: Setgid
. |
|
|
15.13 |
Special File Permissions: Setuid
. |
|
|
15.14 |
Displaying Unusual Permissions |
|
|
15.15 |
Permissions as Numbers . |
|
|
15.16 |
Default Permissions: umask . |
|
|
15.17 |
Exercises . |
|
|
|
|
|
|
|
|
Phase 6 |
|
16) |
Create Partitions
and Filesystems |
|
|
16.1 |
Concepts: Disks and Partitions |
|
|
16.2 |
Disk Naming . |
|
|
16.3 |
Using fdisk. |
|
|
16.4 |
Making New Partitions . |
|
|
16.5 |
Changing Partition Types . . |
|
|
16.6 |
Making Filesystems with mkfs . |
|
|
16.7 |
Useful Websites . |
|
|
|
|
|
17) |
Control Filesystem
Mounting and Unmounting |
|
|
17.1 |
Mounting Filesystems . |
|
|
17.2 |
Mounting a Filesystem: mount . |
|
|
17.3 |
Mounting Other Filesystems . |
|
|
17.4 |
Unmounting a Filesystem: umount
. |
|
|
17.5 |
Configuring mount: /etc/fstab. |
|
|
17.6 |
Sample /etc/fstab . |
|
|
17.7 |
Filesystem Types . |
|
|
17.8 |
Mount Options . |
|
|
17.9 |
Other Columns in /etc/fstab . |
|
|
17.10 |
Mounting a File System . |
|
|
17.11 |
Exercises . |
|
|
|
|
|
18) |
Maintain the
Integrity of Filesystems |
|
|
18.1 |
Filesystem Concepts . |
|
|
18.2 |
Potential Problems . |
|
|
18.3 |
Monitoring Space: df . |
|
|
18.4 |
Monitoring Inodes: df. |
|
|
18.5 |
Monitoring Disk Usage: du . |
|
|
18.6 |
du Options . |
|
|
18.7 |
Finding and Repairing Filesystem
Corruption: fsck . |
|
|
18.8 |
Running fsck . |
|
|
18.9 |
Exercises . |
|
|
|
|
|
|
|
|
Phase 7 |
|
19) |
Find System Files
and Place Files in the Correct Location |
|
|
19.1 |
Unix Filesystem Layout . |
|
|
19.2 |
The Filesystem Hierarchy Standard |
|
|
19.3 |
Shareable and Non-Shareable Data
. |
|
|
19.4 |
Static and Dynamic Data . |
|
|
19.5 |
Overview of the FHS. |
|
|
19.6 |
FHS: Installed Software . |
|
|
19.7 |
FHS: Other Directories Under /usr . |
|
|
19.8 |
FHS: Directories Under /var . |
|
|
19.9 |
FHS: Other Directories . |
|
|
19.10 |
FHS: Other Directories . |
|
|
19.11 |
Finding Programs with which . |
|
|
19.12 |
The Type Built-in Command . |
|
|
19.13 |
Checking for Shell Builtins with type . |
|
|
19.14 |
Updating the locate Database . |
|
|
19.15 |
updatedb.conf . |
|
|
19.16 |
whatis . |
|
|
19.17 |
Finding Manpages with apropos |
|
|
19.18 |
Web Resources . |
|
|
19.19 |
Exercises . |
|
|
|
|
|
20) |
Set and View
Disk Quotas |
|
|
20.1 |
What are Quotas? . |
|
|
20.2 |
Hard and Soft Limits . |
|
|
20.3 |
Per-User and Per-Group Quotas . |
|
|
20.4 |
Block and Inode Limits. |
|
|
20.5 |
Displaying Quota Limits: quota . |
|
|
20.6 |
Options in /etc/fstab . |
|
|
20.7 |
Enabling Quota: quotaon . |
|
|
20.8 |
Changing Quota Limits: setquota
. |
|
|
20.9 |
edquota . |
|
|
20.10 |
repquota. |
|
|
|
|
|
21) |
Boot the System |
|
|
21.1 |
Boot Loaders . |
|
|
21.2 |
LILO . |
|
|
21.3 |
Sample lilo.conf File . |
|
|
21.4 |
Selecting What to Boot . |
|
|
21.5 |
Other Ways of Starting Linux . |
|
|
21.6 |
Specifying Kernel Parameters . |
|
|
21.7 |
Specifying Kernel Parameters in lilo.conf . |
|
|
21.8 |
Useful Kernel Parameters . |
|
|
21.9 |
Boot Messages . |
|
|
21.10 |
Kernel Modules . |
|
|
21.11 |
Exercises . |
|
|
|
|
|
|
|
|
Phase 8 |
|
22) |
Change Runlevels
and Shutdown or Reboot System |
|
|
22.1 |
Understanding Runlevels . |
|
|
22.2 |
Typical Runlevels . |
|
|
22.3 |
Single-User Mode and sulogin . |
|
|
22.4 |
Shutting Down and Restarting the
System . |
|
|
22.5 |
Setting the Default Runlevel . |
|
|
22.6 |
Selecting a Different Runlevel at Bootup
. |
|
|
22.7 |
Determining the Current Runlevel
. |
|
|
22.8 |
Switching Runlevel. |
|
|
22.9 |
Services in Each Runlevel: the init.d Directory
. |
|
|
22.10 |
Symbolic Links in rcN.d . |
|
|
22.11 |
Starting or Stopping Individual
Services . |
|
|
22.12 |
Exercises . |
|
|
|
|
|
23) |
Use and Manage
Local System Documentation |
|
|
23.1 |
Manual Pages . |
|
|
23.2 |
Navigating Within Manual Pages . |
|
|
23.3 |
Sections of a Manual Page |
|
|
23.4 |
Sections of the Manual . |
|
|
23.5 |
Manual Section Numbering . |
|
|
23.6 |
Determining Available Manpages with whatis . |
|
|
23.7 |
Printing Manual Pages . |
|
|
23.8 |
Searching for Manpages with apropos
. |
|
|
23.9 |
Displaying All Manpages of a Particular
Name with man -a . |
|
|
23.10 |
Searching the Content of All Manpages
with man -K . |
|
|
23.11 |
Finding the Right Manual Page . |
|
|
23.12 |
Help on Shell Builtins . |
|
|
23.13 |
Location of Manual Pages . |
|
|
23.14 |
Info Pages . |
|
|
23.15 |
Navigating Within Info Pages . . |
|
|
23.16 |
Documentation in /usr/share/doc/ . |
|
|
23.17 |
Contents of /usr/share/doc . |
|
|
23.18 |
Interrogating Commands for Help
. |
|
|
23.19 |
Finding Documentation . |
|
|
23.20 |
Exercises . |
|
|
|
|
|
24) |
Find Linux Documentation
on the Internet |
|
|
24.1 |
The Linux Documentation Project
. |
|
|
24.2 |
HOWTOs . |
|
|
24.3 |
Obtaining HOWTOs . |
|
|
24.4 |
Vendor- and Application-Specific
Web Sites . |
|
|
24.5 |
Usenet Newsgroups . |
|
|
24.6 |
FAQs . |
|
|
24.7 |
Local Help. |
|
|
|
|
|
|
|
|
Phase 9 |
|
25) |
Tune the User
Environment and System Environment Variables |
|
|
25.1 |
Configuration Files . |
|
|
25.2 |
Shell Configuration Files . |
|
|
25.3 |
Changing Environment Variables . |
|
|
25.4 |
Changing the Prompt . |
|
|
25.5 |
Shell Aliases . |
|
|
25.6 |
Setting Up Home Directories for
New Accounts . |
|
|
25.7 |
Exercises . |
|
|
|
|
|
26) |
Configure and
Use System Log Files |
|
|
26.1 |
syslog . . |
|
|
26.2 |
/etc/syslog.conf . |
|
|
26.3 |
Sample /etc/syslog.conf . |
|
|
26.4 |
Reconfiguring syslog . |
|
|
26.5 |
Examining Logs: less and grep . |
|
|
26.6 |
Examining Logs in Real Time: tail
. |
|
|
26.7 |
Log Rotation . |
|
|
26.8 |
Sample /etc/logrotate.conf . |
|
|
26.9 |
Exercises . |
|
|
|
|
|
27) |
Automate and
Schedule System Administration Tasks |
|
|
27.1 |
Running Commands in the Future . |
|
|
27.2 |
at Commands . |
|
|
27.3 |
Commands Run by the at Dæmon
. |
|
|
27.4 |
at Command Specification . |
|
|
27.5 |
Opening Windows from at Commands. |
|
|
27.6 |
at Command Date & Time Specification
. |
|
|
27.7 |
Managing at Commands . |
|
|
27.8 |
Simple cron Job Specification . |
|
|
27.9 |
More Complex cron Job Specification
. |
|
|
27.10 |
crontab Format . |
|
|
27.11 |
crontab Date & Time Specification |
|
|
27.12 |
More Complex crontab Dates & Times
. |
|
|
27.13 |
/etc/crontab . |
|
|
27.14 |
User crontabs . |
|
|
27.15 |
cron Job Output . . |
|
|
27.16 |
at Command and cron Job Permissions
. |
|
|
27.17 |
Exercises . |
|
|
|
|
|
28) |
Maintain an
Effective Data Backup Strategy |
|
|
28.1 |
Reasons for Backup . |
|
|
28.2 |
Backup Media . |
|
|
28.3 |
Types of Backup . |
|
|
28.4 |
Backup Strategy . |
|
|
28.5 |
Archiving Files with tar . |
|
|
28.6 |
Creating Archives with tar . |
|
|
28.7 |
Listing the Files in tar Archives
. |
|
|
28.8 |
Extracting Files from tar Archives
. |
|
|
28.9 |
Device Files for Accessing Tapes
. |
|
|
28.10 |
Using tar for Backups . |
|
|
28.11 |
Controlling Tape Drives with mt . |
|
|
28.12 |
Deciding What to Backup . |
|
|
28.13 |
What Not to Backup . |
|
|
28.14 |
Scripting Backup . |
|
|
28.15 |
Other Backup Software . |
|
|
28.16 |
Exercises . |