Home > Store

Practical Guide to Linux Commands, Editors, and Shell Programming, A

Register your product to gain access to bonus material or receive a coupon.

Practical Guide to Linux Commands, Editors, and Shell Programming, A


  • Sorry, this book is no longer in print.
Not for Sale



Appropriate for:

  • Students taking a class in which they use Linux
  • Computer science students who are studying the Linux operating system
  • Students learning system administration who need a deeper understanding of Linux and the tools available

The essential reference for core commands that Linux users need daily, along with

superior tutorial on shell programming and much more

o         The book is a complete revision of the commands section of Sobell's Practical

o         Guide to Linux -- a proven best-seller

o         The book is Linux distribution and release agnostic. It will appeal to users of ALL

o         Linux distributions.

o         ° Superior examples make this book the best option on the market!


  • Copyright 2006
  • Edition: 1st
  • Book
  • ISBN-10: 0-13-147823-0
  • ISBN-13: 978-0-13-147823-7

Praise for Mark Sobell’s Books

“I keep searching for books that collect everything you want to know about a subject in one place, and keep getting disappointed. Usually the books leave out some important topic, while others go too deep in some areas and must skim lightly over the others. A Practical Guide to Red Hat® Linux® is one of those rare books that actually pulls it off. Mark G. Sobell has created a single reference for Red Hat Linux that cannot be beat! This marvelous text (with a 4-CD set of Linux Fedora Core 2 included) is well worth the price. This is as close to an ‘everything you ever needed to know’ book that I’ve seen. It’s just that good and rates 5 out of 5.”
—Ray Lodato, Slashdot contributor
“Mark Sobell has written a book as approachable as it is authoritative.”
—Jeffrey Bianchine, Advocate, Author, Journalist
“Excellent reference book, well suited for the sysadmin of a linux cluster, or the owner of a PC contemplating installing a recent stable linux. Don’t be put off by the daunting heft of the book. Sobell has striven to be as inclusive as possible, in trying to anticipate your system administration needs.”
—Wes Boudville, Inventor
A Practical Guide to Red Hat® Linux® is a brilliant book. Thank you Mark Sobell.”
—C. Pozrikidis, University of California at San Diego
“This book presents the best overview of the Linux operating system that I have found. . . . It should be very helpful and understandable no matter what the reader’s background is: traditional UNIX user, new Linux devotee, or even Windows user. Each topic is presented in a clear, complete fashion and very few assumptions are made about what the reader knows. . . . The book is extremely useful as a reference, as it contains a 70-page glossary of terms and is very well indexed. It is organized in such a way that the reader can focus on simple tasks without having to wade through more advanced topics until they are ready.”
—Cam Marshall, Marshall Information Service LLC, Member of Front Range UNIX Users Group FRUUG, Boulder, Colorado
“Conclusively, this is THE book to get if you are a new Linux user and you just got into RH/Fedora world. There’s no other book that discusses so many different topics and in such depth.”
—Eugenia Loli-Queru, Editor in Chief, OSNews.com
The Most Useful Linux Tutorial and Reference Ever, with Hundreds of High-Quality Examples Covering Every Linux Distribution!

To be truly productive with Linux, you need to thoroughly master the shells and the command line. Until now, you had to buy two books to gain that mastery: a tutorial on fundamental Linux concepts and techniques, plus a separate reference. Worse, most Linux references offer little more than prettied-up man pages. Now, there’s a far better solution. Renowned Linux expert Mark Sobell has brought together comprehensive, insightful guidance on the tools system administrators, developers, and power users need most, and an outstanding day-to-day reference, both in the same book.

This book is 100 percent distribution and release agnostic: You can use it on any Linux system, now and for years to come. What’s more, it’s packed with hundreds of high-quality examples: better examples than you’ll find in any other Linux guidebook. This is Linux from the ground up: the clearest explanations and most useful knowledge about everything from filesystems to shells, editors to utilities, and programming tools to regular expressions. And when you need instant answers, you’ll constantly turn to Sobell’s comprehensive command reference section—organized and tabbed for easy, fast access!

