Synopses & Reviews
For more than twenty years, serious C programmers have relied on one book for practical, in-depth knowledge of the programming interfaces that drive the UNIX and Linux kernels: W. Richard Stevens’ Advanced Programming in the UNIX® Environment . Now, once again, Rich’s colleague Steve Rago has thoroughly updated this classic work. The new third edition supports today’s leading platforms, reflects new technical advances and best practices, and aligns with Version 4 of the Single UNIX Specification.
Steve carefully retains the spirit and approach that have made this book so valuable. Building on Rich’s pioneering work, he begins with files, directories, and processes, carefully laying the groundwork for more advanced techniques, such as signal handling and terminal I/O. He also thoroughly covers threads and multithreaded programming, and socket-based IPC.
This edition covers more than seventy new interfaces, including POSIX asynchronous I/O, spin locks, barriers, and POSIX semaphores. Most obsolete interfaces have been removed, except for a few that are ubiquitous. Nearly all examples have been tested on four modern platforms: Solaris 10, Mac OS X version 10.6.8 (Darwin 10.8.0), FreeBSD 8.0, and Ubuntu version 12.04 (based on Linux 3.2).
As in previous editions, you’ll learn through examples, including more than ten thousand lines of downloadable, ISO C source code. More than four hundred system calls and functions are demonstrated with concise, complete programs that clearly illustrate their usage, arguments, and return values. To tie together what you’ve learned, the book presents several chapter-length case studies, each reflecting contemporary environments.
Advanced Programming in the UNIX® Environment has helped generations of programmers write code with exceptional power, performance, and reliability. Now updated for today’s systems, this third edition will be even more valuable.
Synopsis
Master the system calls at the heart of today's UNIX and Linux systems: the programming interfaces that drive the UNIX and Linux kernels and run everything from filesystems and multitasking to interprocess communication. A thorough knowledge of system calls is essential for every UNIX and Linux programmer -- and for 20 years, W. Richard Stevens' Advanced Programming in the Unix Environment has delivered that. Now, Stephen Rago has completely updated this classic to reflect modern distributions including Red Hat 2.6.x, Solaris 10 3, OS X 10.5.4, FreeBSD 7.0.5 -- and for the first time, Ubuntu. As in previous editions, Rago begins with essentials such as file and process control, carefully laying the groundwork for more advanced techniques. He supports his crystal-clear explanations with nearly 10,000 lines of code, all carefully tested on each of these leading versions and distributions. Rago begins with an up-to-date overview of the UNIX System, its standardization processes, and its diverse implementations. Next, he introduces file I/O, files, directories, and the Standard I/O Library. You'll walk through working with UNIX/Linux system data files and information… controlling the process environment and its relationships… using signals, threads, and daemon processes… mastering advanced I/O techniques, interprocess communication, sockets, and advanced IPC… using Terminal I/O and Pseudo Terminals… working with database libraries, communicating with network printers, and much more. Appendices provide essential information on function prototypes, miscellaneous source code, and solutions to many of this guide's exercises. For all intermediate-to-advanced level UNIX programmers and software engineers.
Synopsis
Practical, in-depth knowledge of the system programming interfaces that drive the UNIX and Linux kernels
Building on W. Rich Stevens' pioneering work, this third edition of the classic was updated by Steve Rago, a colleague of Stevens, to reflect technical advances and best practices aligning with Version 4 of the Single UNIX Specification.
This edition covers more than seventy interfaces including:
POSIX asynchronous I/O Spin locks Barriers POSIX semaphores
Steve carefully retains the spirit and approach that have made this book so valuable, starting with files, directories, and processes, carefully laying the groundwork for more advanced techniques, such as signal handling and terminal I/O. And he thoroughly covers threads and multithreaded programming, and socket-based IPC.
Filled with examples, case-studies, and access to thousands of lines of downloadable code, Advanced Programming in the UNIX(R) Environment has helped generations of programmers write code with exceptional power, performance, and reliability.
Synopsis
For more than twenty years, serious C programmers have relied on one book for practical, in-depth knowledge of the programming interfaces that drive the UNIX and Linux kernels: W. Richard Stevens’ Advanced Programming in the UNIX® Environment . Now, once again, Rich’s colleague Steve Rago has thoroughly updated this classic work. The new third edition supports today’s leading platforms, reflects new technical advances and best practices, and aligns with Version 4 of the Single UNIX Specification.
Steve carefully retains the spirit and approach that have made this book so valuable. Building on Rich’s pioneering work, he begins with files, directories, and processes, carefully laying the groundwork for more advanced techniques, such as signal handling and terminal I/O. He also thoroughly covers threads and multithreaded programming, and socket-based IPC.
This edition covers more than seventy new interfaces, including POSIX asynchronous I/O, spin locks, barriers, and POSIX semaphores. Most obsolete interfaces have been removed, except for a few that are ubiquitous. Nearly all examples have been tested on four modern platforms: Solaris 10, Mac OS X version 10.6.8 (Darwin 10.8.0), FreeBSD 8.0, and Ubuntu version 12.04 (based on Linux 3.2).
As in previous editions, you’ll learn through examples, including more than ten thousand lines of downloadable, ISO C source code. More than four hundred system calls and functions are demonstrated with concise, complete programs that clearly illustrate their usage, arguments, and return values. To tie together what you’ve learned, the book presents several chapter-length case studies, each reflecting contemporary environments.
Advanced Programming in the UNIX® Environment has helped generations of programmers write code with exceptional power, performance, and reliability. Now updated for today’s systems, this third edition will be even more valuable.
About the Author
The late W. Richard Stevens was the acclaimed author of UNIX® Network Programming, Volumes 1 and 2, widely recognized as the classic texts in UNIX networking; TCP/IP Illustrated, Volumes 1-3; and the first edition of this book.
Stephen A. Rago is the author of UNIX® System V Network Programming (Addison-Wesley, 1993). Rago was one of the Bell Laboratories developers who built UNIX System V Release 4. He served as a technical reviewer for the first edition of Advanced Programming in the UNIX® Environment. Rago currently works as a research staff member in the Storage Systems Group at NEC Laboratories America.
Table of Contents
Foreword to the Second Edition
Preface to the Third Edition
Preface to the Second Edition
Preface to the First Edition
Chapter 1: UNIX System Overview
Chapter 2: UNIX Standardization and Implementations
Chapter 3: File I/O
Chapter 4: Files and Directories
Chapter 5: Standard I/O Library
Chapter 6: System Data Files and Information
Chapter 7: Process Environment
Chapter 8: Process Control
Chapter 9: Process Relationships
Chapter 10: Signals
Chapter 11: Threads
Chapter 12: Thread Control
Chapter 13: Daemon Processes
Chapter 14: Advanced I/O
Chapter 15: Interprocess Communication
Chapter 16: Network IPC: Sockets
Chapter 17: Advanced IPC
Chapter 18: Terminal I/O
Chapter 19: Pseudo Terminals
Chapter 20: A Database Library
Chapter 21: Communicating with a Network Printer
Appendix A: Function Prototypes
Appendix B: Miscellaneous Source Code
Appendix C: Solutions to Selected Exercises
Bibliography
Index