--background neither closes nor redirects stdin/stdout/stderr
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
tarantool |
Fix Released
|
High
|
Kostja Osipov |
Bug Description
if --daemonize option is given, and the standard output and error point to a terminal, they are neither closed, nor checked for write to succeed.
If there is no 'logger' option, and stdin/stdout are not redirected, this silently drops all logging messages into the void.
Suggestion: if --daemonize option is given, at least check that stderr/stdout are not a tty, and if they are, check that 'logger' option is given in the configuration file. If neither is the case, do not daemonize, because such daemon configuration is broken.
Since stdin is left open, you can't start the daemon remotely using ssh or telnet.
For example, this command simply hangs:
ssh host /bin/tarantool_box --config=
since the forked child keeps its stdin open and pointing to the terminal.
This is how this problem affects scripting.
Changed in tarantool: | |
assignee: | nobody → Yuriy Vostrikov (vostrikov) |
milestone: | none → 1.3.6 |
importance: | Undecided → Low |
status: | New → Confirmed |
Changed in tarantool: | |
assignee: | Yuriy Vostrikov (vostrikov) → Kostja Osipov (kostja) |
importance: | Low → High |
milestone: | none → 1.4.3 |
summary: |
- --daemonize neither closes nor redirects stdin/stdout/stderr + --background neither closes nor redirects stdin/stdout/stderr |
description: | updated |
Changed in tarantool: | |
status: | Confirmed → Fix Committed |
status: | Fix Committed → Fix Released |