I tried to reply to Brian's question earlier but google-groups seems to
have eaten it *eyeroll*. Here's what I wrote:

[In reply to being asked why I think using daemon(3) isn't great]
Mostly that it's a function of the context, not the program, whether it is
to be treated as a daemon or not. But there's also a bunch of stuff to do
with whether the process is/should be a session leader or not, which is
again something the program itself shouldn't be making decisions about. djb
writes a bit about this topic here:
https://cr.yp.to/daemontools/faq/create.html#fghack . The systemd people
even seem to agree (calling a non-backgrounding daemon a "new-style
daemon"), at least as far as non-backgrounding goes:
http://0pointer.de/public/systemd-man/daemon.html#New-Style%20Daemons

Cheers,
  Tony


On Sat, 1 Dec 2018 at 23:12, George Neuner <gneun...@comcast.net> wrote:

> On Thu, 29 Nov 2018 07:19:17 -0800 (PST), Brian Adkins
> <lojicdot...@gmail.com> wrote:
>
> >Just out of curiosity, why do you feel using daemon(3) is not a great
> idea?
> >I'm not disagreeing, just curious about your reasons.
> >
> >On Thursday, November 29, 2018 at 5:54:42 AM UTC-5, Tony Garnock-Jones
> >wrote:
> >>
> >> IMO using daemon(3) is not a great idea. Instead, I like to use djb's
> >> daemontools https://cr.yp.to/daemontools.html to supervise my
> processes.
> >> For example, see the `README` and the `run` script in
> >> https://github.com/tonyg/racket-reloadable-example.
> >>
> >> Tony
>
> daemon(3) is not guaranteed to keep background processes running after
> the the user logs off.
>
> If you need the process to keep running - or to start automatically at
> boot - you really need to use a systemd [preferably] or init script.
> Unfortunately either of these options require root access - which can
> be a problem with some cloud VMs.
>
> George
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Racket Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/racket-users/_4QYrxcWrQw/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>


-- 
Tony Garnock-Jones
to...@leastfixedpoint.com
http://leastfixedpoint.com/

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to