News for hackers. Stuff that matters.
Re:Real-time notifications from systemd to Slack by Curious42 on Monday March 13, 2017 @05:26AM (#13856351)
Is Systemd a nohup equivalent? If it is, then what's the benefit of using one over the other?
Re:Real-time notifications from systemd to Slack by fnord123 on Monday March 13, 2017 @05:38AM (#13856404)
nohup just runs a process that will ignore SIGHUP.

systemd can also run processes that ignore SIGHUP. But systemd does a lot of things that nohup doesn't do. Please don't attempt to use nohup as a daemon management system for anything but the noddiest of tasks.

If you're going to use anything, you're probably best choosing from this list:

https://en.wikipedia.org/wiki/Operating_system_service_manag...

Re:Real-time notifications from systemd to Slack by JdeBP on Monday March 13, 2017 @03:57PM (#13861755)
... which misses out quite a lot, from s6 through perp to initng.
Re:Real-time notifications from systemd to Slack by koolba on Monday March 13, 2017 @06:31AM (#13856590)
While nohup is used to daemonize a single process, systemd does that and a ton of other stuff. It's a replacement init system that includes everything from daemonization, log handling, auto restarts, and by this time next year will probably make coffee for you as well.
Re:Real-time notifications from systemd to Slack by bandrami on Monday March 13, 2017 @07:15AM (#13856777)
This is what I've never understood about systemd. Somebody will ask "doesn't inetd already do that?" or "doesn't nohup already do that?" or "doesn't runit already do that?" and the answer is always "yes, but systemd does a bunch of other things something else already did too".

shrug

Its setup is way, way too brittle for me, but I guess the QR codes are kind of neat.

Re:Real-time notifications from systemd to Slack by deathanatos on Monday March 13, 2017 @09:41AM (#13857713)
My requirements (for server side daemons) are approximately: start a daemon as a child, and monitor it; if it dies, restart it. Ideally, give me a command-line interface to the managing daemon to gracefully start/stop the child. nohup doesn't do this, making it simply not the right tool for the job. I've never used runit, but it looks closer.
Re:Real-time notifications from systemd to Slack by bandrami on Monday March 13, 2017 @10:03AM (#13857870)
Take a look at PIES[1]. I've switched most of my production systems to it. I especially like that it's inittab-compatible.

[1]: http://www.gnu.org.ua/software/pies/