views:

78

answers:

5

Signals seem to be one of those areas that should be conceptually simple and easy to explain but I have never come across one source that is both comprehensive, lucidly written, and up to date. In part this seems to be because of historical cruft, lots of exceptions to rules, different programming standards, the confusion threads throw into the mix, real-time additions, etc.

What's your best written, most complete source on unix/linux/posix signals? Web sites, books, stone tablets, whatever, are acceptable.

+2  A: 

Maybe not comprehensive or lucid, but the following is generally up to date for your platform:

man signal 
Andrew Stein
Man pages are what they are but I was hoping for something more expository.
Newton Falls
Yes, I was a little "tongue in cheek" here. I guess my message is that books can give you a good understanding, but when you have to actually implement, look at the man pages.
Andrew Stein
And I guess that man pages are generally *comprehensive* as well. It is the *lucid* part where they often fail.
Andrew Stein
A: 

W. Richard Stevens is hard to beat on most things UNIX. I own at least 5 of his books and I think they are classics that should be on any UNIX System Programmer's shelf. Cheers.

UNIX Network Programming, Vol 2. Second Edition here http://www.amazon.com/UNIX-Network-Programming-Interprocess-Communications/dp/0130810819

mrjoltcola
Stevens is always great but he really only devotes a half dozen or so pages - and bunch of little references spread around the book - to signals in that volume. I was hoping for some a little more centralized and detailed.
Newton Falls
+1  A: 

Advanced Programming in the UNIX Environment (you may see it referred to as APUE).

R Samuel Klatchko
I have the 1st edition (1992) but it is a bit long in the tooth. Do you know if the signals chapter was significantly updated in the 2nd edition from a couple of years ago?
Newton Falls
Not sure what was changed between the two. The 2nd edition's chapter on signals is 65 pages and has 20 sections (plus an intro and a summary for a total of 22 sections). You can see the titles of the sections in the online table of contents (http://www.apuebook.com/toc.html).
R Samuel Klatchko
+1  A: 

Re: the comments to check man pages: Whenever I encounter man page failure (wrt either lucidity or completeness), I hit up OpenBSD's version. At least nine times out of ten, it's a night and day difference.

So my suggestion in this case is man sigaction & man signal.

pra
+1  A: 

Not the clearest documentation, but it's free and comprehensive: the UNIX spec at opengroup.org.

Section 2.4 Signal Concepts: http://www.opengroup.org/onlinepubs/000095399/functions/xsh_chap02_04.html

Potatoswatter