1. Trang chủ
  2. » Công Nghệ Thông Tin

Prentice hall linux for programmers and users feb 2006 ISBN 0131857487

1,3K 274 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 1.268
Dung lượng 5,22 MB

Nội dung

Table of • Contents • Index Linux for Programmers and Users By Graham Glass, King Ables Publisher : Prentice Hall Pub Date : February 15, 2006 Print ISBN-10 : 0-13-185748-7 Print ISBN-13 : 978-0-13-185748-3 eText ISBN-10 : 0-13-186102-6 eText ISBN-13 : 978-0-13-186102-2 Pages : 700 Offering full coverage of Linux in one source, this book documents the most commonly needed topics for new and experienced Linux users and programmers Linux for Programmers and Users By Graham Glass, King Ables Publisher : Prentice Hall Pub Date : February 15, 2006 Print ISBN-10 : 0-13-185748-7 Print ISBN-13 : 978-0-13-185748-3 Table of eText ISBN-10 : 0-13-186102-6 • Contents eText ISBN-13 : 978-0-13-186102-2 • Index Pages : 700 Copyright Trademark Information Preface About the Authors About the Book Organization of the Book Layout of the Chapters A Guide for Teachers Nomenclature References to Other Books Source Code Availability Online Acknowledgments Chapter 1 What Is Linux? Motivation Prerequisites Objectives Presentation Section 1.1 Computer Systems Section 1.2 Hardware Section 1.3 Operating System Section 1.4 Software Section 1.5 Sharing Resources ii xxv xxv xxvi xxvii xxvii xxviii xxix xxix xxx xxx 1 1 5 Section 1.6 Communication Section 1.7 Utilities Section 1.8 Programmer Support Section 1.9 Standards Section 1.10 Linux Lineage Section 1.11 Linux Packaging Section 1.12 The Linux and UNIX Philosophy Section 1.13 Linux Features Section 1.14 The Rest of This Book Chapter Review Chapter 2 Installing Your Linux System Motivation Prerequisites Objectives Presentation Section 2.1 Introduction Section 2.2 Make Sure Your Hardware Will Support Linux Section 2.3 Choose Your Linux Distribution Section 2.4 Consider Optional Software Packages Section 2.5 Design Your System Section 2.6 Get Linux Section 2.7 Install Linux Chapter Review Chapter 3 GNU Utilities for Nonprogrammers Motivation Prerequisites Objectives Presentation Utilities Shell command Section 3.1 Obtaining an Account Section 3.2 Logging In Section 3.3 Shells Section 3.4 Running a GNU Utility Section 3.5 Input, Output, and Error Channels Section 3.6 Obtaining Online Help: man Section 3.7 Special Characters Section 3.8 Setting Your Password: passwd Section 3.9 Logging Out 7 8 11 12 13 14 15 17 17 17 17 17 18 18 20 23 28 33 35 39 41 41 41 41 41 42 42 42 42 43 44 45 45 47 49 50 Section 3.10 Poetry in Motion: Exploring the File System Section 3.11 Printing Your Shell's Current Working Directory: pwd Section 3.12 Absolute and Relative Pathnames Section 3.13 Creating a File Section 3.14 Listing the Contents of a Directory: ls Section 3.15 Listing the Contents of a File: cat/more/head/tail Section 3.16 Renaming a File: mv Section 3.17 Creating a Directory: mkdir Section 3.18 Moving to a Directory: cd Section 3.19 Copying a File: cp Section 3.20 Editing a File: vim Section 3.21 Deleting a Directory: rmdir Section 3.22 Deleting a File: rm Section 3.23 Printing a File: lp/lpstat/cancel Section 3.24 Printing a File: lpr/lpq/lprm Section 3.25 Counting Words in a File: wc Section 3.26 File Attributes Section 3.27 Groups Section 3.28 Listing Your Groups: groups Section 3.29 Changing a File's Group: chgrp Section 3.30 Changing a File's Permissions: chmod Section 3.31 Changing a File's Owner: chown Section 3.32 Changing Groups: newgrp Section 3.33 Poetry in Motion: Epilogue Section 3.34 Determining Your Terminal's Type: tset Section 3.35 Changing a Terminal's Characteristics: stty Section 3.36 Editing a File: vim Section 3.37 Editing a File: emacs Section 3.38 Electronic Mail: mail Chapter Review Chapter 4 GNU Utilities for Power Users Motivation Prerequisites Objectives Presentation Utilities Section 4.1 Introduction Section 4.2 Filtering Files: grep, egrep, fgrep, and uniq Section 4.3 Sorting Files: sort 50 52 52 54 55 56 58 58 59 60 61 62 62 64 65 67 68 72 73 73 74 76 76 77 77 80 82 93 99 103 107 107 107 107 107 107 108 109 113 Section 4.4 Comparing Files: cmp and diff Section 4.5 Finding Files: find Section 4.6 Archiving Files: cpio, tar, and dump/restore Section 4.7 Scheduling Commands: crontab and at Section 4.8 Programmable Text Processing: gawk Section 4.9 Hard and Soft Links: ln Section 4.10 Identifying Shells: whoami Section 4.11 Substituting a User: su Section 4.12 Transforming Files Section 4.13 Looking at Raw File Contents: od Section 4.14 Mounting File Systems: mount and umount Section 4.15 Identifying Terminals: tty Section 4.16 Timing Execution: time Section 4.17 Rolling Your Own Programs: Perl Chapter Review Chapter 5 The Linux Shells Motivation Prerequisites Objectives Presentation Utilities Shell Commands Section 5.1 Introduction Section 5.2 Selecting a Shell Section 5.3 Shell Operations Section 5.4 Executable Files Versus Built-in Commands Section 5.5 Metacharacters Section 5.6 Redirection Section 5.7 Filename Substitution (Wildcards) Section 5.8 Command Substitution Section 5.9 Sequences Section 5.10 Grouping Commands Section 5.11 Background Processing Section 5.12 Redirecting Background Processes Section 5.13 Shell Programs (Scripts) Section 5.14 Subshells or Child Shells Section 5.15 Variables Section 5.16 Quoting Section 5.17 Here Documents 116 119 121 128 132 137 139 139 140 148 149 150 151 152 164 167 167 167 167 168 168 168 168 169 170 170 171 172 174 178 178 179 180 181 182 183 184 187 187 Section 5.18 Job Control Section 5.19 Finding a Command: $PATH Section 5.20 Superseding Standard Utilities Section 5.21 Termination and Exit Codes Section 5.22 Common Core Built-Ins Chapter Review Chapter 6 The Bourne Again Shell Motivation Prerequisites Objectives Presentation Shell Commands Section 6.1 Introduction Section 6.2 Startup Section 6.3 Variables Section 6.4 Command Shortcuts Section 6.5 Tilde Substitution Section 6.6 Redirection Section 6.7 Command Substitution Section 6.8 Arithmetic Section 6.9 Conditional Expressions Section 6.10 Control Structures Section 6.11 Functions Section 6.12 Menus: select Section 6.13 Directory Access and the Directory Stack Section 6.14 Job Control Section 6.15 Command-Line Options Chapter Review Chapter 7 The Korn Shell Motivation Prerequisites Objectives Presentation Shell Commands Section 7.1 Introduction Section 7.2 Startup Section 7.3 Variables Section 7.4 Aliases Section 7.5 History 188 194 195 196 197 200 203 203 203 203 203 204 204 204 205 217 220 221 222 222 223 226 232 236 237 239 242 242 245 245 245 245 245 245 246 246 248 255 259 Section 7.6 Editing Commands Section 7.7 Arithmetic Section 7.8 Tilde Substitution Section 7.9 Menus: select Section 7.10 Functions Section 7.11 Job Control Section 7.12 Enhancements Section 7.13 Sample Project: junk Section 7.14 Command-Line Options Chapter Review Chapter 8 The C Shell Motivation Prerequisites Objectives Presentation Shell Commands Section 8.1 Introduction Section 8.2 Startup Section 8.3 Variables Section 8.4 Expressions Section 8.5 Filename Completion Section 8.6 Command Editing Section 8.7 Aliases Section 8.8 History Section 8.9 Control Structures Section 8.10 Sample Project: junk Section 8.11 Enhancements Section 8.12 Built-Ins Section 8.13 The Directory Stack Section 8.14 Command-Line Options Chapter Review Chapter 9 Networking and the Internet Motivation Prerequisites Objectives Presentation Commands Section 9.1 Introduction Section 9.2 Building a Network 262 265 267 267 269 273 276 290 293 293 295 295 295 295 295 296 296 296 298 303 307 307 307 310 314 321 323 328 330 332 333 335 335 335 335 335 336 336 336 Section 9.3 Internetworking Section 9.4 Identifying Network Users Section 9.5 Communicating with Network Users Section 9.6 Distributing Data Section 9.7 Distributed Processing Section 9.8 Evolution of the Internet Section 9.9 Using Today's Internet Chapter Review Chapter 10 The Linux Desktop Motivation Prerequisites Objectives Presentation Utilities Section 10.1 Introduction Section 10.2 X Servers Section 10.3 Desktop Environments Section 10.4 Window Managers Section 10.5 Widgets Section 10.6 Desktop Operation Section 10.7 Client Applications Section 10.8 Standard X Client Arguments Section 10.9 Advanced Topics Chapter Review Chapter 11 C Programming Tools Motivation Prerequisites Objectives Presentation Utilities Section 11.1 The C Language Section 11.2 C Compilers Section 11.3 Single-Module Programs Section 11.4 Multimodule Programs Section 11.5 Archiving Modules: ar Section 11.6 Managing Dependencies: make Section 11.7 The GNU Profiler: gprof Section 11.8 Debugging a Program: gdb Section 11.9 When You're Done: strip 338 344 347 350 354 360 371 373 375 375 375 375 375 376 376 377 379 381 385 387 389 391 392 397 399 399 399 399 399 400 400 400 401 404 408 411 418 419 429 Chapter Review Chapter 12 Systems Programming Motivation Prerequisites Objectives Presentation Utilities System calls and library functions Section 12.1 Introduction Section 12.2 Error Handling: perror () Section 12.3 Regular File Management Section 12.4 Process Management Section 12.5 Signals Section 12.6 Interprocess Communication Chapter Review Chapter 13 Linux Internals Motivation Prerequisites Objectives Presentation Section 13.1 Introduction Section 13.2 Kernel Basics Section 13.3 The File System Section 13.4 Process Management Section 13.5 Virtual Memory Management Section 13.6 Input and Output Section 13.7 Interprocess Communication Chapter Review Chapter 14 System Administration Motivation Prerequisites Objectives Presentation Utilities Section 14.1 Introduction Section 14.2 Becoming the Super-User Section 14.3 Starting Linux Section 14.4 Stopping Linux Section 14.5 Maintaining the File System 429 431 431 431 431 431 432 432 432 434 436 473 486 500 528 533 533 533 533 534 534 534 541 552 556 560 569 573 575 575 575 575 575 576 576 576 578 580 580 Section 14.6 Maintaining User Accounts Section 14.7 Installing New Software Section 14.8 Peripheral Devices Section 14.9 The Network Interface Section 14.10 Automating Tasks Section 14.11 Tunable Kernel Parameters Section 14.12 Security Issues Chapter Review Appendix A Section A.1 Regular Expressions Section A.2 Extended Regular Expressions Section A.3 Modified Backus-Naur Notation Section A.4 Utilities and Shell Built-In Commands Section A.5 System Calls and Library Functions Bibliography Index 584 587 587 588 589 590 591 592 595 595 597 597 598 605 609 ntohl () ntohs () Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] od olwm onintr open () 2nd Open Software Foundation (OSF) 2nd Open Source software opendir opendir () OpenOffice OpenSSH OpenSSL OpenWindows Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] page cache page fault page table partition table passwd 2nd pause () Perl perror () PF_INET PF_LOCAL PID 2nd 3rd pipe () 2nd pipes named unnamed popd 2nd POSIX 2nd 3rd PPID 2nd print process 2nd 3rd 4th 5th 6th 7th 8th 9th background child 2nd creating 2nd group 2nd orphan parent 2nd 3rd 4th priority runable 2nd scheduler state status suspending 2nd terminating 2nd 3rd 4th waiting for zombie 2nd 3rd 4th 5th prof ps pushd 2nd pwd Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] raw mode rcp read 2nd 3rd read () readdir () readonly 2nd Red Hat regular expression regular expressions 2nd rehash repeat restore Ritchie, Dennis 2nd rlogin rm rmdir route RPM rpm rsh run level Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] sched scheduler scp security sed select 2nd set 2nd 3rd 4th setenv setpgid () setpgrp () sftp shadow password file shell aliases 2nd 3rd 4th 5th removing 2nd 3rd arithmetic 2nd 3rd built-in commands 2nd 3rd 4th 5th 6th command editing 2nd 3rd 4th command substitution 2nd 3rd 4th control structures 2nd directory stack 2nd 3rd expressions 2nd filename completion 2nd 3rd filename substitution functions 2nd 3rd history 2nd 3rd 4th job control 2nd 3rd 4th metacharacters 2nd 3rd parameters 2nd 3rd pipes 2nd 3rd 4th 5th redirection 2nd 3rd 4th 5th 6th 7th 8th script variables 2nd 3rd 4th 5th 6th 7th 8th 9th 10th 11th 12th 13th wildcards shift shutdown signal 2nd 3rd 4th 5th 6th 7th 8th 9th 10th 11th 12th death of a child process 2nd defined in signal.h handler 2nd 3rd list of queued sending 2nd suspending and resuming a process signal () 2nd Slackware 2nd 3rd 4th sleep slogin socket () sockets Solaris sort source 2nd ssh Stallman, Richard 2nd startx stat () stderr 2nd 3rd stdin 2nd 3rd stdout 2nd 3rd 4th Steele, Guy stop strip stty 2nd su 2nd 3rd subshell super-user SuSE 2nd 3rd 4th 5th suspend swapping switch sync () 2nd sysctl system call 2nd System V Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] tail talk tar task list task_struct TCP/IP 2nd telnet Thompson, Ken tilde 2nd time Torvalds, Linus touch tr trap 2nd 3rd Trojan horse truncate () tset tty TurboLinux 2nd 3rd twm typeset Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] UID ul umask 2nd umount 2nd umount () unalias 2nd 3rd unhash uniq unlink () 2nd unset until URL user ID 2nd 3rd 4th effective 2nd 3rd 4th 5th real 2nd root set user ID 2nd 3rd 4th 5th user mode useradd userdel users uucp Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] VFS vim 2nd customizing deleting text moving the cursor saving files VMS VUE 2nd vuewm Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] w wait wait () 2nd wall Wall, Larry wc while 2nd who whoami write write () application resources check box client 2nd copy-and-paste dialog box display manager focus geometry 2nd radio button scroll bars server starting widget window manager 2nd Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] X Window System 2nd xclock xhost 2nd xrdb xterm 2nd Index [SYMBOL] [A] [B] [C] [D] [E] [F] [G] [H] [I] [J] [K] [L] [M] [N] [O] [P] [R] [S] [T] [U] [V] [W] [X] [Z] zcat ... Linux for Programmers and Users By Graham Glass, King Ables Publisher : Prentice Hall Pub Date : February 15, 2006 Print ISBN- 10 : 0-13-185748-7 Print ISBN- 13 : 978-0-13-185748-3... courses The widespread use of Linux has led to the same need for Linux users and instructors When my editors at Prentice- Hall first approached me about creating a Linux version of the book, my flippant response was... but he likes hiking, mountain biking, and skiing just a bit more [Page xxvi] About the Book This book is an outgrowth of the popularity of Linux Its original version, UNIX for Programmers and Users, written by Graham and updated in subsequent editions by King has been widely

Ngày đăng: 26/03/2019, 16:33