Don’t settle for yesterday’s Linux guidebook. Get the one book that meets today’s challenges—and tomorrow’s!

A Practical Guide to Linux® Commands, Editors, and Shell Programming is the most useful, most comprehensive Linux tutorial and reference you can find. It’s the only book to deliver

  • Better, more realistic examples covering tasks you’ll actually need to perform
  • Deeper insight, based on Sobell’s immense knowledge of every Linux nook and cranny
  • More practical explanations of more than eighty core utilities, from aspell to xargs
  • Techniques for implementing secure communications using ssh and scp—plus dozens of tips for making your system more secure
  • A superior introduction to the Linux programming environment, including make, gcc, gdb, CVS, and much more
  • Expert guidance on basic and advanced shell programming using bash and tcsh
  • Tips and tricks for customizing the shell and using it interactively from the command line
  • Thorough guides to vim and emacs, designed to help you get productive fast and maximize your editing efficiency
  • Dozens of exercises to help you practice and gain confidence
  • Instructions for using Apt, yum, and BitTorrent for keeping your system up to date automatically
  • And much more, including coverage of gawk, sed, find, sort, bzip2, and regular expressions


Related Article

Vector Programming with GCC

Author's Site

Visit the author's web site: http://www.sobell.com

Sample Content

Table of Contents

Preface xxvii

Chapter 1: Welcome to Linux 1

The GNU-Linux Connection 2

The Heritage of Linux: UNIX 5

What Is So Good About Linux? 6

Overview of Linux 10

Additional Features of Linux 15

Chapter Summary 16

Exercises 17

Part I: The Linux Operating System 19

Chapter 2: Getting Started 21

Conventions Used in This Book 22

Logging In 24

Working with the Shell 25

Curbing Your Power: Superuser Access 28

Getting the Facts: Where to Find Documentation 29

More About Logging In 35

Chapter Summary 38

Exercises 39

Advanced Exercises 39

Chapter 3: Command Line Utilities 41

Special Characters 42

Basic Utilities 43

Working with Files 45

| (Pipe): Communicates Between Processes 52

Four More Utilities 53

Compressing and Archiving Files 56

Locating Commands 61

Obtaining User and System Information 63

Communicating with Other Users 67

Email 69

Chapter Summary 69

Exercises 72

Advanced Exercises 73

Chapter 4: The Linux Filesystem 75

The Hierarchical Filesystem 76

Directory and Ordinary Files 77

Working with Directories 88

Access Permissions 91

Links 96

Chapter Summary 102

Exercises 103

Advanced Exercises 105

Chapter 5: The Shell 107

The Command Line 108

Standard Input and Standard Output 113

Running a Program in the Background 125

Filename Generation/Pathname Expansion 127

Builtins 132

Chapter Summary 133

Exercises 134

Advanced Exercises 136

Part II: The Editors 137

Chapter 6: The vim Editor 139

History 140

Tutorial: Creating and Editing a File with vim 141

The compatible Parameter 148

Introduction to vim Features 148

Command Mode: Moving the Cursor 154

Input Mode 158

Command Mode: Deleting and Changing Text 160

Searching and Substituting 164

Miscellaneous Commands 170

Yank, Put, and Delete Commands 171

Reading and Writing Files 174

Setting Parameters 175

Advanced Editing Techniques 180

Units of Measure 184

Chapter Summary 188

Exercises 193

Advanced Exercises 194

Chapter 7: The emacs Editor 195

History 196

Tutorial: Getting Started with emacs 198

Basic Editing Commands 204

Online Help 209

Advanced Editing 212

Language-Sensitive Editing 225

Customizing emacs 235

More Information 240

Chapter Summary 241

Exercises 248

Advanced Exercises 250

Part III: The Shells 253

