Chrome OS: Revise comments in /etc/init/system-services.conf |
|||
Issue description/etc/init/system-services.conf has the following comment: # Jobs that depend on system-services as described above can assume the # following: # * All services implied by 'boot-services' are available. This is correct 99.9% of time, but unless I'm missing something, there seems to be no real synchronization between boot-services and system-services. With the following test Upstart jobs, system-services jobs are started before boot-services' "exec sleep 24h" lines are executed. Can we just ignore such an extreme case, or is it better to rewrite the comment? I'm not really sure if this is worth fixing, but filing this as a feature request for the record. Test scripts: localhost ~ # cat /etc/init/boot-test.conf start on started boot-services pre-start script exec >> /var/log/test.log 2>&1 echo "$(date --rfc-3339=ns): pre-start boot-test.conf" sleep 30 exec sleep 24h end script localhost ~ # cat /etc/init/boot-test-2.conf start on started boot-services script exec >> /var/log/test.log 2>&1 echo "$(date --rfc-3339=ns): start boot-test-2.conf" sleep 30 exec sleep 24h end script localhost ~ # cat /etc/init/system-test.conf start on started system-services pre-start script exec >> /var/log/test.log 2>&1 echo "$(date --rfc-3339=ns): pre-start system-test.conf" exec sleep 24h end script localhost ~ # cat /etc/init/system-test-2.conf start on started system-services script exec >> /var/log/test.log 2>&1 echo "$(date --rfc-3339=ns): start system-test-2.conf" exec sleep 24h end script Test result: localhost ~ # cat /var/log/test.log 2017-06-09 15:18:47.005118578-07:00: start boot-test-2.conf 2017-06-09 15:18:47.005569162-07:00: pre-start boot-test.conf 2017-06-09 15:18:52.526157017-07:00: pre-start system-test.conf 2017-06-09 15:18:52.532803346-07:00: start system-test-2.conf system-test* jobs were started without waiting for 'sleep 30' to finish.
,
Jun 16 2017
Yes, that's more or less what this bug is about: /etc/init/system-services.conf recommends the flawed version in https://chromium.googlesource.com/chromiumos/platform2/+/master/init/upstart/system-services.conf#16 should we either change the recommendation to say "starting" rathern than "started", OR change the wording of the guarantee.
,
Jun 16 2017
Sorry, wrong link: /etc/init/boot-services.conf recommends the "started" version https://chromium.googlesource.com/chromiumos/platform2/+/master/init/upstart/boot-services.conf There's also this: chromiumos/src$ ag 'start on started.*boot-services' -G conf$ | wc -l 36 chromiumos/src$ ag 'start on starting.*boot-services' -G conf$ | wc -l 28
,
Jun 28 2017
,
Jun 28 2018
Issue has not been modified or commented on in the last 365 days, please re-open or file a new bug if this is still an issue. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot |
|||
►
Sign in to add a comment |
|||
Comment 1 by vapier@chromium.org
, Jun 16 2017