
Advanced UNIX programming
by Marc J. Rochkind · first published 1985
26mentions
12recommended by
15HN commenters
2010–2024first – last mentioned
80% recommend20% neutral
Why HN recommends it
Hands-on, approachable guide to Unix system programming, with strong coverage of signals, processes and writing a shell. Suited to working C programmers and anyone moving past basic syntax.
Summarised by Claude from recommending comments
This book covers how to program UNIX clearly and systematically at the system call level while providing the seasoned programmer with practical advice for using I/O on files and terminals, multitasking, signals and system administration.
Affiliate links. As an Amazon Associate I earn from qualifying purchases.







…http://en.wikipedia.org/wiki/The_C_Programming_Language_%28b...). The best way to play around with C is to mess around with Systems Programming in UNIX. Get Systems Programming book (http://www.amazon.com/Advanced-UNIX-Programming-Marc-Rochkin...) Having said all of the above, do you know what you are interested in doing with a degree in C.S? There are some nice interdisciplinary programs where you may not have to do all the hardcore…
on “ASK HN: From lit major to Computer Science Masters?” ↗The classic for me of an exposition of writing a shell is Advanced UNIX Programming by Marc Rochkind (Bell labs guy and author of SCCS) (not to be confused with W Richard Steven's text which is also excellent) http://basepath.com/aup/ First published in 1985; for me ranks up there…
on “Write a Shell in C (2015)” ↗Not sure from your question, whether you are only looking for resources on TTYs, or general resources on writing a Unix shell. If the latter, this book is quite good: Search for "advanced unix programming marc rochkind" and also see this specific page (it's one of the hits of that search): http://basepath.com/aup/ I had read it some years ago. (It used to come bundled with HP-UX servers and workstations,…
on “The TTY demystified (2008)” ↗Marc Rochkind's Advanced Unix Programming is a very approachable book that walks you through, among other things, writing a shell. It's a good book, give it a read.
on “Writing a Unix Shell” ↗If you'd like to see Marc Rochkind's other stuff, go to https://basepath.com/new/books.php I can particularly recommend Advanced UNIX Programming (2nd Edition) even though it is a little old.
on “The Source Code Control System (1975) [pdf]” ↗…with K&R for reference, but then go to the following two books for threading and all the other stuff like networking: You need these two books to get down C and it's ecosystem (make, autotools, etc): Advanced Unix Programming by Rochkind (Really good explanation of signals especially): http://www.amazon.com/Advanced-UNIX-Programming-Marc-Rochkin... Gnu/Linux Application Programming by M. Tim Jones (Recovers some of the same…
on “Ask HN: I use and love Python. What's the best book to learn C ?” ↗…that show little examples/snippets and or O'Reilly reference books that I used to purchase when starting a new language to get an idea for the syntax. The best book that I have ever bought and read was "Advanced UNIX Programming" by Marc J. Rochkind. It helped me get a much firmer grasp on Unix programming and along with it C which I was lacking at the time. I've got a copy of the Dragon book sitting on my desk, it is waiting…
on “Books Programmers Don't Really Read But Recommend” ↗I did something similar at the start of my admin/programming career. 1. Read the entire UNIX manual (wasn't that big at the time) 2. Read Rochkind "Advanced UNIX Programming" 3. Read K&R "The C Programming Language" 4. Read K&P "The UNIX Programming Environment" sometime later I also read (parts of) Stevens UNIX Networking. I'd say these made a very strong base from which…
on “What programming languages are used late at night?” ↗All in no particular order.... As a Unix systems engineer, I would choose 1. W.R. Stevens books on Unix and Tcp/ip. 2. Rochkind's Advanced UNIX Programming. 3. Most of the Unix/Linux manual pages. 4. Bash FAQ As a Unix systems programmer I would choose 1. Mythical Man Month 2. Jon Bentley's Programming Pearls. 3. K&R C and Stroustrup…
on “Ask HN: What are the books you wish your colleagues had read?” ↗On that topic, I really liked Advanced Unix Programming by Marc Rochkind. [1] It was an early Unix programming book and covered very well how to correctly use many important Unix system calls and showed how to write some non-trivial apps including a simple…
on “Ask HN: What books do you keep on your desk?” ↗…Software Engineering by Ghezzi, Jazayeri and Mandrioli * The Practice of Programming by Kernighan & Pike. * Code Complete by Steve Mcconnell. * The Unix Programming Environment by Kernighan & Pike * Advanced Unix Programming by Marc Rochkind. * C Interfaces and Implementation by David Hanson. * Large Scale C++ design by John Lakos * Unix Network Programming by Richard Stevens. The key is that while reading the above you…
on “Ask HN: How to transition from academic programming to software engineering?” ↗…https://www.amazon.com/Morgan-Kaufmann-Computer-Architecture... * UNIX Systems for Modern Architectures: Symmetric Multiprocessing and Caching for Kernel Programmers - https://www.amazon.com/UNIX-Systems-Modern-Architectures-Mul... * Advanced UNIX Programming - https://www.amazon.com/Advanced-UNIX-Programming-Marc-Rochki...
on “Ask HN: What are some architectural decisions that improved your codebase?” ↗I strongly recommend Rochkind - Advanced Unix Programming. Despite the title, it's not that advanced; the "advanced" here refers to system-level programming, not application. Note, for this you probably need to learn C. K&R ed2 remains an excellent book for…
on “Ask HN: How can a intermediate-beginner learn Unix/Linux and programming?” ↗…ELF: From the Programmer's Perspective; a paper by Hongjiu Lu. * UNIX Network Programming by Richard Stevens. Initially, get the old 1st edition since it contains TCP/IP, IPC etc. all in one volume. * Advanced UNIX Programming by Marc Rochkind. * Advanced programming in the UNIX Environment by Richard Stevens. * UNIX Systems Programming by Robbins and Robbins. * Programming for the Real World, POSIX.4 by Bill Gallmeister.
on “Ask HN: How to learn proper systems programming?” ↗To your first three above, add Marc Rochkind's Advanced Unix Programming and Richard Stevens' Advanced Programming in the Unix Environment and you have got yourself a complete course in C/Unix programming which is the bedrock for everything else; C is the "lingua franca" and…
on “Brian Kernighan on “The Practice of Programming” [video]” ↗