Chapter 8: The Bourne Again Shell 255

Background 256

Shell Basics 257

Parameters and Variables 277

Processes 292

History 295

Aliases 312

Functions 315

Controlling bash Features and Options 318

Processing the Command Line 322

Chapter Summary 332

Exercises 334

Advanced Exercises 336

Chapter 9: The TC Shell 339

Shell Scripts 340

Entering and Leaving the TC Shell 341

Features Common to the Bourne Again and TC Shells 343

Redirecting Standard Error 349

Working with the Command Line 350

Variables 355

Control Structures 368

Builtins 377

Chapter Summary 381

Exercises 382

Advanced Exercises 384

Part IV: Programming Tools 385

Chapter 10: Programming Tools 387

Programming in C 388

Using Shared Libraries 396

make: Keeps a Set of Programs Current 399

Debugging C Programs 407

Threads 417

System Calls 417

Source Code Management 420

Chapter Summary 430

Exercises 431

Advanced Exercises 432

Chapter 11: Programming the Bourne Again Shell 435

Control Structures 436

File Descriptors 470

Parameters and Variables 474

Builtin Commands 487

Expressions 501

Shell Programs 510

Chapter Summary 520

Exercises 522

Advanced Exercises 524

Chapter 12: The gawk Pattern Processing Language 527

Syntax 528

Arguments 528

Options 529

Notes 529

Language Basics 530

Examples 537

Advanced gawk Programming 554

Error Messages 559

Chapter Summary 560

Exercises 561

Advanced Exercises 561

Chapter 13: The sed Editor 563

Syntax 564

Arguments 564

Options 564

Editor Basics 565

Examples 568

Chapter Summary 578

Exercises 579

Part V: Command Reference 581

Standard Multiplicative Suffixes 586

Common Options 587

The sample Utility 587

sample: Very brief description of what the utility does 588

aspell: Checks a file for spelling errors 589

at: Executes commands at a specified time 593

bzip2: Compresses or decompresses files 596

cal: Displays a calendar 598

cat: Joins and displays files 599

cd: Changes to another working directory 601

chgrp: Changes the group associated with a file 603

chmod: Changes the access mode (permissions) of a file 604

chown: Changes the owner of a file and/or the group the file is associated with 608

cmp: Compares two files 610

comm: Compares sorted files 612

configure: Configures source code automatically 614

cp: Copies files 616

cpio: Creates an archive or restores files from an archive 619

crontab: Maintains crontab files 624

cut: Selects characters or fields from input lines 627

date: Displays or sets the system time and date 630

dd: Converts and copies a file 633

df: Displays disk space usage 636

diff: Displays the differences between two files 638

du: Displays information on disk usage by file 644

echo: Displays a message 647

expr: Evaluates an expression 649

file: Displays the classification of a file 653

find: Finds files based on criteria 655

finger: Displays information about users 661

fmt: Formats text very simply 664

fsck: Checks and repairs a filesystem 666

ftp: Transfers files over a network 671

gcc: Compiles C and C++ programs 678

grep: Searches for a pattern in files 683

gzip: Compresses or decompresses files 688

head: Displays the beginning of a file 691

kill: Terminates a process by PID 693

killall: Terminates a process by name 695

less: Displays text files, one screen at a time 697

ln: Makes a link to a file 702

lpr: Sends files to printers 705

ls: Displays information about one or more files 708

make: Keeps a set of programs current 715

man: Displays documentation for commands 721

mkdir: Creates a directory 724

mkfs: Creates a filesystem on a device 725

Mtools: Uses DOS-style commands on files and directories 728

mv: Renames or moves a file 732

nice: Changes the priority of a command 734

nohup: Runs a command that keeps running after you log out 736

od: Dumps the contents of a file 737

paste: Joins corresponding lines from files 742

pr: Paginates files for printing 744

ps: Displays process status 746

rcp: Copies one or more files to or from a remote system 750

