Advanced Programming in the UNIX Environment (3rd Edition) and over 2 million other books are available for Amazon Kindle . Learn more

Sign in to turn on 1-Click ordering.
Trade in Yours
For a 11.25 Gift Card
Trade in
More Buying Choices
Have one to sell? Sell yours here
Sorry, this item is not available in
Image not available for
Image not available

Start reading Advanced Programming in the UNIX Environment on your Kindle in under a minute.

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.

Advanced Programming in the UNIX Environment (Addison-Wesley Professional Computing) [Paperback]

W. Richard Stevens , Stephen A. Rago
5.0 out of 5 stars  See all reviews (3 customer reviews)
RRP: 44.99
Price: 32.40 & FREE Delivery in the UK. Details
You Save: 12.59 (28%)
o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o
Only 12 left in stock (more on the way).
Dispatched from and sold by Amazon. Gift-wrap available.
Want it tomorrow, 30 Aug.? Choose Express delivery at checkout. Details


Amazon Price New from Used from
Kindle Edition 30.78  
Paperback 32.40  
Trade In this Item for up to 11.25
Trade in Advanced Programming in the UNIX Environment (Addison-Wesley Professional Computing) for an Amazon Gift Card of up to 11.25, which you can then spend on millions of items across the site. Trade-in values may vary (terms apply). Learn more

Book Description

1 Jun 2013 0321637739 978-0321637734 3

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.

Frequently Bought Together

Advanced Programming in the UNIX Environment (Addison-Wesley Professional Computing) + Unix Network Programming: Sockets Networking API v. 1 (Addison-Wesley Professional Computing) + TCP/IP Illustrated: The Protocols v. 1 (Addison-Wesley Professional Computing)
Price For All Three: 107.43

Buy the selected items together

Product details

  • Paperback: 1024 pages
  • Publisher: Addison Wesley; 3 edition (1 Jun 2013)
  • Language: English
  • ISBN-10: 0321637739
  • ISBN-13: 978-0321637734
  • Product Dimensions: 23.1 x 18.8 x 5.3 cm
  • Average Customer Review: 5.0 out of 5 stars  See all reviews (3 customer reviews)
  • Amazon Bestsellers Rank: 194,563 in Books (See Top 100 in Books)
  • See Complete Table of Contents

More About the Authors

Discover books, learn about writers, and more.

Product Description

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.

Inside This Book (Learn More)
Browse Sample Pages
Front Cover | Copyright | Table of Contents | Excerpt | Index
Search inside this book:

Customer Reviews

4 star
3 star
2 star
1 star
5.0 out of 5 stars
5.0 out of 5 stars
Most Helpful Customer Reviews
5 of 5 people found the following review helpful
Format:Kindle Edition
The latest edition of a maestro! Still reigning supreme, a masterstroke of genius writing on a very important programming topic. Immensely readable, near-thorough in coverage of its very technical subject, this books remains excellent for doing anything serious on Linux/UNIX using C. And can anyone argue that Linux/Unix, and its diverse brands, have not become the platform of choice for hosting modern, distributed mobile and web-based application systems? Linux has been gradually moving on, and this update was really due and necessary.

First one needs to possess or build up a good knowledge of and ability at C (with books such as C Programming Modern Approach 2nd or Programming Language 2nd Brian Kernighan supported by the former) this Stevens book's content and guidance is a requirement for crafting any meaningful and useful system with C on Linux/Unix and related operating systems.

