UNIX系统编程-通信.并发与线程-(英文版)

本书特色

[

本书是一本基于*UNIX 标准的完备的参考书,对UNIX 编程的要点进行了清晰易懂的介绍,从一些用于说明如何使用系统调用的短小代码段开始,逐渐过渡到能帮助读者扩展自己技能水平的实际项目中。书中对通信、并发和线程问题进行了深入探讨,对复杂的概念,例如信号和并发,进行了全面且清晰的解释。本书还覆盖了与文件、信号、信号量、POSIX 线程和客户机—服务器通信相关的内容。书中不仅提供了大量实例和练习,还专门设计了有针对性的项目并给出了参考答案。

]

内容简介

[

√ 经典原味,UNIX**宝典。
√ 基于*UNIX标准的独立参考书,专业、全面、清晰。
√ 大量实例、练习、可重用的代码和用于网络通信应用程序的简化库。
√ 作者为麻省理工学院博士,现任德州大学圣安东尼奥分校计算机科学系讲师。

]

作者简介

[

无(影印版无译者……………………………………………………………………………………………………………………) Kay A. Robbins , Steve Robbins (凯罗·宾斯,史蒂夫·罗宾斯)拥有麻省理工学院博士学位,就任于德州大学圣安东尼奥分校计算机学院。

]

目录