rlogin: Logs in on a remote system 752

rm: Removes a file (deletes a link) 753

rmdir: Removes a directory 755

rsh: Executes commands on a remote system 756

scp: Securely copies one or more files to or from a remote system 758

sleep: Creates a process that sleeps for a specified interval 760

sort: Sorts and/or merges files 762

split: Divides a file in into sections 771

ssh: Securely executes commands on a remote system 773

strings: Displays strings of printable characters 777

stty: Displays or sets terminal parameters 778

tail: Displays the last part (tail) of a file 783

tar: Stores or retrieves files to/from an archive file 786

tee: Copies standard input to standard output and one or more files 791

telnet: Connects to a remote system over a network 792

test: Evaluates an expression 794

top: Dynamically displays process status 798

touch: Changes a file's access and/or modification time 801

tr: Replaces specified characters 804

tty: Displays the terminal pathname 807

tune2fs: Changes parameters on an ext2 or ext3 filesystem 808

umask: Establishes the file-creation permissions mask 810

uniq: Displays unique lines 812

w: Displays information about system users 814

wc: Displays the number of lines, words, and bytes 816

which: Shows where in PATH a command is located 817

who: Displays information about logged-in users 819

xargs: Converts standard input into command lines 821

Part VI: Appendixes 825

Appendix A: Regular Expressions 827

Characters 828

Delimiters 828

Simple Strings 828

Special Characters 828

Rules 831

Bracketing Expressions 832

The Replacement String 833

Extended Regular Expressions 834

Appendix Summary 835

Appendix B: Help 837

Solving a Problem 838

Finding Linux-Related Information 839

Specifying a Terminal 844

Appendix C: Keeping the System Up-to-Date 847

yum: Updates and Installs Packages 848

Apt: An Alternative to yum 850

BitTorrent 855

Glossary 859

Index 913


Untitled Document

A Practical Guide to Linux ® Commands, Editors, and Shell Programming explains how to work with the Linux operating system from the command line. The first few chapters quickly bring readers with little computer experience up to speed. The rest of the book is appropriate for more experienced computer users. This book does not describe a particular release or distribution of Linux but rather pertains to all recent versions of Linux.

Command line interface (CLI). In the beginning there was the command line (textual) interface (CLI), which enabled you to give Linux commands from the command line. There was no mouse or icons to drag and drop. Some programs, such as emacs , implemented rudimentary windows using the very minimal graphics available in the ASCII character set. Reverse video helped separate areas of the screen. Linux was born and raised in this environment.

Naturally all of the original Linux tools were invoked from the command line. The real power of Linux still lies in this environment, which explains why many Linux professionals work exclusively from the command line. Using clear descriptions and lots of examples, this book shows you how to get the most out of your Linux system using the command line interface.

Linux distributions. A Linux distribution comprises the Linux kernel, utilities, and application programs. Many distributions are available, including Debian, Red Hat, Fedora Core, SUSE, Mandriva (formerly Mandrake), KNOPPIX, and Slackware. Although the distributions differ from one another in various ways, all of them rely on the Linux kernel, utilities, and applications. This book is based on the code that is common to most distributions. As a consequence you can use it regardless of which distribution you are running.

Overlap. If you read A Practical Guide to Red Hat ® Linux, ® Second Edition: Fedora Core ™ and Red Hat Enterprise Linux, or a subsequent edition, you will notice some overlap between that book and the one you are reading now. The introduction, the appendix on regular expressions, and the chapters on the utilities (Chapter 3 of this book-- not Part V), the filesystem, and programming tools are very similar in the two books. The three chapters that cover the Bourne Again shell ( bash ) have been expanded and rewritten for this text. Chapters that appear in this book and but not in A Practical Guide to Red Hat ® Linux, ® Second Edition, include those covering the vim and emacs editors, the TC Shell ( tcsh ), the gawk and sed languages, and Part V, which describes 80 of the most useful Linux utility programs in detail.