I crave the reader's indulgence for a quick (somewhat relevant, I believe) digression. And for such modern, distributed system development you would sure need essential system characteristics such as fault tolerance, scalability, live upgrades without down-time, soft real-time transaction response times and massive throughput; use of distributed in-memory databases, fast instant messaging, robust message queueing systems, Continuous Delivery/Integration, Testing tools, etc. And if one wants to do this without massive resource and time requirements the choice is essentially narrowed down to one platform essentially: Erlang/OTP and its Ecosystem of Library API, Platforms, Tools, etc. So search Erlang, Riak, RabbitMQ, etc.
Read more ›
Comment | 
Was this review helpful to you?
5.0 out of 5 stars Good stuff! 24 Mar 2014
Format:Paperback|Verified Purchase
I was looking for more detail than my other books and found it in this one. I like the style in which it is written easier to read than some other books.
Comment | 
Was this review helpful to you?
5.0 out of 5 stars Very helpful 29 Dec 2013
By gg
Format:Paperback|Verified Purchase
This is a truly recommended book for all software developers who like to gather the most valuable insights of the UNIX internals.
Comment | 
Was this review helpful to you?
Most Helpful Customer Reviews on (beta) 5.0 out of 5 stars  12 reviews
22 of 25 people found the following review helpful
5.0 out of 5 stars Indispensable classic! 23 Aug 2013
By ksw - Published on
In 1992, W. Richard Stevens wrote Advanced Programming in the UNIX Environment (APUE), published in 1993 by Addison-Wesley. The original edition was revised in 2005 by Stephen A. Rago to more accurately reflect the landscape of UNIX and UNIX-like systems. In 2013, Rago wrote an updated 3rd edition upon which this review is based.

APUE is targeted at readers with a working knowledge of UNIX and C. It includes chapter long examples of real-world applications, and manages to simultaneously serve as an enlightening tutorial and a valuable reference book.

Few technical authors have had such a great impact on the geek community as Rich Stevens, and because of this, any review of his books should include a few words about the man himself. Stevens' work typically tops any "recommended reading" list when it comes to TCP/IP networking or UNIX programming. Stevens passed away on September 1st, 1999. In addition to APUE, he authored UNIX Network Programming (Volume 1: APIs and Volume 2: IPC) and TCP/IP Illustrated (Volume 1: Protocols, Volume 2: Implementation, and Volume 3: TCP/T, HTTP, NNTP, Unix Domain Protocols.) Stevens was posthumously awarded the USENIX Lifetime Achievement Award for his extraordinarily lucid teaching and generous spirit within the community, which was accepted on his behalf by his wife and children.

Stephen A. Rago, who accepted the daunting task of revising Stevens' APUE, worked at Bell Laboratories as a UNIX SVR4 developer. His first contact with Rich Stevens was an e-mail regarding a typographical error in Stevens' first book, UNIX Network Programming. Stevens later acted as a technical reviewer for Rago's UNIX System V Network Programming. Rago reciprocated as a technical reviewer for the first edition of APUE, and has done a fine job of revising that same text for the second edition and third editions.

Rago's revisions to the third edition reflect the following changes:
* The text now covers version 4 of the Single UNIX Specification (SUS).
* STREAMS-related interfaces have been obsoleted per SUS POXIS.1-2008.
* The following platforms are covered: FreeBSD 8.0, Linux 3.2.0 (the Ubuntu 12.04 distribution), Mac OS X version 10.6.8 (Darwin 10.80.0), and Solaris 10.
* Linux 2.6 changed to the Native POSIX Thread Library (NPTL).
* "In total, this edition includes more than 70 new interfaces, including interfaces to handle asynchronous I/O, spin locks, barriers, and POSIX semaphores. Most obsolete interfaces are removed, except for a few ubiquitous ones."

Stevens believed that the best way to learn code was to read code, and his books reflect that philosophy well. The original edition contained a chapter titled "Communicating with a PostScript Printer" that included a complete program to communicate over a RS-232 serial connection to an attached printer. Most printers today are accessed via a network interface, and in the second and third editions Rago has changed the material to reflect this while still maintaining the original intent of the chapter.

This book is no superficial update from the previous edition. From cover to cover, it's apparent that Rago has carefully interpreted the original text and rewritten it to accurately reflect the changes of the past several years; he has also managed to preserve to original lucid and efficient presentation style of Stevens' classic.
10 of 11 people found the following review helpful
5.0 out of 5 stars I dig it! 7 Sep 2013
By L. Fesenden - Published on
Good gracious this is a big book! What's funny is I KNOW I have read and reviewed a previous edition of this book and I spent a half an hour looking for it this morning, but it must have been before I moved and on my old Blog. That being the case, well it's high time you heard about this monster!

