SMF Service Management Facility

por | 9 agosto, 2008

Service Management Facilty (SMF)

Service Names

Solaris uses a URI string called an FMRI (Fault Managed Resource Identifier) to identify system objects for which advanced fault and resource management capabilities are provided. Services managed by SMF are assigned FMRI strings prefixed with the scheme name «svc», as shown in the following examples for the Solaris service syslogd(1M):

* svc://localhost/system/system-log:default
* svc:/system/system-log:default
* system/system-log:default

#### SMF #####

-bash-3.00# who -r
. run-level 3 Aug 9 14:43 3 0 S
-bash-3.00# cd /etc/rc3.d/
-bash-3.00# ls -ltr
total 28
-rwxr--r-- 6 root sys 344 Jan 21 2005 S80mipagent
-rwxr--r-- 6 root sys 474 Jan 21 2005 S16boot.server
-rw-r--r-- 1 root sys 1285 Jan 21 2005 README
-rwxr--r-- 6 root sys 5840 Jun 19 2006 S52imq
-rwxr--r-- 5 root sys 824 Aug 16 2006 S84appserv
-rwxr--r-- 6 root sys 1649 Feb 19 07:38 S50apache
lrwxrwxrwx 1 root other 18 Aug 8 21:11 S99nxsensor -> ../init.d/nxsensor


Why SMF is better????
Features Include:

1. Provides service management via service configuration database ( list of services and their various supported methods )

2. Provides legacy rc script support

3. Facilitates service dependencies ( A & B ) Relationships between services. E.J. service B cannot start if service A is not started.

4. * Permits automatic restarts of failed and/or stopped services

5. Provides service status information ( online/offline, dependencies )

6. Causes each defined service to log individually to: /var/svc/log

7. Defines a Fault Management Resource Identifier ( FMRI )

8. Can load mutually exclusive services in parallel ( faster boot )

9. SMF supports multiple instances of services


Service States:

1. Online / Offline
2. legacy_run/maintenance
3. uninitialized/degraded/disabled