Audience. This book is designed for a wide range of readers. It does not require programming experience, although some experience using a general-purpose computer is helpful. It is appropriate for the following readers:

  • Students taking a class in which they use Linux
  • Power users who want to explore the power of Linux from command line
  • Professionals who use Linux at work
  • System administrators who need a deeper understanding of Linux and the tools that are available to them
  • Computer science students who are studying the Linux operating system
  • Programmers who need to understand the Linux programming environment
  • Technical executives who want to get a grounding in Linux

Benefits. A Practical Guide to Linux ® Commands, Editors, and Shell Programming gives you an in-depth understanding of how to use Linux from the command line. Regardless of your background, it offers the knowledge you need to get on with your work: You will come away from this book understanding how to use Linux, and this text will remain a valuable reference for years to come.

Features of This Book

This book is organized for ease of use in different situations. For example, you can read it from cover to cover to learn command line Linux from the ground up. Alternatively, once you are comfortable using Linux, you can use this book as a reference: Look up a topic of interest in the table of contents or index and read about it. Or, refer to one of the utilities covered in Part V, "Linux Utility Programs." You can also think of this book as a catalog of Linux topics: Flip through the pages until a topic catches your eye. The book also includes many pointers to Web sites where you can get additional information: Consider the Web an extension of this book.

A Practical Guide to Linux ® Commands, Editors, and Shell Programming offers the following features:

  • Optional sections allow you to read the book at different levels, returning to more difficult material when you are ready to tackle it.
  • Caution boxes highlight procedures that can easily go wrong, giving you guidance before you run into trouble.
  • Tip boxes highlight places in the text where you can save time by doing something differently or when it may be useful or just interesting to have additional information.
  • Security boxes point out ways that you can make a system more secure.
  • The Supporting Web site will include corrections to the book, downloadable examples from the book, pointers to useful Web sites, and answers to even-numbered exercises.
  • Concepts are illustrated by practical examples found throughout the book.
  • The many useful URLs (Internet addresses) identify sites where you can obtain software and information.
  • Chapter summaries review the important points covered in each chapter.
  • Review exercises are included at the end of each chapter for readers who want to hone their skills. Answers to even-numbered exercises are available at www.sobell.com.
  • Important GNU tools, including gcc , gdb , GNU Configure and Build System, make , gzip , and many others, are described in detail.
  • Pointers throughout the book provide help in obtaining online documentation from many sources, including the local system and the Internet.


This section describes the information that each chapter covers and explains how that information can help you take advantage of the power of Linux. You may want to review the table of contents for more detail.

Chapter 1: Welcome to Linux

Presents background information on Linux. This chapter covers the history of Linux, explains how the GNU project helped Linux get started, and discusses some of Linux's important features that distinguish it from other operating systems.

Part I: The Linux Operating System

Part I introduces Linux and gets you started using it.

TIP: Experienced Users May Want to Skim Part I
If you have used a UNIX/Linux system before, you may want to skim or skip some or all of the chapters in Part I. All readers should take a look at "Conventions Used in This Book," which explains the typographic conventions that this book uses, and "Getting the Facts: Where to Find Documentation," which points you toward both local and remote sources of Linux documentation.

Chapter 2: Getting Started

Explains the typographic conventions that this book uses to make explanations clearer and easier to read. This chapter provides basic information and explains how to log in, change your password, give Linux commands using the shell, and find system documentation.

Chapter 3: Command Line Utilities

Explains the command line interface (CLI) and briefly introduces more than 30 command line utilities. Working through this chapter gives you a feel for Linux and introduces some of the tools you will use day in and day out. The utilities covered in this chapter include

  • grep , which searches through files for strings of characters;
  • unix2dos , which converts Linux text files to Windows format;
  • tar , which creates archive files that can hold many other files;
  • bzip2 and gzip , which compress files so that they take up less space on disk and allow you to transfer them over a network more quickly; and
  • diff , which displays the differences between two text files.

