Re: [linux-audio-dev] pthreads and signals

New Message Reply About this list Date view Thread view Subject view Author view Other groups

Subject: Re: [linux-audio-dev] pthreads and signals
From: Ingo Oeser (ingo.oeser_AT_informatik.tu-chemnitz.de)
Date: Thu May 15 2003 - 21:58:07 EEST


On Thu, May 15, 2003 at 10:39:45AM +0200, David Olofson wrote:
> On Wednesday 14 May 2003 23.52, Ingo Oeser wrote:
> [...]
> > Re-exec is an alternative I could envision for realtime.
>
> Further thoughts on that:
>
> If you have a setup with multiple redundant processes and/or machines,
> the obvious job for the "crash handler" is to tell some other process
> or machine to take over. (This could be a matter of sending some
> commands to a hardware mixer or "router".) After that, you should
> just get out of the way ASAP, and maybe restart.

If you are talking HA, then the other processes (or some kind of
monitor in a more fragile solution) should detect the failure and
take over.

If you crash, then you cannot trust your addressspace anymore.

Detecting a crash is very simple for the other process: Just have
a never to be used pipe open and detect SIGCHLD or SIGPIPE. Then
you even know, which one of processes died.

Cannot do that with threads? What a pity...

Anything more sophisticated, which involves data from the
segfaulting process asks for trouble.

Re-exec means, that you just trust your read-only segment, which
is a good assumption until hardware memory errors exist. If they
exist, you have other problems. I'm talking about exec called
with read-only constants, to clarify that.

Regards

Ingo Oeser


New Message Reply About this list Date view Thread view Subject view Author view Other groups

This archive was generated by hypermail 2b28 : Thu May 15 2003 - 22:09:37 EEST