On Sat, 10 Sep 2005, Matthias Klose wrote: > Tim Connors writes: > > Package: bash > > Version: 3.0-15 > > Severity: normal > > > > Is there a way to turn off bash's reporting of what signals have > > terminated a program? There is no obvious occurence of the method to > > shut this off, in the man page. > > > > It is most frustrating to have a script that runs a program where it > > not unexpected to receive a signal to kill it, and I have to filter > > out the crap that bash prints out. In a script, it is obvious that > > this shouldn't even happen -- this behaviour should certainly not be > > turned on by default: > > > > 37400,12> gnuserv.restart > > /home/tconnors/bin/gnuserv.restart: line 36: 23475 Terminated > > $GNUSERV 2>/dev/null > > why not start the process using nohup, or in a subshell?
It *is* a shell script. gnuserv.restart is a /bin/bash shell script (although /bin/sh does exactly the same thing, which suprises me since /bin/sh is meant to make bash behave POSIXly), and I want it to not block SIGHUPs, because I want it to restart gnuserv upon receiving a HUP or TERM or whatever. And I have no idea why bash is printing out job control information within a shell script. I did look at the `set -m` option, but it didn't help. There's nothing else in the man pages that I've seen, that help me in any way here. Here's a very simple test: > cat bin/sig-test #!/bin/sh while echo loop ; do sleep 5 done shell1> sig-test sheel2> killall sleep loop bin/sig-test: line 6: 19448 Terminated sleep 5 loop bin/sig-test: line 6: 19458 Terminated sleep 5 loop Is there something obvious I am missing? -- TimC Theoretically one might have been wearing pants at work. -- Anthony de Boer in Scary Devil Monastry -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]