Chapter 4: The Linux Filesystem

Discusses the Linux hierarchical filesystem, covering files, filenames, pathnames, working with directories, access permissions, and hard and symbolic links. Understanding the filesystem allows you to organize your data so that you can find information quickly. It also enables you to share some of your files with other users while keeping other files private.

Chapter 5: The Shell

Explains how to use shell features to make your work faster and easier. All of the features covered in this chapter work with both the bash and tcsh shells. This chapter discusses

  • Using command-line options to modify the way a command works;
  • How a minor change in a command line can redirect input to a command to come from a file instead of the keyboard;
  • How to redirect output from a command to go to a file instead of the screen;
  • Using pipes to send the output of one utility directly to another utility so that you can solve problems right on the command line;
  • Running programs in the background so that you can work on one task while Linux is working on a different one; and
  • Using the shell to generate filenames to save you time spent on typing and help you when you do not remember the exact name of a file.

Part II: The Editors

Part II covers two classic, powerful Linux command line text editors. Most Linux distributions include the vim text editor, an "improved" version of the widely used vim editor, as well as the popular GNU emacs editor. Text editors enable you to create and modify text files that can hold programs, shell scripts, memos, and input to text formatting programs. Because Linux system administration involves editing text-based configuration files, skilled Linux administrators are adept at using text editors.

Chapter 6: The vim Editor

Starts with a tutorial on vim and then explains how to use many of the advanced features of vim , including special characters in search strings, the General-Purpose and Named buffers, parameters, markers, and execution of commands from vim . The chapter concludes with a summary of vim commands.

Chapter 7: The emacs Editor

Opens with a tutorial and then explains many of the features of the emacs editor as well as how to use the META , ALT , and ESCAPE keys. The chapter also covers key bindings, buffers, and incremental and complete searching for both character strings and regular expressions. In addition, it details the relationship between Point, the cursor, Mark, and Region. It also explains how to take advantage of the extensive online help facilities available from emacs . Other topics covered include cutting and pasting, using multiple windows and frames, and working with emacs modes--specifically C mode, which aids programmers in writing and debugging C code. Chapter 7 concludes with a summary of emacs commands.

Part III: The Shells

Part III goes into more detail about bash and introduces the TC Shell ( tcsh ).

Chapter 8: The Bourne Again Shell

Picks up where Chapter 5 leaves off, covering more advanced aspects of working with a shell. For examples it uses the Bourne Again Shell-- bash , the shell used almost exclusively for system shell scripts. Chapter 8 describes how to

  • Use shell startup files, shell options, and shell features to customize your shell;
  • Use job control to stop jobs and move jobs from the foreground to the background and vice versa;
  • Modify and reexecute commands using the shell history list;
  • Create aliases to customize commands;
  • Work with user-created and keyword variables in shell scripts;
  • Set up functions, which are similar to shell scripts but can execute more quickly;
  • Write and execute simple shell scripts; and
  • Redirect error messages so that they go to a file instead of the screen.

Chapter 9: The TC Shell

Describes tcsh and covers features that are common to and different between bash and tcsh . This chapter explains how to

  • Run tcsh and change your default shell to tcsh ;
  • Redirect error messages so that they go to files instead of the screen;
  • Use control structures to alter the flow of control within shell scripts;
  • Work with tcsh array and numeric variables; and
  • Use shell builtin commands.

Part IV: Programming Tools

Part IV covers programming under Linux. It discusses the C programming environment, the use of bash as a programming language, and ways to write programs using gawk and sed .

Chapter 10: Programming Tools

Introduces Linux's exceptional programming environment. This chapter

  • Explains how to invoke the GNU gcc compiler;
  • Describes how to use make to keep a set of programs up-to-date;
  • Explains how to debug a C program using gdb ;
  • Describes how to work with shared libraries;
  • Explains how to set up and use CVS to manage and track program modules in a software development project; and
  • Discusses system calls and explains how you can use them to initiate kernel operations

