[rust-dev] Daemonizing a process

richo richo at psych0tik.net
Wed Jul 9 00:32:54 PDT 2014


On 08/07/14 23:47 -0700, Gulshan Singh wrote:
>Is there currently any way to daemonize a process in Linux? I was using the
>`daemon` function in C: http://man7.org/linux/man-pages/man3/daemon.3.html.
>I asked in the IRC but I didn't get a response.

There's going to be excitement with this, mostly because typically
daemonising involves forking twice to ensure that you're reparented to init,
which will result in a Really Bad Time if you're using libnative.

Therefore, it's possible but only if you've not done too much stuff, which
would be unsafe.

Seperately though, rust *does* need a coherent story here. I'm just not at
all sure what it will look like.



More information about the Rust-dev mailing list