firewalld keeps file descriptors open when forking

Michael Biebl mbiebl at gmail.com
Sat Feb 9 07:44:41 UTC 2013


Hi,

I noticed that firewalld keeps the stdin/stdout/stderror file
descriptors open when forking. The recommended way for daemons is to
redirect those to /dev/null and close all others. See [1] Section
"SysV Daemons, 1. + 9.
This is important when running firewalld in non-systemd environments.

[2] has some example code for python. Unfortunately I'm not much of a
python hacker myself.

Michael

[1] http://0pointer.de/public/systemd-man/daemon.html
[2] http://code.activestate.com/recipes/278731-creating-a-daemon-the-python-way/

-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?


More information about the firewalld-devel mailing list