Understanding processes is fundamental to understanding UNIX. This book zeroes right in on the key techniques of processes and interprocess communication (IPC) - from primitive communications to the complexities of sockets.Loaded with examples and illustrations that clarify each technique, Interprocess Communications in UNIX covers topics like: beginning and ending processes; using fork and exec together; using primitive communications; and working with both named and unnamed pipes. Learn how to create message queues; use remote procedure calls (RPCs); create and access semaphore sets; and create shared memory segments. Once you attain a thorough mastery of interprocess communication methodologies, using POSIX threads you'll learn communications techniques for multithreaded applications. Learn to handle multiple threads in both single and multiple processes. From beginning to end, the book truly leads you through the "nooks and crannies" of UNIX - making you a dramatically more effective programmer.
|Product dimensions:||6.95(w) x 9.18(h) x 1.39(d)|
Table of Contents
(NOTE: Each chapter beings with an Introduction and concludes with a Summary.)
1. Programs and Processes.
Library Functions. System Calls. Linking Object Code. Managing Failures. Executable File Format. System Memory. Process Memory. The u Area. Process Memory Addresses. Creating a Process.
2. Processing Environment.
Process ID. Parent Process ID. Process Group ID. Permissions. Real and Effective User and Group Ids. File System Information. File Information. Process Resource Limits. Signaling Processes. Command Line Values. Environment Variables.
3. Using Processes.
The fork System Call Revisited. exec's Minions. Execlp. Execvp. Using fork and exec Together. Ending a Process. Waiting on Processes.
4. Primitive Communications.
Lock Files. Locking Files. Signals--Continued. Signal and Signal Management Calls.
Unnamed Pipes. Named Pipes.
6. Message Queues.
IPC System Calls--A Synopsis. Creating a Message Queue. Message Queue Control. Message Queue Operations. A Client-Server Message Queue Example.
Creating and Accessing Semaphore Sets. Semaphore Control. Semaphore Control Details. Semaphore Operations. Semaphore Operation Details.
8. Shared Memory.
Creating a Shared Memory Segment. Shared Memory Control. Shared Memory Operations. Using a File as Shared Memory.
9. Remote Procedure Calls.
Executing Remote Commands at a System Level. Executing Remote Commands in a C Program. Transforming a Local Function Call Into a Remote Procedure. Debugging RPC Applications. Using rpcgen to Generate Templates and a makefile. Encoding and Decoding Arbitrary Data Types. Using Broadcasting to Search for an RPC Service.
Communication Basics. Network Addresses. Domains--Network and Communication. Protocol Families. Socket Types. IPC Using socketpair. Sockets--The Connection-Oriented Paradigm. A UNIX Domain Stream Socket Example. An Internet Domain Stream Socket Example. Sockets--The Connectionless Paradigm. A UNIX Domain Datagram Socket Example. An Internet Domain Datagram Socket Example. Multiplexing I/O with select. Peeking at Data. Out of Band Messages.
Creating a Thread. Exiting a Thread. Basic Thread Management. Thread Attributes. Scheduling Threads. Using Signals in Threads. Thread Synchronization. Mutex Variables. Condition Variables. Read/Write Locks. Multithread Semaphores. Thread-Specific Data. Debugging Multithreaded Programs. Dbx. lock_lint Utility.
A. Using UNIX Manual Pages.
Manual Page Sections. Manual Page Format. Standard C Library System Calls/Library Functions.
B. UNIX Error Messages.
C. RPC Syntax Diagrams.
Introduction. RPC Definitions. Program-definition. Const-definition. Enum-definition. Typedef-definition. Structure-definition. Union-definition. RPC Keywords. Some RPC Examples.