Re: cannot set terminal process group

2017-12-15 Thread Laurent Bercot


 Indeed, runit does not run the service as a session leader by default.
runsvdir runs every instance of runsv in a different session, but a
runsv instance runs its service in the same session.
 The workaround, as Jonathan pointed out, is to add "setsid"
(or "chpst -P") to your run script, in the command line that execs into
your daemon.

 Note that s6 runs the service as a session leader by default,
precisely to avoid that minor annoyance. There is no benefit in running
the supervisor processes in a different session from the scanner
process, but there is benefit in running the services in their own
session.

--
 Laurent



Re: cannot set terminal process group

2017-12-14 Thread Jonathan de Boyne Pollard

DGSJ:


Well, Crtl+C doesn't work, [...]

It seems to be the time of year for this question.  I just answered 
another variant of it, complete with daemontools-style chain loading 
tools.  Read the further reading and other questions, too.


* https://unix.stackexchange.com/questions/410318/

* https://unix.stackexchange.com/questions/255385/

* https://unix.stackexchange.com/questions/338214/