Re: Vanishing threads in shell-script-started process on solaris 10
- From: "Rama" <rama.duggal@xxxxxxxxx>
- Date: 29 Jun 2006 19:29:39 -0700
Tim Bradshaw wrote:
"Rama" <rama.duggal@xxxxxxxxx> wrote:
> Playing around with the problem, I got weird results. Originally, app
binaries were launched out of a bouurne shell script as daemons running
in the background. So my first attempt to debug the problem was to
launch it under dbx's control, and viola ! the problem seemd to
disappear, I saw all the daemons running with all their threads intact
for first time o 10.
Next I tried launching the daemons from bourne shell command line as
background processes (after ensuring that the shell environment
required is all set up). Still the 8 out of 12 threads died
(vanished). Tried launching from Korn-shell prompt and surprise - all
threads intact, the app apeared to be running and processig incoming
stuff. So I tried launching it out of a ksh cript, no luck, back to
vanishing threads.
Is this a tty issue? It smells like it could be one. I can't remember
the details (someone will though) but things in the background have
significantly different behaviour when they try and talk to stdin / stdout
etc. This can (or has in the past) also depend on the shell. There is an
enormous amount of magic here to do with controlling terminals, process
groups &c &c.
One thing to try might be to run it in the foreground but as detached as
you can make it be from a tty. I think something like this:
$ foo >/dev/null 2>&1 </dev/null
Then see what happens to it.
--tim
The app daemonises itself (i.e, fork, close stdin, stdout etc.) upon
startup. In any case, it does run ok when launched from command line.
.
- References:
- Prev by Date: Re: how to check ethernet interface 100M full dup (solaris 8)
- Next by Date: Re: how to check ethernet interface 100M full dup (solaris 8)
- Previous by thread: Re: Vanishing threads in shell-script-started process on solaris 10
- Next by thread: scsi issue
- Index(es):
Relevant Pages
|
|