Project

General

Profile

Actions

Bug #7267

closed

SMF is fast and loose with optional dependencies

Added by Andrew Stormont almost 5 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
High
Assignee:
-
Category:
-
Start date:
2016-08-03
Due date:
% Done:

100%

Estimated time:
Difficulty:
Hard
Tags:
needs-triage
Gerrit CR:

Description

In terms of res order optional dependencies should behave like normal dependencies (when they're online and the restart_on attribute is set to "restart" or "refresh"). In reality this is not the case. Restarting an optional dependency usually results in the dependent being restarted first and the optional dependency being restarted after. Clearly this is broken.

Part of the problem is that optional_all dependencies are bypassed when marking dependents to do down/checking that they've gone down. It also doesn't help that the dependency code is extremely naive and has almost no handling for instances that are transitioning (GV_TOOFFLINE is handled, but that's about it).

In short, the dependency handling code for optional_all dependencies is so loose that they are nearly always considered satisfied. Because of this the start/restart order is completely unpredictable. The other dependency group types suffer from similar problems though to a much lesser extend (except require_any dependencies, which are always satisfied).


Related issues

Related to illumos gate - Bug #7246: SMF stops dependents in the wrong orderClosed2016-07-31

Actions
Related to illumos gate - Bug #7369: regression after 7267 SMF is fast and loose with optional dependenciesResolvedAndrew Stormont2016-09-10

Actions
Related to illumos gate - Bug #7387: SMF is fast and loose with require_any/service dependenciesResolved2016-09-16

Actions
Related to illumos gate - Bug #4395: "svcadm restart" should be identical to "svcadm disable; svcadm enable"New2013-12-12

Actions
Precedes illumos gate - Bug #8890: ipfilter and nfs/server are locked in death raceNew2016-08-042016-08-04

Actions
Actions

Also available in: Atom PDF