| |
| |
Introduction | |
| |
| |
Does Each Chapter Take an Hour? | |
| |
| |
What If I Take Longer Than 24 Hours? | |
| |
| |
How to Use This Book | |
| |
| |
Main Section | |
| |
| |
Tasks | |
| |
| |
Workshops | |
| |
| |
| |
What Is This Unix Stuff? | |
| |
| |
What Is Unix? | |
| |
| |
A Brief History of Unix | |
| |
| |
The C Programming Language | |
| |
| |
Unix Becomes Popular | |
| |
| |
What's All This About Multiuser Systems? | |
| |
| |
Cracking Open the Shell | |
| |
| |
Getting Help | |
| |
| |
| |
Man Pages, Unix Online Reference | |
| |
| |
| |
Other Ways to Find Help in Unix | |
| |
| |
| |
Getting onto the System and Using the Command Line | |
| |
| |
Beginning Your Session | |
| |
| |
| |
Logging In and Out of the System | |
| |
| |
| |
Changing Passwords with passwd | |
| |
| |
| |
Picking a Secure Password | |
| |
| |
Seeing What's Going On Around You | |
| |
| |
| |
Who Are You? | |
| |
| |
| |
Finding Out What Other Users Are Logged In to the System | |
| |
| |
| |
What Is Everyone Doing on the Computer? | |
| |
| |
| |
Checking the Current Date and Time | |
| |
| |
| |
Moving About the File System | |
| |
| |
What a Hierarchical File System Is All About | |
| |
| |
| |
The Unix File System Organization | |
| |
| |
The bin Directory | |
| |
| |
The dev Directory | |
| |
| |
The etc Directory | |
| |
| |
The lib Directory | |
| |
| |
The lost+found Directory | |
| |
| |
The mnt and sys Directories | |
| |
| |
The tmp Directory | |
| |
| |
The usr Directory | |
| |
| |
Other Miscellaneous Stuff at the Top Level | |
| |
| |
Directory Separator Characters | |
| |
| |
The Difference Between Relative and Absolute Filenames | |
| |
| |
| |
Hidden Files in Unix | |
| |
| |
| |
The Special Directories. and | |
| |
| |
| |
The env Command | |
| |
| |
| |
PATH and HOME | |
| |
| |
| |
Find Where You Are with pwd | |
| |
| |
| |
Moving to Another Location with cd | |
| |
| |
| |
Listing Files and Managing Disk Usage | |
| |
| |
The ls Command | |
| |
| |
| |
All About the ls Command | |
| |
| |
| |
Having ls Tell You More | |
| |
| |
| |
Combining Flags | |
| |
| |
| |
Listing Other Directories Without Changing Location | |
| |
| |
Special ls Command Flags | |
| |
| |
| |
Changing the Sort Order in ls | |
| |
| |
| |
Listing Directory Trees Recursively in ls | |
| |
| |
| |
Long Listing Format in ls | |
| |
| |
Permissions Strings | |
| |
| |
| |
Long Listing Format for Directories in ls | |
| |
| |
| |
Creating Files with the touch Command | |
| |
| |
| |
Checking Disk Space Usage with du | |
| |
| |
| |
Checking Available Disk Space with df | |
| |
| |
| |
Shrinking Big Files with the compress Program | |
| |
| |
| |
Ownership and Permissions | |
| |
| |
Working with File Permissions | |
| |
| |
| |
Understanding File Permissions Settings | |
| |
| |
| |
Directory Permissions Settings | |
| |
| |
| |
Modifying File and Directory Permissions with chmod | |
| |
| |
| |
Setting New File Permissions with chmod | |
| |
| |
| |
Calculating Numeric Permissions Strings | |
| |
| |
| |
Establishing Default File and Directory Permissions with the umask Command | |
| |
| |
| |
Identifying Owner and Group for Any File or Directory | |
| |
| |
| |
Creating, Moving, Renaming, and Deleting Files and Directories | |
| |
| |
Manipulating the Unix File System | |
| |
| |
| |
Creating New Directories Using mkdir | |
| |
| |
| |
Copying Files to New Locations Using cp | |
| |
| |
| |
Moving Files to New Locations Using mv | |
| |
| |
| |
Renaming Files with mv | |
| |
| |
| |
Removing Directories with rmdir | |
| |
| |
| |
Removing Files Using rm | |
| |
| |
| |
Minimizing the Danger of the rm Command | |
| |
| |
| |
Looking into Files | |
| |
| |
Looking Inside Files | |
| |
| |
| |
Using file to Identify File Types | |
| |
| |
| |
Exploring Unix Directories with file | |
| |
| |
| |
Peeking at the First Few Lines with head | |
| |
| |
| |
Viewing the Last Few Lines with tail | |
| |
| |
| |
Viewing the Contents of Files with cat | |
| |
| |
| |
Viewing Larger Files with more | |
| |
| |
| |
Filters and Piping | |
| |
| |
Maximizing the Command Line | |
| |
| |
| |
The Secrets of File Redirection | |
| |
| |
| |
Counting Words and Lines Using wc | |
| |
| |
| |
Removing Extraneous Lines Using uniq | |
| |
| |
| |
Sorting Information in a File Using sort | |
| |
| |
| |
Wildcards and Regular Expressions | |
| |
| |
Finding Needles in Haystacks | |
| |
| |
| |
Filename Wildcards | |
| |
| |
| |
Advanced Filename Wildcards | |
| |
| |
| |
Searching Files Using grep | |
| |
| |
| |
Creating Sophisticated Regular Expressions | |
| |
| |
| |
For Complex Expressions, Try egrep | |
| |
| |
| |
Searching for Multiple Patterns at Once with fgrep | |
| |
| |
| |
An Introduction to the vi Editor | |
| |
| |
Editing the Unix Way | |
| |
| |
| |
How to Start and Quit vi | |
| |
| |
| |
Simple Cursor Motion in vi | |
| |
| |
| |
Moving by Words and Pages | |
| |
| |
| |
Inserting Text into the File Using i, a, o, and O | |
| |
| |
| |
Deleting Text | |
| |
| |
| |
Advanced vi Tricks, Tools, and Techniques | |
| |
| |
Advanced Editing with vi | |
| |
| |
| |
Searching Within a File | |
| |
| |
| |
The Colon Commands in vi | |
| |
| |
| |
How to Start vi Correctly | |
| |
| |
| |
Search and Replace | |
| |
| |
| |
The Change and Replace Commands | |
| |
| |
| |
Accessing Unix with! | |
| |
| |
Summary of vi Commands | |
| |
| |
| |
An Overview of the emacs Editor | |
| |
| |
The Other Popular Editor: emacs | |
| |
| |
| |
Launching emacs and Inserting Text | |
| |
| |
| |
How to Move Around in a File | |
| |
| |
| |
How to Delete Characters and Words | |
| |
| |
| |
Search and Replace in emacs | |
| |
| |
| |
Using the emacs Tutorial and Help System | |
| |
| |
| |
Working with Other Files | |
| |
| |
| |
Introduction to Command Shells | |
| |
| |
The (Command) Shell Game | |
| |
| |
| |
What Shells Are Available? | |
| |
| |
| |
Identifying Your Shell | |
| |
| |
| |
How to Choose a New Shell | |
| |
| |
| |
Learning the Shell Environment | |
| |
| |
| |
Exploring bash Configuration Files | |
| |
| |
| |
Advanced Shell Interaction | |
| |
| |
Which Shell Is Which? | |
| |
| |
| |
The Shell History Mechanisms | |
| |
| |
| |
Using History to Cut Down on Typing | |
| |
| |
| |
Command Aliases | |
| |
| |
| |
Some Power Aliases | |
| |
| |
| |
Setting Custom Prompts | |
| |
| |
| |
Shell Programming Overview | |
| |
| |
Build Your Own Commands | |
| |
| |
| |
Shell Variables | |
| |
| |
| |
Shell Arithmetic | |
| |
| |
| |
Comparison Functions | |
| |
| |
| |
Conditional Expressions | |
| |
| |
| |
Looping Expressions | |
| |
| |
| |
Bash Functions | |
| |
| |
| |
Slicing and Dicing Command-Pipe Data | |
| |
| |
The awk Programming System | |
| |
| |
| |
Learning to Use awk | |
| |
| |
How to Use cut in Pipes | |
| |
| |
| |
Slicing and Dicing with cut | |
| |
| |
Inline Editing with sed and tr | |
| |
| |
| |
Inline Editing with sed and tr | |
| |
| |
| |
Job Control | |
| |
| |
Wrestling with Your Jobs | |
| |
| |
| |
Job Control in the Shell: Stopping Jobs | |
| |
| |
| |
Foreground/Background and Unix Programs | |
| |
| |
| |
Finding Out What Tasks Are Running | |
| |
| |
| |
Terminating Processes with kill | |
| |
| |
| |
Printing in the Unix Environment | |
| |
| |
Making a Printed Copy | |
| |
| |
| |
Find Local Printers with printers | |
| |
| |
| |
Printing Files with lpr or lp | |
| |
| |
| |
Formatting Print Jobs with pr and col | |
| |
| |
| |
Working with the Print Queue | |
| |
| |
| |
Searching for Information and Files | |
| |
| |
Finding What's Where | |
| |
| |
| |
The find Command and Its Weird Options | |
| |
| |
| |
Using find with xargs | |
| |
| |
| |
Archives and Backups | |
| |
| |
The tar Tape Archive Utility | |
| |
| |
| |
Learning to use tar | |
| |
| |
Shrinking Your Files with compress | |
| |
| |
| |
Shrinking Large Files on Unix | |
| |
| |
Exploring the Unix Tape Command: cpio | |
| |
| |
Action 20.3: A Quick Exploration of cpio | |
| |
| |
Personal Backup Solutions | |
| |
| |
| |
A Personal Backup Scheme | |
| |
| |
| |
Communicating with E-mail | |
| |
| |
Interacting with the World | |
| |
| |
| |
Enabling Messages Using mesg | |
| |
| |
| |
Writing to Other Users | |
| |
| |
| |
Reading Electronic Mail with mailx | |
| |
| |
| |
Sending Mail with mailx | |
| |
| |
| |
Internet E-mail Addresses | |
| |
| |
| |
The Smarter Electronic Mail Alternative, elm | |
| |
| |
| |
A Glimpse of Pine | |
| |
| |
| |
Using telnet, SSH, and ftp | |
| |
| |
Stepping Beyond Your Own System | |
| |
| |
| |
Connecting to Remote Internet Sites | |
| |
| |
| |
Telnet from Windows and Macs | |
| |
| |
| |
Secure Connections with SSH | |
| |
| |
| |
Copying Files from Other Internet Sites | |
| |
| |
| |
C Programming in Unix | |
| |
| |
Extending and Expanding Unix with Your Own Programs | |
| |
| |
| |
fget, a Smarter FTP Client | |
| |
| |
| |
Compiling the Program with cc, the C Compiler | |
| |
| |
| |
The Invaluable make Utility | |
| |
| |
| |
Additional Useful C Tools | |
| |
| |
| |
Perl Programming in Unix | |
| |
| |
Flexible and Powerful: Perl | |
| |
| |
| |
Exchange, a Demonstration Currency Translator Written in Perl | |
| |
| |
| |
Checking Code Quality with -w | |
| |
| |
| |
Online Perl Documentation and Information | |
| |
| |
| |
Other Useful Perl Commands | |
| |
| |
Appendix | |
| |
| |
| |
Working with the Apache Server | |
| |
| |
Working with a Unix Web Server | |
| |
| |
| |
Exploring Apache Configuration Files | |
| |
| |
| |
Creating a Simple CGI Program | |
| |
| |
| |
A Server-Side Include Program | |
| |
| |
| |
Understanding Apache Log Files | |
| |
| |
Index | |