Re: Vanishing threads in shell-script-started process on solaris 10



"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

.



Relevant Pages

  • Re: Vanishing threads in shell-script-started process on solaris 10
    ... Originally, app ... I saw all the daemons running with all their threads intact ... Next I tried launching the daemons from bourne shell command line as ...
    (comp.unix.solaris)
  • Re: OT clearcase question [was Re: How to escape this?]
    ... The only shell that works well is sh, ... and haven't seen any issues with launching from a particular shell. ... I have been using the same TK script on and off for 7-8 ... Now Cleartool can no longer launch any application. ...
    (comp.lang.tcl)
  • Re: OT clearcase question [was Re: How to escape this?]
    ... Cleartool (of Clearcase) from a TK application. ... The only shell that works well is sh, ... and haven't seen any issues with launching from a particular shell. ...
    (comp.lang.tcl)
  • shell.exe is not accepting any input after it is launched
    ... The Problem i'm facing is, after the kernel starts, shell (using the platform builder's target control window) is not taking the input after the 'shell.exe' is launched. ... While launching 'shell.exe', first it loads the modules, 'coredll.dll' and 'toolhelp.dll' then it loads the module, 'shell.exe'. ... >>> Loading module toolhelp.dll at address 0x03E10000-0x03E16000 ...
    (microsoft.public.windowsce.embedded)
  • Re: OT clearcase question [was Re: How to escape this?]
    ... Cleartool (of Clearcase) from a TK application. ... The only shell that works well is sh, ... and haven't seen any issues with launching from a particular shell. ...
    (comp.lang.tcl)