Once you have mastered the basics of Linux, you can use your knowledge to build more complex and specialized programs, using the shell as a programming language.

Chapter 11: Programming the Bourne Again Shell

Shows how to use bash to write advanced shell scripts. This chapter discusses

  • Control structures such as if...then...else and case;
  • Variables, including locality of variables;
  • Arithmetic and logical (Boolean) expressions; and
  • Some of the most useful shell builtin commands, including exec , trap , and getopts .

Chapter 11 poses two complete shell programming problems and then shows you how to solve them step by step. The first problem uses recursion to create a hierarchy of directories. The second problem develops a quiz program and shows you how to set up a shell script that interacts with a user and how the script processes data. (The examples in Part V also demonstrate many features of the utilities you can use in shell scripts.)

Chapter 12: The gawk Pattern Processing Language

Explains how to write programs using the powerful gawk language that filter data, write reports, and retrieve data from the Internet. The advanced programming section describes how to set up two-way communication with another program using a coprocess and how to obtain input over a network instead of from a local file.

Chapter 13: The sed Editor

Describes sed , the noninteractive stream editor that finds many applications as a filter within shell scripts. This chapter discusses how to use sed 's buffers to write simple yet powerful programs and includes many examples.

Part V: Command Reference

Linux includes hundreds of utilities. Chapters 11 and 12 as well as Part V provide extensive examples of the use of more than 80 of the most important utilities with which you can solve problems without resorting to programming in C. If you are already familiar with UNIX/Linux, this part of the book will be a valuable, easy-to-use reference. If you are not an experienced user, it will serve as a useful supplement while you are mastering the earlier sections of the book.

Although the descriptions of the utilities in Chapters 11 and 12 and Part V are presented in a format similar to that used by the Linux manual ( man ) pages, they are much easier to read and understand. These utilities were chosen because you will work with them day in and day out (for example, ls and cp ), because they are powerful tools that are especially useful in shell scripts ( sort , paste , and test ), because they help you work with your Linux system ( ps , kill , and fsck ), or because they enable you to communicate with other systems ( ssh , scp , and ftp ). Each utility description includes complete explanations of its most useful options. The "Discussion" and "Notes" sections present tips and tricks for using the utility to full advantage. The "Examples" sections demonstrate how to use these utilities in real life, alone and together with other utilities to generate reports, summarize data, and extract information. Take a look at the "Examples" sections for gawk , ftp , and sort to see how extensive these sections are.

Part VI: Appendixes

Part VI includes the appendixes, the glossary, and the index.

Appendix A Regular Expressions

Explains how to use regular expressions to take advantage of the hidden power of Linux. Many utilities, including grep , sed , vim , and gawk , accept regular expressions in place of simple strings of characters. A single regular expression can match many simple strings.

Appendix B Help

Details the steps typically used to solve the problems you may encounter with a Linux system. This appendix also includes many links to Web sites that offer documentation, useful Linux information, mailing lists, and software.

Appendix C Keeping the System Up-to-date

Describes how to use tools to download software and keep your system current. This appendix includes information on

  • yum --Downloads software from the Internet, keeping a system up-to-date and resolving dependencies as it goes.
  • Apt--An alternative to yum for keeping a system current.
  • BitTorrent--Good for distributing large amounts of data such as Linux installation CDs.


Defines more than 500 terms that pertain to the use of Linux.


Helps you find the information you want quickly.


The author's home page will contain downloadable listings of the longer programs from this book as well as pointers to many interesting and useful Linux-related sites on the World Wide Web, a list of corrections to the book, answers to even-numbered exercises, and a solicitation for corrections, comments, and suggestions.


Untitled Document Download the Index file related to this title.


Submit Errata

More Information

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information

To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.


Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.


If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information

Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.


This site is not directed to children under the age of 13.


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information

If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information

Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents

California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure

Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact

Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice

We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020