Merge commit 'dc97a43d4a70c8773a619f11b95b07a787f6f5b7' into merges
[unleashed.git] / share / man / man5 / smf_bootstrap.5
blobde7ab255408b713a39e0fe05d438f25201482090
1 '\" te
2 .\" Copyright (c) 2008, Sun Microsystems, Inc. All Rights Reserved.
3 .\" 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.
4 .\" 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.
5 .\" 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]
6 .TH SMF_BOOTSTRAP 5 "Sep 25, 2008"
7 .SH NAME
8 smf_bootstrap \- service management facility boot, packaging, and compatibility
9 behavior
10 .SH DESCRIPTION
11 .sp
12 .LP
13 The service management facility establishes conventions for delivering service
14 manifests, incorporating service manifest changes, describing service
15 configuration stability, using service configuration overrides, and the use of
16 service profiles.
17 .SS "Manifest Loading at Boot"
18 .sp
19 .LP
20 The \fBsvc:/system/manifest-import:default\fR service uses \fBsvccfg\fR(8) to
21 import certain manifest files from the \fB/var/svc/manifest\fR directory tree
22 into the service configuration repository. The service imports files that it
23 has not imported previously and those files which have changed since the last
24 time they were imported by the service. When a manifest is imported by the
25 service, a hash of the file that includes its contents is recorded in a
26 property group of the \fBsvc:/smf/manifest\fR service. The
27 \fBmanifest-import\fR service uses the hash to determine whether the file has
28 changed. See \fBsvccfg\fR(8) for information on the \fBsvccfg import\fR
29 behavior for services that already exist in the repository.
30 .SS "Manifest Handling During Packaging Operations"
31 .sp
32 .LP
33 Service manifests within packages should be identified with the class
34 \fBmanifest\fR. Class action scripts that install and remove service manifests
35 are included in the packaging subsystem. When \fBpkgadd\fR(8) is invoked, the
36 service manifest is imported.
37 .sp
38 .LP
39 When \fBpkgrm\fR(8) is invoked, instances in the manifest that are disabled
40 are deleted. Instances in the manifest that are online or degraded are disabled
41 first and then deleted. Any services in the manifest with no remaining
42 instances are also deleted.
43 .sp
44 .LP
45 If the \fB-R\fR option is supplied to \fBpkgadd\fR(8) or \fBpkgrm\fR(8), the
46 actions described in this section will be done when the system is next rebooted
47 with that alternate root path.
48 .SS "Stability Declarations"
49 .sp
50 .LP
51 Each service group and each property group delivered in a manifest should
52 declare a stability level based on \fBattributes\fR(5) definitions. With
53 knowledge of the stability level, an application developer can determine the
54 likelihood that feature development based on the existence or components of a
55 service or object is likely to remain functional across a release boundary.
56 .sp
57 .LP
58 In an \fBsmf\fR(5) context, the stability value also identifies the expected
59 scope of the changes to properties within the property group across a release
60 boundary for the service, which can include patches for that service. The
61 following two sections discuss this in more detail.
62 .SS "Property Overrides"
63 .sp
64 .LP
65 The \fBservice_bundle\fR(4) document type definition includes an override
66 attribute that is applicable to each property in a service manifest. If set to
67 \fBtrue\fR, the attribute instructs \fBsvccfg\fR(8) and other manifest import
68 tools to replace the current value of a property in the repository with the one
69 from the manifest. If the override attribute is absent or present but set to
70 \fBfalse\fR, the current value in the repository is preserved.
71 .sp
72 .LP
73 Property groups declared as Stable do not contain override attributes on
74 enclosed properties. Property groups declared as Evolving do so only to correct
75 an erroneous setting. Property groups declared as Unstable can contain
76 overrides on any property. The exception to this behavior is for the stability
77 property itself, which can be modified to identify incipient change to the
78 interface presented by the service.
79 .SS "Property Group Deletion"
80 .sp
81 .LP
82 The \fBservice_bundle\fR(4) document type definition includes a delete
83 attribute, applicable to each property group in a service manifest. If set to
84 \fBtrue\fR, the delete attribute instructs \fBsvccfg\fR(8) and other manifest
85 import tools to delete this property group from the repository. If the delete
86 attribute is absent or present but set to \fBfalse\fR, the property group in
87 the repository is preserved.
88 .sp
89 .LP
90 Property groups declared as Stable or Evolving are not deleted. Property groups
91 declared as Unstable can be deleted across any release boundary.
92 .SS "Profile Application"
93 .sp
94 .LP
95 The first time the existence of each of the three service profiles listed below
96 is detected, \fBsvc.startd\fR(8) automatically applies the profile.
97 .sp
98 .in +2
99 .nf
100 /var/svc/profile/generic.xml
101 /var/svc/profile/platform.xml
102 /var/svc/profile/site.xml
104 .in -2
108 The \fBsvc:/smf/manifest\fR service is used in a similar fashion.
111 Additional service profiles that characterize the activation of various groups
112 of service instances might be present in \fB/var/svc/profile\fR. None of the
113 \fB/var/svc/profile\fR profiles are automatically applied to the repository. A
114 profile can be manually applied or re-applied using \fBsvccfg\fR(8).
115 .SH SEE ALSO
118 \fBpkgadd\fR(8), \fBpkgrm\fR(8), \fBsvcadm\fR(8), \fBsvccfg\fR(8),
119 \fBsvc.startd\fR(8), \fBlibscf\fR(3LIB), \fBservice_bundle\fR(4),
120 \fBattributes\fR(5), \fBsmf\fR(5), \fBsmf_security\fR(5)
121 .SH NOTES
124 The present version of \fBsmf\fR(5) does not support multiple repositories.