ContentsI Fundamentals 11 Technology’s Impact on Programs 31.1 TerminologyofChange . . . . . . . . . . . . . . . . . . . . . 41.2 Time andSpeed . . . . . . . . . . . . . . . . . . . . . . . . . 51.3 Multiprogramming and Time Sharing . . . . . . . . . . . . . . 71.4 Concurrency at the Applications Level . . . . . . . . . . . . . 91.5 Security and Fault Tolerance . . . . . . . . . . . . . . . . . . 131.6 Buffer Overflows for Breaking and Entering . . . . . . . . . . 141.7 UNIXStandards . . . . . . . . . . . . . . . . . . . . . . . . . 181.8 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 202 Programs, Processes and Threads 212.1 How a Program Becomes a Process . . . . . . . . . . . . . . . 222.2 Threads andThreadofExecution . . . . . . . . . . . . . . . . 232.3 Layout of a Program Image . . . . . . . . . . . . . . . . . . . 242.4 LibraryFunctionCalls . . . . . . . . . . . . . . . . . . . . . 262.5 Function Return Values and Errors . . . . . . . . . . . . . . . 292.6 ArgumentArrays . . . . . . . . . . . . . . . . . . . . . . . . 312.7 Thread-SafeFunctions . . . . . . . . . . . . . . . . . . . . . 382.8 UseofStaticVariables . . . . . . . . . . . . . . . . . . . . . 402.9 StructureofStaticObjects . . . . . . . . . . . . . . . . . . . 422.10 Process Environment . . . . . . . . . . . . . . . . . . . . . . 482.11 Process Termination . . . . . . . . . . . . . . . . . . . . . . . 512.12 Exercise: An env Utility . . . . . . . . . . . . . . . . . . . 542.13 Exercise: Message Logging . . . . . . . . . . . . . . . . . . . 552.14 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 563 Processes in UNIX 593.1 Process Identification . . . . . . . . . . . . . . . . . . . . . . 603.2 ProcessState . . . . . . . . . . . . . . . . . . . . . . . . . . 613.3 UNIX Process Creation and fork . . . . . . . . . . . . . . . 643.4 The wait Function . . . . . . . . . . . . . . . . . . . . . . 713.5 The exec Function . . . . . . . . . . . . . . . . . . . . . . 783.6 Background Processes and Daemons . . . . . . . . . . . . . . 843.7 Critical Sections . . . . . . . . . . . . . . . . . . . . . . . . . 863.8 Exercise: Process Chains . . . . . . . . . . . . . . . . . . . . 873.9 Exercise: Process Fans . . . . . . . . . . . . . . . . . . . . . 883.10 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 894 UNIX I/O 914.1 DeviceTerminology . . . . . . . . . . . . . . . . . . . . . . . 924.2 Reading and Writing . . . . . . . . . . . . . . . . . . . . . . 924.3 OpeningandClosingFiles . . . . . . . . . . . . . . . . . . . 1024.4 The select Function . . . . . . . . . . . . . . . . . . . . . 1074.5 The pollFunction . . . . . . . . . . . . . . . . . . . . . . . 1164.6 File Representation . . . . . . . . . . . . . . . . . . . . . . . 1194.7 Filters and Redirection . . . . . . . . . . . . . . . . . . . . . 1284.8 FileControl . . . . . . . . . . . . . . . . . . . . . . . . . . . 1324.9 Exercise: Atomic Logging . . . . . . . . . . . . . . . . . . . 1354.10 Exercise: A cat Utility . . . . . . . . . . . . . . . . . . . . 1414.11 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 1435 Files and Directories 1455.1 UNIXFileSystemNavigation . . . . . . . . . . . . . . . . . 1465.2 Directory Access . . . . . . . . . . . . . . . . . . . . . . . . 1525.3 UNIX File System Implementation . . . . . . . . . . . . . . . 1585.4 Hard Links and Symbolic Links . . . . . . . . . . . . . . . . 1625.5 Exercise: The which Command . . . . . . . . . . . . . . . 1735.6 Exercise: Biffing . . . . . . . . . . . . . . . . . . . . . . . . 1745.7 Exercise: News biff . . . . . . . . . . . . . . . . . . . . . 1775.8 Exercise: Traversing Directories . . . . . . . . . . . . . . . . 1795.9 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 1816 UNIX Special Files 1836.1 Pipes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1846.2 Pipelines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1886.3 FIFOs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1926.4 Pipes and the Client-Server Model . . . . . . . . . . . . . . . 1966.5 TerminalControl . . . . . . . . . . . . . . . . . . . . . . . . 2036.6 AudioDevice . . . . . . . . . . . . . . . . . . . . . . . . . . 2146.7 Exercise:Audio . . . . . . . . . . . . . . . . . . . . . . . . . 2196.8 Exercise: Barriers . . . . . . . . . . . . . . . . . . . . . . . . 2216.9 Exercise: The stty Command . . . . . . . . . . . . . . . . 2236.10 Exercise: Client-Server Revisited . . . . . . . . . . . . . . . . 2236.11 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 2237 Project: The Token Ring 2257.1 RingTopology . . . . . . . . . . . . . . . . . . . . . . . . . . 2267.2 RingFormation . . . . . . . . . . . . . . . . . . . . . . . . . 2277.3 RingExploration . . . . . . . . . . . . . . . . . . . . . . . . 2347.4 SimpleCommunication . . . . . . . . . . . . . . . . . . . . . 2367.5 MutualExclusionwithTokens . . . . . . . . . . . . . . . . . 2377.6 MutualExclusionbyVoting . . . . . . . . . . . . . . . . . . . 2387.7 Leader Election on an Anonymous Ring . . . . . . . . . . . . 2397.8 TokenRingforCommunication . . . . . . . . . . . . . . . . . 2417.9 Pipelined Preprocessor . . . . . . . . . . . . . . . . . . . . . 2437.10 Parallel Ring Algorithms . . . . . . . . . . . . . . . . . . . . 2467.11 FlexibleRing . . . . . . . . . . . . . . . . . . . . . . . . . . 2507.12 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 251II Asynchronous Events 2538 Signals 2558.1 BasicSignalConcepts . . . . . . . . . . . . . . . . . . . . . . 2568.2 GeneratingSignals . . . . . . . . . . . . . . . . . . . . . . . 2568.3 Manipulating Signal Masks and Signal Sets . . . . . . . . . . 2618.4 Catching and Ignoring Signals—sigaction . . . . . . . . . 2678.5 Waiting for Signals—pause, sigsuspend and sigwait 2738.6 Handling Signals: Errors and Async-signal Safety . . . . . . . 2838.7 Program Control with siglongjmp and sigsetjmp . . . 2868.8 Programming with Asynchronous I/O . . . . . . . . . . . . . 2888.9 Exercise:DumpingStatistics . . . . . . . . . . . . . . . . . . 2998.10 Exercise: Spooling a Slow Device . . . . . . . . . . . . . . . 2998.11 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 3009 Times and Timers 3019.1 POSIXTimes . . . . . . . . . . . . . . . . . . . . . . . . . . 3029.2 SleepFunctions . . . . . . . . . . . . . . . . . . . . . . . . . 3149.3 POSIX:XSI IntervalTimers . . . . . . . . . . . . . . . . . . . 3159.4 Realtime Signals . . . . . . . . . . . . . . . . . . . . . . . . 3209.5 POSIX:TMRIntervalTimers . . . . . . . . . . . . . . . . . . 3249.6 Timer Drift, Overruns and Absolute Time . . . . . . . . . . . 3299.7 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 33910 Project: Virtual Timers 34110.1 ProjectOverview . . . . . . . . . . . . . . . . . . . . . . . . 34210.2 SimpleTimers . . . . . . . . . . . . . . . . . . . . . . . . . . 34410.3 Setting One of Five Single Timers . . . . . . . . . . . . . . . 34710.4 Using Multiple Timers . . . . . . . . . . . . . . . . . . . . . 35710.5 A Robust Implementation of Multiple Timers . . . . . . . . . 36310.6 POSIX:TMRTimer Implementation . . . . . . . . . . . . . . 36710.7 mycron, a Small Cron Facility . . . . . . . . . . . . . . . . . 36710.8 AdditionalReading . . . . . . . . . . . . . . . . . . . . . . . 36811 Project: Cracking Shells 36911.1 BuildingaSimpleShell . . . . . . . . . . . . . . . . . . . . . 37011.2 Redirection . . . . . . . . . . . . . . . . . . . .

封面

UNIX系统编程-通信.并发与线程-(英文版)

书名:UNIX系统编程-通信.并发与线程-(英文版)

作者:凯罗.宾斯

页数:904

定价:¥198.0

出版社:电子工业出版社

出版日期:2017-04-01

ISBN:9787121308536

PDF电子书大小:79MB 高清扫描完整版

百度云下载:http://www.chendianrong.com/pdf

发表评论

邮箱地址不会被公开。 必填项已用*标注