The Linux Programming Interface

Front Cover
No Starch Press, 2010 - Computers - 1552 pages

The Linux Programming Interface is the definitive guide to the Linux and UNIX programming interface—the interface employed by nearly every application that runs on a Linux or UNIX system.

In this authoritative work, Linux programming expert Michael Kerrisk provides detailed descriptions of the system calls and library functions that you need in order to master the craft of system programming, and accompanies his explanations with clear, complete example programs.

You'll find descriptions of over 500 system calls and library functions, and more than 200 example programs, 88 tables, and 115 diagrams. You'll learn how to:

* Read and write files efficiently
* Use signals, clocks, and timers
* Create processes and execute programs
* Write secure programs
* Write multithreaded programs using POSIX threads
* Build and use shared libraries
* Perform interprocess communication using pipes, message queues, shared memory, and semaphores
* Write network applications with the sockets API

While The Linux Programming Interface covers a wealth of Linux-specific features, including epoll, inotify, and the /proc file system, its emphasis on UNIX standards (POSIX.1-2001/SUSv3 and POSIX.1-2008/SUSv4) makes it equally valuable to programmers working on other UNIX platforms.

The Linux Programming Interface is the most comprehensive single-volume work on the Linux and UNIX programming interface, and a book that's destined to become a new classic.

 

What people are saying - Write a review

LibraryThing Review

User Review  - Tobias.Bruell - LibraryThing

This book is an exhaustive description of the Linux/UNIX system calls and related C-library functions. It could also be used as a reference. The book is nicely divided into chapters, each of which is ... Read full review

User Review - Flag as inappropriate

This is an amazing book. While I was learning the Linux API I could turn to a topic in the book, understand the concept without having read the prior pages and if a sentence generated a question, it was usually answered in the next sentence. I have never had a reference this well written. If you are writing applications for Linux this book is an absolute must. The book is accompanied by an extensive set of example programs and a library you can include with your application. 

Contents

History and Standards
1
Fundamental Concepts
21
System Programming Concepts
43
File IO The Universal IO Model
69
File IO Further Details
89
Processes
113
Memory Allocation
139
Users and Groups
153
Writing Secure Privileged Programs
783
Capabilities
797
Login Accounting
817
Fundamentals of Shared Libraries
833
Advanced Features of Shared Libraries
859
Interprocess Communication Overview
877
Pipes and FIFOs
889
Introduction to System V IPC
921

Process Credentials
167
Time
185
System Limits and Options
211
System and Process Information
223
File IO Buffering
233
File Systems
251
File Attributes
279
Extended Attributes
311
Access Control Lists
319
Directories and Links
339
Monitoring File Events
375
Signals Fundamental Concepts
387
Signals Signal Handlers
421
Signals Advanced Features
447
Timers and Sleeping
479
Process Creation
513
Process Termination
531
Monitoring Child Processes
541
Program Execution
563
Process Creation and Program Execution in More Detail
591
Threads Introduction
617
Threads Thread Synchronization
631
Threads Thread Safety and PerThread Storage
655
Threads Thread Cancellation
671
Threads Further Details
681
Process Groups Sessions and Job Control
699
Process Priorities and Scheduling
733
Process Resources
753
Daemons
767
System V Message Queues
937
System V Semaphores
965
System V Shared Memory
997
Memory Mappings
1017
Virtual Memory Operations
1045
Introduction to POSIX IPC
1057
POSIX Message Queues
1063
POSIX Semaphores
1089
POSIX Shared Memory
1107
File Locking
1117
Sockets Introduction
1149
Sockets UNIX Domain
1165
Sockets Fundamentals of TCPIP Networks
1179
Sockets Internet Domains
1197
Sockets Server Design
1239
Sockets Advanced Topics
1253
Terminals
1289
Alternative IO Models
1325
Pseudoterminals
1375
Tracing System Calls
1401
Parsing CommandLine Options
1405
Casting the NULL Pointer
1413
Kernel Configuration
1417
Further Sources of Information
1419
Solutions to Selected Exercises
1425
Bibliography
1437
Index
1447
Copyright

Other editions - View all

Common terms and phrases

About the author (2010)

Michael Kerrisk has been using and programming UNIX systems for more than 20 years, and has taught many week-long courses on UNIX system programming. Since 2004, he has maintained the man-pages project, which produces the manual pages describing the Linux kernel and glibc programming APIs. He has written or co-written more than 250 of the manual pages and is actively involved in the testing and design review of new Linux kernel-userspace interfaces. Michael lives with his family in Munich, Germany.

Bibliographic information