]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
build/ops: restart ceph-osd@.service after 20s instead of 100ms
authorLoic Dachary <ldachary@redhat.com>
Wed, 30 Nov 2016 16:33:54 +0000 (17:33 +0100)
committerLoic Dachary <ldachary@redhat.com>
Thu, 1 Dec 2016 07:28:20 +0000 (08:28 +0100)
commitb3887379d6dde3b5a44f2e84cf917f4f0a0cb120
tree5cd405312a664eea7eee29957fc5592007fc94f9
parentea019fba8ffd8e812e13a43963f81cce6030521b
build/ops: restart ceph-osd@.service after 20s instead of 100ms

Instead of the default 100ms pause before trying to restart an OSD, wait
20 seconds instead and retry 30 times instead of 3. There is no scenario
in which restarting an OSD almost immediately after it failed would get
a better result.

It is possible that a failure to start is due to a race with another
systemd unit at boot time. For instance if ceph-disk@.service is
delayed, it may start after the OSD that needs it. A long pause may give
the racing service enough time to complete and the next attempt to start
the OSD may succeed.

This is not a sound alternative to resolve a race, it only makes the OSD
boot process less sensitive. In the example above, the proper fix is to
enable --runtime ceph-osd@.service so that it cannot race at boot time.

The wait delay should not be minutes to preserve the current runtime
behavior. For instance, if an OSD is killed or fails and restarts after
10 minutes, it will be marked down by the ceph cluster.  This is not a
change that could break things but it is significant and should be
avoided.

Refs: http://tracker.ceph.com/issues/17889

Signed-off-by: Loic Dachary <loic@dachary.org>
systemd/ceph-osd@.service