This book, Advanced Programming in the Unix Environment, by Stevens and Rago, is the 3rd edition of what is, essentially, the Unix Programming Bible. In fact, so much so that I cannot imagine any serious Unix/Linux/**ux contributor that doesn't own a copy or at least know what it is.

This is *not* light reading. It is a reference book. This is the stuff geek dreams are coded in and you are going to want to be familiar with the C language to get a lot of this.

All the internal workings and ideas about this kind of operating system, how it works, or is supposed to work and code examples are included here. The least technical chapter in here is the 1st, which is the overview chapter. This goes over things like input/output, files/directories, processes, error handling, and system calls. From there, the chapters narrow in more on specific subjects like Process control, Daemons, Signals, Threading, etc.. Like I said, there is a LOT of very specific information in here. That being said, if you are developing anything more than some scripting, this has what you want to know. This is not to say that those are the only folks that can get anything out of this book, though. Even without understanding the code examples, a person could get a good understanding and overview of how this fantastic type of operating system works, and why. This is the category I find myself in more than any other. Although I have done some C programming, I find myself using this book to help me conceptualize how things are working the background.

No self respecting Unix/Linux geek should be without this book in one format or another. Remember this is not a story book you read once, this is going to be something you turn to for the right information when you need it. I almost always give away my review books after I read through them, but this one is sticking around. In fact, I am just going to take it to work with me so I can have it handy where I would normally need the information anyway
4 of 4 people found the following review helpful
5.0 out of 5 stars Solid update to a great book. 15 Oct 2013
By Jeff Martin - Published on
Advanced Programming in the UNIX Environment (APUE) has long been a standard reference for those seeking to learn about systems programming in the UNIX environment. I was recently provided a review copy of the latest edition, but I have long been familiar with the book.

Don't let the "UNIX" in the title fool you, the examples provided are applicable to the following covered platforms: Linux, Solaris, FreeBSD, and Apple Mac OS X. The concepts taught are going to be useful for many (if not all) modern operating systems. The fact that this is now in its third edition is a testament to the quality of the material and the authors' writing style. Whether you are learning these concepts for the first time, or just want a trustworthy reference, APUE 3rd Edition will be very useful. Look at other reviews and you will see words like "classic", "bible", and "indispensable". There is a well earned reason for this, and this book deserves your consideration if you have any interest at all in the subject matter.
2 of 2 people found the following review helpful
5.0 out of 5 stars Is there abetter UNIX book? 3 Mar 2014
By Vishal Kasliwal - Published on
Format:Paperback|Verified Purchase
Read this - cover to cover. This is simply the best book on UNIX out there. If you use Linux, pair this with 'The Linux Programming Interface' by Michael Kerrisk. My only gripe with this book is that they've dropped the hardcover from this edition and now it comes only in a soft-cover version. For a book like this, having a sturdy hardcover is a must because a softcover will just wear every time you pull this book out until the pages are dog-eared.
5.0 out of 5 stars Where is AIX, HP/UX, among other majors? 31 July 2014
By bernie - Published on
This book is a fantastic starting point in life. Somehow our public schools over look teaching the fundamental skills presented in this book. We learn how to play with toys on simple computers and never really learn what we are doing.

The real strength of this book is in the definitions. We get to see the purpose and flexibility of system calls and functions. Not just use them but understand them. UNIX functions as job control or signals are explained in detail. Let's take just one item "waitpid":

The waitpid function provides three features that aren't provided by the wait function.

You will have to red the book to find out what they are. However there are examples also. Now for people with real systems like AIX all you have to do is ad a "k" to the front of the call and you have the AIX kernel function call "kwaitpid"; voila you now have an understanding that can not be found clearly in a Red Book.

It does help some to have a preunderstanding of the system do you can use the book to fill in the education holes missed when necessary.

The index is worth its weight in gold as you can find functions headers and concepts all in alphabetical order. My favorite is the definitions.

As much as I am a fan of the internet it also pays to carry the information in the form of a book. And all this book has to do is save a couple of hours and it has paid for its self.

Each addition adds newer information at the expense of dropping what appears to be obsolete information; so it would behoove you to obtain a copy of each addition and periodically look for the latest.
Were these reviews helpful?   Let us know
Search Customer Reviews
Only search this product's reviews

Customer Discussions

This product's forum
Discussion Replies Latest Post
No discussions yet

Ask questions, Share opinions, Gain insight
Start a new discussion
First post:
Prompts for sign-in

Search Customer Discussions
Search all Amazon discussions

Look for similar items by category