did-you-know? rent-now

Amazon no longer offers textbook rentals. We do!

did-you-know? rent-now

Amazon no longer offers textbook rentals. We do!

We're the #1 textbook rental company. Let us show you why.

9780131857483

Linux For Programmers And Users

by ;
  • ISBN13:

    9780131857483

  • ISBN10:

    0131857487

  • Edition: 1st
  • Format: Paperback
  • Copyright: 2006-02-08
  • Publisher: Pearson

Note: Supplemental materials are not guaranteed with Rental or Used book purchases.

Purchase Benefits

  • Free Shipping Icon Free Shipping On Orders Over $35!
    Your order must be $35 or more to qualify for free economy shipping. Bulk sales, PO's, Marketplace items, eBooks and apparel do not qualify for this offer.
  • eCampus.com Logo Get Rewarded for Ordering Your Textbooks! Enroll Now
List Price: $146.65 Save up to $63.06
  • Rent Book $83.59
    Add to Cart Free Shipping Icon Free Shipping

    TERM
    PRICE
    DUE
    USUALLY SHIPS IN 24-48 HOURS
    *This item is part of an exclusive publisher rental program and requires an additional convenience fee. This fee will be reflected in the shopping cart.

Supplemental Materials

What is included with this book?

Summary

Offering full coverage of Linux in one source, this book documents the most commonly needed topics for new and experienced Linux users and programmers - including over 100 utilities and their common options.Provides a good foundation of understanding for the most often-used Linux utilities. Devotes a chapter to helpful installation information for those who must install their own systems. Includes hundreds of command and code examples throughout. Provides approximately 50 diagrams throughout. Features FTP-able files; code used in the book will be made available on a website hosted by the publisher.A useful reference for anyone using a Linux platform, including programmers, system administrators, and any user who must understand the operating system outside of a specific application.

Author Biography

Graham Glass is Chief Technology Officer of WebMethods. He has taught UNIX, C, assembly language, C++, Smalltalk, and other computer science topics at the University of Texas at Dallas, where he earned his M.S. in computer science. Glass co-founded ObjectSpace to deliver object-oriented training, consulting and products. He also founded The Mind Electric, which created the Glue web services platform and the Fabric shared SOA infrastructure platform. King Ables has developed UNIX/Linux product software and systems tools, delivered support and training services, and written product documentation. Now an independent consultant specializing in IT services and network security, he has worked with Unix technologies since 1979 as a user, developer, system administrator, and consultant. Glass and Ables co-authored UNIX for Programmers and Users.

Table of Contents

