Christopher Negus served for eight years on development teams for the UNIX operating system at the AT&T labs, where UNIX was created and developed. He also worked with Novell on UNIX and UnixWare development. Chris is the author of the bestselling Fedora and Red Hat Linux Bible series, Linux Toys II, Linux Troubleshooting Bible, and Linux Bible 2008 Edition. He now works as a trainer for Red Hat Enterprise Linux, and is RHEL certified.
Francois Caen hosts and manages business application infrastructures through his company Turbosphere LLC. As an open-source advocate, he has lectured on OSS network management and Internet services, and served as president of the Tacoma Linux User Group. He is a Red Hat Certified Engineer (RHCE).
Thomas Myer is a consultant, speaker, and writer. He has become closely involved with various aspects of Mac OS X and iPhone programming. He has switched his entire web development business to Mac-based systems.
Introduction | p. xix |
Starting with Unix on Mac OS X | p. 1 |
About FreeBSD, NetBSD, and OpenBSD | p. 2 |
Finding Mac OS X Resources | p. 4 |
Focusing on Mac OS X Commands | p. 4 |
Finding Commands | p. 5 |
Command Reference Information in Unix | p. 6 |
Summary | p. 9 |
New to Mac OS X? | p. 11 |
What Is Mac OS X Unix? | p. 11 |
Finding Terminal and Utilities | p. 12 |
Directory Structure | p. 16 |
Your Home Directory | p. 18 |
Spotlight | p. 19 |
Getting and Using Fink | p. 21 |
Mounting and Unmounting Drives | p. 23 |
Learning to Love Launchd | p. 25 |
Summary | p. 25 |
Using the Shell | p. 27 |
Terminal Windows and Shell Access | p. 27 |
Using the Shell | p. 28 |
Using bash History | p. 29 |
Using Command-Line Completion | p. 30 |
Redirecting stdin and stdout | p. 31 |
Using Aliases | p. 33 |
Tailing Files | p. 34 |
Acquiring Super User Power | p. 34 |
Using Environment Variables | p. 35 |
Creating Simple Shell Scripts | p. 36 |
Editing and Running a Script | p. 36 |
Adding Content to Your Script | p. 37 |
Summary | p. 41 |
Working with Files | p. 43 |
Understanding File Types | p. 43 |
Using Regular Files | p. 43 |
Using Directories | p. 44 |
Using Symbolic and Hard Links | p. 45 |
Using Device Files | p. 46 |
Using Named Pipes and Sockets | p. 46 |
Setting File and Directory Permissions | p. 47 |
Changing Permissions with chmod | p. 48 |
Setting the umask | p. 51 |
Changing Ownership | p. 51 |
Traversing the File System | p. 51 |
Copying Files | p. 53 |
Searching for Files | p. 55 |
Generating the locate Database | p. 55 |
Finding Files with locate | p. 56 |
Locating Files with find | p. 57 |
Using Other Commands to Find Files | p. 59 |
Finding Out More About Files | p. 59 |
Listing Files | p. 59 |
Verifying Files | p. 60 |
Summary | p. 62 |
Manipulating Text | p. 63 |
Matching Text with Regular Expressions | p. 63 |
Editing Text Files | p. 64 |
Using the Pico and Nano Editors | p. 65 |
Listing, Sorting, and Changing Text | p. 67 |
Listing Text Files | p. 67 |
Paging Through Text | p. 68 |
Paginating Text Files with pr | p. 69 |
Searching for Text with grep | p. 69 |
Replacing Text with sed | p. 71 |
Translating or Removing Characters with tr | p. 73 |
Checking Differences Between Two Files with diff | p. 73 |
Using awk and cut to Process Columns | p. 75 |
Summary | p. 76 |
Advanced Scripting | p. 77 |
Shell Scripting on Mac OS X | p. 77 |
Creating a Basic Shell Script | p. 78 |
Adding Command-Line Arguments | p. 80 |
Things to Watch Out For | p. 83 |
Using the Script Command | p. 83 |
AppleScripting | p. 84 |
Working with the Open Command | p. 87 |
Summary | p. 90 |
Administering File Systems | p. 91 |
Understanding File System Basics | p. 91 |
Setting Up the Disk Initially | p. 92 |
Checking Your Disk Setup | p. 92 |
Understanding File System Types | p. 92 |
Creating and Managing File Systems | p. 94 |
Partitioning Hard Disks | p. 94 |
A Better Option: Nondestructive Partitioning | p. 95 |
Mounting and Unmounting File Systems | p. 96 |
Checking File Systems | p. 97 |
Finding Out About File System Use | p. 99 |
Summary | p. 101 |
Backups and Removable Media | p. 103 |
Backing Up Data to Compressed Archives | p. 103 |
Creating Backup Archives with tar | p. 103 |
Using Compression Tools | p. 105 |
Listing, Joining, and Adding Files to tar Archives | p. 107 |
Backing Up over a Network | p. 107 |
Backing Up tar Archives over ssh | p. 108 |
Backing Up Files with rsync | p. 109 |
Backing Up to CD or DVD | p. 110 |
Working with Time Machine and Time Capsule | p. 111 |
Summary | p. 112 |
Checking and Running Processes | p. 115 |
Listing Active Processes | p. 116 |
Viewing Active Processes with ps | p. 116 |
Watching Active Processes with top | p. 121 |
Finding and Controlling Processes | p. 123 |
Using grep and pgrep to Find Processes | p. 123 |
Using fuser to Find Processes | p. 124 |
Summary | p. 131 |
Managing the System | p. 133 |
Monitoring Resources | p. 133 |
Monitoring Memory Use | p. 134 |
Monitoring CPU Usage | p. 135 |
Monitoring Storage Devices | p. 136 |
Mastering Time | p. 137 |
Changing Time Zone | p. 137 |
Displaying and Setting Time and Date | p. 137 |
Using Network Time Protocol to Set Date/Time | p. 139 |
Checking Uptime | p. 139 |
Starting and Stopping Your System | p. 140 |
Straight to the Kernel | p. 141 |
Summary | p. 141 |
Managing Network Connections | p. 143 |
Configuring Network Interfaces | p. 143 |
Managing Network Interface Cards | p. 144 |
Managing Network Connections | p. 147 |
Starting and Stopping Network Connections | p. 148 |
Starting and Stopping Network Services | p. 149 |
Checking Name Resolution | p. 149 |
Troubleshooting Network Problems | p. 151 |
Checking Connectivity to a Host | p. 152 |
Checking Address Resolution Protocol(ARP) | p. 153 |
Tracing Routes to Hosts | p. 154 |
Displaying netstat Connections and Statistics | p. 156 |
Summary | p. 157 |
Accessing Network Resources | p. 159 |
Transferring Files | p. 159 |
Downloading Files with Wget | p. 159 |
Transferring Files with curl | p. 161 |
Transferring Files with FTP Commands | p. 162 |
Using SSH Tools to Transfer Files | p. 164 |
Sharing Remote Directories | p. 165 |
Sharing Remote Directories with NFS | p. 165 |
Sharing Remote Directories with Samba | p. 167 |
Chatting with Friends in IRC | p. 172 |
Using Text-Based E-mail Clients | p. 173 |
Summary | p. 175 |
Remote System Administration | p. 177 |
Remote Login and Tunnelling with SSH | p. 177 |
Configuring SSH | p. 179 |
Logging in Remotely with ssh | p. 179 |
Using screen: A Rich Remote Shell | p. 184 |
Reconnecting to a screen Session | p. 185 |
Naming screen Sessions | p. 186 |
Sharing screen Sessions | p. 186 |
Using a Remote Windows Desktop | p. 186 |
Using Remote Desktop and Applications | p. 187 |
Sharing Your Desktop Using VNC | p. 188 |
Summary | p. 189 |
Locking Down Security | p. 191 |
Working with Users and Groups | p. 192 |
Managing Users the GUI Way | p. 192 |
Checking on Users | p. 193 |
Configuring the Built-in Firewall | p. 195 |
Working with System Logs | p. 197 |
Summary | p. 197 |
Using vi or Vim Editors | p. 199 |
Starting and Quitting the vi Editor | p. 200 |
Moving Around in vi | p. 201 |
Changing and Deleting Text in vi | p. 202 |
Using Miscellaneous Commands | p. 204 |
Modifying Commands with Numbers | p. 204 |
Using Ex Commands | p. 205 |
Working in Visual Mode | p. 206 |
Summary | p. 206 |
Shell Special Characters and Variables | p. 207 |
Using Special Shell Characters | p. 207 |
Using Shell Variables | p. 208 |
Personal Configuration Files | p. 211 |
AppleScript Command Summary | p. 215 |
Fink Package Summary | p. 219 |
Perl Primer | p. 239 |
Introducing Perl | p. 239 |
Checking Links on a Website | p. 240 |
The Entire Script | p. 241 |
Initializing the Script and Loading Packages | p. 242 |
Targeting the URL and Extracting Links | p. 243 |
Processing the @ links Array | p. 244 |
Running the Script | p. 245 |
Extending the Script | p. 246 |
Index | p. 247 |
Table of Contents provided by Ingram. All Rights Reserved. |
The New copy of this book will include any supplemental materials advertised. Please check the title of the book to determine if it should include any access cards, study guides, lab manuals, CDs, etc.
The Used, Rental and eBook copies of this book are not guaranteed to include any supplemental materials. Typically, only the book itself is included. This is true even if the title states it includes any access cards, study guides, lab manuals, CDs, etc.