genode/repos/os/src/init
Norman Feske 3bbeacad20 init: preserve final state of exited children
This is a follow-up patch of "init: avoid too eager child restart". On
each config update of init, init re-applies child-specific configuration
changes. In the case of an already exited child, this re-evaluation
wrongly marked such a child as abandoned because the child's environment
sessions do no longer exist. Abandoning the child, in turn, triggers the
destruction and subseqent restart (because the <start> node of the
configuration still exists). The latter is bad for two reasons.

First, the exit state of the original instance becomes lost. Second, the
restart may have unexpected side effects due to sessions created by the
new instance. I.e., when resizing a partition in sculpt, init would
wrongly restart the gpt-write tool after the tool successfully exited.
This collides with a newly started instance of part_blk/resize2fs, which
now competes with the second gpt-write instance for the exclusive access
of the targeted block device.

The patch prevents init from re-applying configurations to exited
children. The accompanied test case covers the corner case.
2018-07-03 09:39:30 +02:00
..
alias.h init: refactoring into multiple files 2017-03-24 16:19:56 +01:00
child_registry.h Follow practices suggested by "Effective C++" 2018-01-17 12:14:35 +01:00
child.cc init: preserve final state of exited children 2018-07-03 09:39:30 +02:00
child.h init: support dynamic cap-quota adjustment 2018-06-12 12:11:42 +02:00
config.explicit_routing Remove obsolete RAM/CAP services from run scripts 2017-05-31 13:16:22 +02:00
config.priority Remove obsolete RAM/CAP services from run scripts 2017-05-31 13:16:22 +02:00
config.wildcard Remove obsolete RAM/CAP services from run scripts 2017-05-31 13:16:22 +02:00
config.xsd init config.xsd: add ld_verbose attribute 2018-02-09 13:34:19 +01:00
main.cc init: defer immediate restart of abandoned child 2018-06-12 12:11:47 +02:00
name_registry.h init: refactoring into multiple files 2017-03-24 16:19:56 +01:00
report.h init: reduce report latency for resource requests 2018-06-12 12:11:38 +02:00
server.cc Follow practices suggested by "Effective C++" 2018-01-17 12:14:35 +01:00
server.h os: make 'Buffered_xml' util publicly available 2018-02-09 13:34:17 +01:00
service.h Follow practices suggested by "Effective C++" 2018-01-17 12:14:35 +01:00
state_reporter.h init: reduce report latency for resource requests 2018-06-12 12:11:38 +02:00
target.mk run: target-specific config schemata 2017-12-21 15:01:36 +01:00
types.h Capability quota accounting and trading 2017-05-31 13:16:06 +02:00
utils.h init: support dynamic cap-quota adjustment 2018-06-12 12:11:42 +02:00
verbose.h init: refactoring into multiple files 2017-03-24 16:19:56 +01:00