Preface xxv
What Is Linux?
1(16)
Computer Systems
2(1)
Hardware
3(1)
Central Processing Unit (CPU)
3(1)
Bus
3(1)
Random Access Memory (RAM)
3(1)
Read-Only Memory (ROM)
3(1)
Disk(s)
3(1)
CD-ROM Drives
3(1)
Monitor(s)
3(1)
Graphics Card(s)
3(1)
Keyboard
3(1)
Mouse
4(1)
Printer(s)
4(1)
Tape(s)
4(1)
Modem
4(1)
Network Interface
4(1)
Other Peripherals
4(1)
Operating System
4(1)
Software
5(1)
Sharing Resources
5(1)
Communication
6(1)
Utilities
7(1)
Programmer Support
7(1)
Standards
8(1)
Linux Lineage
8(3)
UNIX
8(2)
Open Source Software and the Free Software Foundation
10(1)
Linus
11(1)
Linux Packaging
11(1)
The Linux and UNIX Philosophy
12(1)
Linux Features
13(1)
The Rest of This Book
14(3)
Installing Your Linux System
17(24)
Introduction
18(1)
Make Sure Your Hardware Will Support Linux
18(2)
CPU Type
18(1)
Bus Architecture
19(1)
Memory
19(1)
Disk
19(1)
Display, Keyboard, and Mouse
20(1)
Choose Your Linux Distribution
20(3)
Debian
21(1)
Fedora
21(1)
Mandrake
22(1)
Slackware
22(1)
SuSE
23(1)
TurboLinux
23(1)
Consider Optional Software Packages
23(5)
X Window System
23(1)
Desktop Environments
24(2)
Networking
26(1)
Office Tools
27(1)
Programming Languages and Tools
27(1)
Design Your System
28(5)
How Do You Want To Run Linux?
28(1)
Disk Partitioning
28(2)
Linux File Systems
30(2)
Boot Loaders
32(1)
Boot Floppy
32(1)
Get Linux
33(2)
CD-ROM
33(1)
Download
34(1)
Install Linux
35(6)
Get the Documentation for Your Distribution
35(1)
Boot
35(1)
Partition Disks
35(2)
Resize a Windows Partition
37(1)
System Setup
37(1)
The Boot Loader
38(3)
GNU Utilities for Nonprogrammers
41(66)
Obtaining an Account
42(1)
Logging In
42(1)
Shells
43(1)
Running a GNU Utility
44(1)
Input, Output, and Error Channels
45(1)
Obtaining online Help: man
45(2)
Special Characters
47(2)
Terminating a Process: Control-C
48(1)
End-of-input: Control-D
48(1)
Setting Your Password: passwd
49(1)
Logging Out
50(1)
Poetry in Motion: Exploring the File System
50(2)
Printing Your Shell's Current Working Directory: pwd
52(1)
Absolute and Relative Pathnames
52(2)
Creating a File
54(1)
Listing the Contents of a Directory: Is
55(1)
Listing the Contents of a File: cat/more/head/tail
56(2)
Renaming a File: mv
58(1)
Creating a Directory: mkdir
58(1)
Moving to a Directory: cd
59(1)
Copying a File: cp
60(1)
Editing a File: vim
61(1)
Deleting a Directory: rmdir
62(1)
Deleting a File: rm
62(2)
Printing a File: lp/lpstat/cancel
64(1)
Printing a File: lpr/lpq/lprm
65(2)
Counting Words in a File: wc
67(1)
File Attributes
68(4)
File Storage
68(1)
Filenames
68(1)
File Modification Time
69(1)
File Owner
69(1)
File Group
69(1)
File Types
69(1)
File Permissions
70(2)
Hard Link Count
72(1)
Groups
72(1)
Listing Your Groups: groups
73(1)
Changing a File's Group: chgrp
73(1)
Changing a File's Permissions: chmod
74(2)
Changing a File's Owner: chown
76(1)
Changing Groups: newgrp
76(1)
Poetry in Motion: Epilogue
77(1)
Determining Your Terminal's Type: tset
77(3)
Changing a Terminal's Characteristics: stty
80(2)
Editing a File: vim
82(11)
Starting vim
82(1)
Text Entry Mode
83(1)
Command Mode
84(1)
Memory Buffer and Temporary Files
85(1)
Common Editing Features
85(1)
Cursor Movement
86(1)
Deleting Text
87(1)
Replacing Text
87(1)
Pasting Text
88(1)
Searching
89(1)
Search/Replace
89(1)
Saving/Loading Files
90(1)
Miscellaneous
91(1)
Customizing vim
92(1)
Keeping Your Customizations
92(1)
Editing a File: emacs
93(6)
Starting emacs
93(1)
emacs Commands
94(1)
Getting Out of Trouble
94(1)
Getting Help
95(1)
Leaving emacs
95(1)
emacs Modes
95(1)
Entering Text
95(1)
Common Editing Features
95(1)
Moving the Cursor
96(1)
Deleting, Pasting, and Undoing
96(1)
Searching
97(1)
Search/Replace
97(1)
Saving/Loading files
98(1)
Miscellaneous
98(1)
Electronic Mail: mail
99(8)
Sending Mail
101(1)
Reading Mail
102(1)
Contacting the System Administrator
103(4)
GNU Utilities for Power Users
107(60)
Introduction
108(1)
Filtering Files: grep, egrep, fgrep, and uniq
109(4)
Filtering Patterns: egrep/fgrep/grep
109(3)
Removing Duplicate Lines: uniq
112(1)
Sorting Files: sort
113(3)
Comparing Files: cmp and diff
116(3)
Testing for Sameness: cmp
116(1)
File Differences: diff
117(2)
Finding Files: find
119(2)
Archiving Files: cpio, tar, and dump/restore
121(7)
Copying Files: cpio
121(3)
Tape Archiving: tar
124(2)
Incremental Backups: Dump and Restore
126(2)
Scheduling Commands: crontab and at
128(4)
Periodic Execution: Crontab
128(2)
One-time Execution: at
130(2)
Programmable Text Processing: gawk
132(5)
gawk Programs
132(1)
Accessing Individual Fields
133(1)
BEGIN and END
133(1)
Operators
134(1)
Variables
134(1)
Control Structures
135(1)
Extended Regular Expressions
135(1)
Condition Ranges
136(1)
Field Separators
136(1)
Built-In Functions
136(1)
Hard and Soft Links: In
137(2)
Identifying Shells: whoami
139(1)
Substituting a User: su
139(1)
Transforming Files
140(8)
Compressing Files: gzip and gunzip
141(1)
Stream Editing: sed
141(5)
Translating Characters: tr
146(1)
Converting Underline Sequences: ul
147(1)
Looking at Raw File Contents: od
148(1)
Mounting File Systems: mount and umount
149(1)
Identifying Terminals: tty
150(1)
Timing Execution: time
151(1)
Rolling Your Own Programs: Perl
152(15)
Getting Perl
152(1)
Running Perl
152(1)
Printing Text
153(1)
Variables, Strings, and Integers
153(1)
Arrays
154(1)
Mathematical and Logical Operators
155(2)
String Operators
157(1)
Comparison Operators
157(1)
If, while, for and foreach Loop Constructs
158(1)
File I/O
159(1)
Functions
159(1)
Library Functions
160(1)
Command-line Arguments
161(1)
A Real-World E-xample
162(5)
The Linux Shells
167(36)
Introduction
168(1)
Selecting a Shell
169(1)
Shell Operations
170(1)
Executable Files Versus Built-In Commands
170(1)
Displaying Information: echo
171(1)
Changing Directories: cd
171(1)
Metacharacters
171(1)
Redirection
172(2)
Output Redirection
173(1)
Input Redirection
174(1)
Filename Substitution (Wildcards)
174(4)
Pipes
175(3)
Command Substitution
178(1)
Sequences
178(1)
Conditional Sequences
179(1)
Grouping Commands
179(1)
Background Processing
180(1)
Redirecting Background Processes
181(1)
Shell Programs (Scripts)
182(1)
Subshells or Child Shells
183(1)
Variables
184(3)
Quoting
187(1)
Here Documents
187(1)
Job Control
188(6)
Process Status: ps
188(4)
Signaling Processes: kill
192(1)
Waiting For Child Processes: wait
193(1)
Finding a Command: SPATH
194(1)
Superseding Standard Utilities
195(1)
Termination and Exit Codes
196(1)
Common Core Built-ins
197(6)
eval
197(1)
exec
197(1)
shift
198(1)
umask
199(4)
The Bourne Again Shell
203(42)
Introduction
204(1)
Startup
204(1)
Variables
205(12)
Creating/Assigning a Simple Variable
205(1)
Accessing Simple Variables
206(3)
Creating/Assigning a List Variable
209(1)
Accessing List Variables
209(1)
Building Lists
210(1)
Destroying lists
211(1)
Reading a Variable from Standard Input
211(1)
Exporting Variables
212(1)
Read-only Variables
213(1)
Predefined Variables
214(3)
Command Shortcuts
217(3)
Aliases
217(1)
Command History
217(3)
Auto-Completion
220(1)
Tilde Substitution
220(1)
Redirection
221(1)
Command Substitution
222(1)
Arithmetic
222(1)
Conditional Expressions
223(3)
Arithmetic Tests
223(1)
String Comparisons
224(1)
File-Oriented Expressions
224(2)
Control Structures
226(6)
case .. in .. esac
226(2)
if .. then .. elif .. then .. else .. fi
228(1)
for .. do .. done
229(1)
while/until .. do .. done
229(2)
trap
231(1)
Functions
232(4)
Using Parameters
233(1)
Returning from a Function
233(1)
Access to Functions
234(1)
Recursion
235(1)
Sharing Functions
236(1)
Menus: select
236(1)
Directory Access and the Directory Stack
237(2)
Job Control
239(3)
Specifying a Job
240(1)
bg
240(1)
fg
241(1)
kill
241(1)
Command-Line Options
242(3)
The Korn Shell
245(50)
Introduction
246(1)
Startup
246(2)
Variables
248(7)
Creating/Assigning A Variable
248(1)
Accessing A Variable
248(2)
Reading a Variable from Standard Input
250(1)
Exporting Variables
251(1)
Read-Only Variables
252(1)
Predefined Local Variables
253(1)
Predefined Environment Variables
254(1)
Aliases
255(4)
Aliasing Built-in Commands
256(1)
Removing an Alias
256(1)
Predefined Aliases
256(1)
Some Useful Aliases
257(1)
Tracked Aliases
258(1)
Sharing Aliases
258(1)
History
259(3)
Numbered Commands
259(1)
Storage of Commands
259(1)
Command Re-execution
260(1)
Editing Commands
260(2)
Editing Commands
262(3)
The Built-in vi Editor
262(2)
The Built-in emacs/gmacs Editor
264(1)
Arithmetic
265(2)
Preventing Metacharacter Interpretation
266(1)
Testing Values
266(1)
Tilde Substitution
267(1)
Menus: select
267(2)
Functions
269(4)
Using Parameters
270(1)
Returning from a Function
270(1)
Context
271(1)
Local Variables
271(1)
Recursion
271(1)
Sharing Functions
272(1)
Job Control
273(3)
Jobs
273(1)
Specifying a Job
274(1)
bg
274(1)
fg
275(1)
kill
275(1)
Enhancements
276(14)
Redirection
276(1)
Pipes
277(1)
Command Substitution
277(1)
Variables
277(7)
Built-Ins
284(6)
Sample Project: junk
290(3)
Command-Line Options
293(2)
The C Shell
295(40)
Introduction
296(1)
Startup
296(2)
Variables
298(5)
Creating/Assigning Simple Variables
298(1)
Accessing a Simple Variable
298(1)
Creating/Assigning List Variables
299(1)
Accessing a List Variable
300(1)
Building Lists
300(1)
Predefined Local Variables
301(1)
Creating/Assigning Environment Variables
302(1)
Predefined Environment Variables
303(1)
Expressions
303(4)
String Expressions
303(1)
Arithmetic Expressions
304(2)
File-oriented Expressions
306(1)
Filename Completion
307(1)
Command Editing
307(1)
Aliases
307(3)
Removing an Alias
309(1)
Useful Aliases
309(1)
Sharing Aliases
309(1)
Parameterized Aliases
310(1)
History
310(4)
Numbered Commands
310(1)
Storage of Commands
310(1)
Reading History
310(1)
Command Re-execution
311(1)
Accessing Pieces of History
312(1)
Accessing Portions of Filenames
313(1)
History Substitution
313(1)
Control Structures
314(7)
foreach .. end
314(1)
goto
315(1)
if .. then .. else .. endif
316(1)
onintr
317(1)
repeat
318(1)
switch .. case .. endsw
318(2)
while .. end
320(1)
Sample Project: junk
321(2)
Enhancements
323(5)
Metacharacters: { }
324(1)
Filename Substitution
324(1)
Redirection
325(1)
Piping
325(1)
Job Control
326(2)
Terminating a Login Shell
328(1)
Built-ins
328(2)
chdir
328(1)
glob
329(1)
source
329(1)
The Directory Stack
330(2)
The Hash Table
331(1)
Command-Line Options
332(3)
Networking and the Internet
335(40)
Introduction
336(1)
Building a Network
336(2)
Ethernets
337(1)
Bridges
338(1)
Routers
338(1)
Gateways
338(1)
Internetworking
338(6)
Packet Switching
340(1)
IP Addresses
340(1)
Naming
341(1)
Routing
342(1)
Security
342(1)
Ports and Common Services
343(1)
Network Programming
344(1)
Identifying Network Users
344(3)
Listing Users: users
344(1)
More User Listings: who and w
345(1)
Your Own Host Name: hostname
345(1)
Personal Data: finger
346(1)
Communicating with Network Users
347(3)
Shielding Yourself from Communication: mesg
347(1)
Sending a Line at a Time: write
348(1)
Interactive Conversations: talk
349(1)
Messages to Everyone: wall
349(1)
Distributing Data
350(4)
Copying Files Between Two Linux or UNIX Hosts: rcp and scp
351(1)
Copying Files Between Non-Linux/UNIX Hosts: ftp and sftp
351(3)
Distributed Processing
354(6)
Remote Logins: rlogin and slogin
355(1)
Executing Remote Commands: rsh and ssh
356(1)
Remote Connections: telnet
357(3)
Evolution of the Internet
360(11)
In The Beginning---the 1960s
360(1)
Standardizing the Internet---the 1970s
361(2)
Re-Architecting and Renaming the Internet---the 1980s
363(3)
The Web---the 1990s
366(5)
Using Today's Internet
371(4)
URLs
371(1)
Web Searches
372(1)
Finding Users and Domains
373(2)
The Linux Desktop
375(24)
Introduction
376(1)
Graphical User Interfaces
376(1)
MIT
376(1)
X Servers
377(2)
Screen Geometry
377(1)
Security and Authorization
378(1)
Desktop Environments
379(2)
CDE
380(1)
GNOME
380(1)
KDE
381(1)
Window Managers
381(4)
Focus
381(1)
Program Startup
382(1)
Opened and Closed Windows
383(1)
Choices
384(1)
Widgets
385(2)
Menus
385(1)
Pushbuttons
385(1)
Check Boxes/Radio Buttons
385(2)
Scroll Bars
387(1)
Desktop Operation
387(2)
Bringing up the Root Menu
388(1)
Opening and Closing a Window
388(1)
Minimizing a Window
389(1)
Maximizing a Window
389(1)
Moving a Window
389(1)
Resizing a Window
389(1)
Raising or Lowering a Window
389(1)
Bringing up a Window Menu
389(1)
Client Applications
389(2)
xclock
390(1)
xterm
391(1)
Standard X Client Arguments
391(1)
geometry
391(1)
Foreground and Background
391(1)
title
392(1)
iconic
392(1)
Advanced Topics
392(7)
Copy-and-Paste
392(1)
Networking Capabilities
393(1)
Application Resources
394(5)
C Programming Tools
399(32)
The C Language
400(1)
C Compilers
400(1)
Single-Module Programs
401(3)
Compiling a C Program
402(1)
A Listing of the Corrected Reverse Program
402(1)
Running a C Program
403(1)
Overriding the Default Executable Name
404(1)
Multimodule Programs
404(4)
Reusable Functions
404(1)
Preparing a Reusable Function
404(2)
Separately Compiling and Linking Modules
406(1)
Reusing the Reverse Function
406(2)
Archiving Modules: ar
408(3)
Creating or Adding a File
408(1)
Appending a File
409(1)
Obtaining a Table of Contents
409(1)
Deleting a File
409(1)
Extracting a File
409(1)
Maintaining an Archive from the Command Line
410(1)
Indexing Archives
410(1)
Shared Libraries
411(1)
Managing Dependencies: make
411(7)
Make Files
412(1)
The Order of Make Rules
413(1)
Running Make
414(1)
Make Rules
415(1)
Forcing Compilation
415(1)
Macros
416(1)
Maintaining an Archive Using Make
417(1)
Other Make Capabilities
418(1)
The GNU Profiler: gprof
418(1)
Debugging a Program: gdb
419(10)
Preparing a Program for Debugging
421(1)
Entering the Debugger
421(1)
Running a Program
422(1)
Listing a Program
422(2)
Setting a Breakpoint
424(2)
Stepping Through the Code
426(1)
Examining Variable Values
427(1)
The Epiphany
428(1)
When You're Done: strip
429(2)
Systems Programming
431(102)
Introduction
432(2)
Error Handling: perror ()
434(2)
Regular File Management
436(37)
A File Management Primer
436(2)
First Example: reverse
438(1)
How reverse Works
439(1)
reverse.c: Listing
440(5)
Opening a File: open ()
445(2)
Reading From a File: read ()
447(1)
Writing to a File: write ()
448(1)
Moving in a File: Iseek ()
449(1)
Closing a File: close ()
450(1)
Deleting a File: unlink ()
451(1)
Second Example: monitor
451(2)
How monitor Works
453(1)
Monitor.c: Listing
453(8)
Obtaining File Information: stat ()
461(2)
Reading Directory Information: opendir (), readdir (), and closedir ()
463(1)
Miscellaneous File Management System Calls
464(1)
Changing a File's Owner and/or Group: chown ()
464(1)
Changing a File's Permissions: chmod ()
465(1)
Duplicating a File Descriptor: dup ()
466(1)
File Descriptor Operations: fcntl ()
467(2)
Controlling Devices: ioctl ()
469(1)
Creating Hard Links: link ()
469(1)
Creating Special Files: mknod (), mkdir (), and mkfifo ()
470(1)
Flushing the File System Buffer: sync ()
471(1)
Truncating a File: truncate ()
472(1)
Process Management
473(13)
Creating a New Process: fork ()
474(2)
Orphan Processes
476(2)
Terminating a Process: exit ()
478(1)
Zombie Processes
478(1)
Waiting for a Child: wait ()
479(2)
Differentiating a Process: exec
481(1)
Changing Directories: chdir ()
482(1)
Changing Priorities: nice ()
483(1)
Accessing User and Group IDs
484(1)
Sample Program: Background Processing
485(1)
Redirection
485(1)
Signals
486(14)
Signal Types
487(1)
Defined Signals
487(1)
POSIX Signals
488(1)
Terminal Signals
489(1)
Requesting an Alarm Signal: alarm ()
489(1)
Handling Signals: signal ()
490(1)
Protecting Critical Code and Chaining Interrupt Handlers
491(1)
Sending Signals: kill ()
492(1)
Death of Children
493(1)
Suspending and Resuming Processes
494(2)
Process Groups and Control Terminals
496(4)
Interprocess Communication
500(33)
Pipes
501(7)
Sockets
508(25)
Linux Internals
533(42)
Introduction
534(1)
Kernel Basics
534(7)
Kernel Subsystems
534(1)
Processes and Files
535(1)
Talking to the Kernel
536(1)
System Calls
536(1)
User Mode and Kernel Mode
536(2)
Synchronous Versus Asynchronous Processing
538(2)
Interrupting Interrupts
540(1)
The File System
541(11)
Disk Architecture
541(3)
Virtual File System
544(1)
Inodes
545(2)
File System Layout
547(1)
Bad Blocks
548(1)
Directories
548(1)
Translating Pathnames into Inode Numbers
549(2)
Mounting File Systems
551(1)
Process Management
552(4)
Executable Files
552(1)
The First Processes
552(1)
Kernel Processes and User Processes
552(1)
The Process Hierarchy
552(1)
Process States
553(1)
Process Kernel Data
553(2)
The Task List
555(1)
The Scheduler
555(1)
Virtual Memory Management
556(4)
The Page Table
556(1)
Paging
557(1)
Memory-Mapped Files
558(1)
Swapping
558(1)
Allocation and Deallocation
559(1)
Loading an Executable: execl ()/execv ()
560(1)
Duplicating a Process: fork ()
560(1)
Input and Output
560(9)
I/O Objects
561(1)
I/O System Calls
561(1)
I/O Buffering
561(1)
Regular File I/O
562(3)
Directory File I/O
565(1)
Mounting File Systems
565(1)
Translation of Filenames
566(1)
Special File I/O
567(2)
Interprocess Communication
569(6)
Signals
569(3)
Pipes
572(1)
Sockets
573(2)
System Administration
575(20)
Introduction
576(1)
Becoming the Super-User
576(2)
Using su
577(1)
Using sudo
577(1)
Starting Linux
578(2)
The Linux Kernel
578(1)
Run Levels
578(1)
init
579(1)
Boot Scripts
579(1)
Stopping Linux
580(1)
Maintaining the File System
580(4)
File System Integrity
580(1)
Disk Space
581(2)
Creating New File Systems
583(1)
Backing up File Systems
584(1)
Maintaining User Accounts
584(3)
The Password File
585(1)
The Group File
586(1)
Installing New Software
587(1)
Peripheral Devices
587(1)
The Network Interface
588(1)
Automating Tasks
589(1)
Tunable Kernel Parameters
590(1)
The /proc File System
590(1)
The sysctl Utility
591(1)
Security Issues
591(4)
Appendix 595(14)
Bibliography 609(2)
Index 611

Supplemental Materials

What is included with this book?

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.

Rewards Program