1 '\" te
   2 .\" Copyright (c) 2008, Sun Microsystems, Inc. All Rights Reserved.
   3 .\" Copyright 2019 Joyent, Inc.
   4 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
   5 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
   6 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
   7 .TH SMF_RESTARTER 5 "Dec 11, 2019"
   8 .SH NAME
   9 smf_restarter \- service management facility conventions for restarters
  10 .SH DESCRIPTION
  11 All service instances in the service management facility must be managed by a
  12 restarter. This manual page describes configuration, functionality, and
  13 reporting characteristics that are common to all restarters in the framework.
  14 Characteristics specific to a particular restarter are described in the
  15 restarter's man page.
  16 .sp
  17 .LP
  18 For each managed service, a restarter relies on retrieving properties on the
  19 service instance to determine configuration. The restarter manages a set of
  20 property groups to communicate the current disposition of a service with
  21 display tools such as \fBsvcs\fR(1).
  22 .SS "Service Configuration"
  23 The common restarter configuration for all services is captured in the
  24 \fBgeneral\fR property group. This group includes the following required and
  25 optional property settings.
  26 .sp
  27 .ne 2
  28 .na
  29 \fB\fBenabled\fR\fR
  30 .ad
  31 .RS 19n
  32 This is a required property. If set, the restarter of an instance attempts to
  33 maintain availability of the service.
  34 .RE
  35 
  36 .sp
  37 .ne 2
  38 .na
  39 \fB\fBrestarter\fR\fR
  40 .ad
  41 .RS 19n
  42 This is an optional property that allows the specification of an alternate
  43 restarter to manage the service instance. If the restarter property is empty or
  44 absent, the restarter defaults to \fBsvc.startd\fR(1M).
  45 .RE
  46 
  47 .sp
  48 .ne 2
  49 .na
  50 \fB\fBsingle_instance\fR\fR
  51 .ad
  52 .RS 19n
  53 This is an optional property. When set, only one instance of the service is
  54 allowed to transition to an online or degraded status at any time. Note that no
  55 known implementation honours this setting, and it should be considered obsolete.
  56 .RE
  57 
  58 .SS "Service Reporting"
  59 All restarters report status using the \fBrestarter\fR property group, which
  60 includes the following properties:
  61 .sp
  62 .ne 2
  63 .na
  64 \fB\fBnext_state\fR\fR
  65 .ad
  66 .RS 19n
  67 The current state and next state, if currently in transition, for instances
  68 stored in these properties. See \fBsmf\fR(5) for a description of the potential
  69 states.
  70 .RE
  71 
  72 .sp
  73 .ne 2
  74 .na
  75 \fB\fBauxiliary_state\fR\fR
  76 .ad
  77 .RS 19n
  78 An astring with no spaces that contains a precise term to describe the full
  79 restarter-specific state in combination with the restarter state property. The
  80 auxiliary state cannot always be set and is always cleared during transition
  81 out of any state. Each restarter must define the precise list of auxiliary
  82 states it uses.
  83 .RE
  84 
  85 .sp
  86 .ne 2
  87 .na
  88 \fB\fBstate_timestamp\fR\fR
  89 .ad
  90 .RS 19n
  91 The time when the current state was reached.
  92 .RE
  93 
  94 .sp
  95 .ne 2
  96 .na
  97 \fB\fBcontract\fR\fR
  98 .ad
  99 .RS 19n
 100 The primary process contract ID, if any, under which the service instance is
 101 executing.
 102 .RE
 103 
 104 .SH SEE ALSO
 105 \fBsvcs\fR(1), \fBsvc.startd\fR(1M), \fBservice_bundle\fR(4), \fBsmf\fR(5),
 106 \fBsmf_method\fR(5)