Skip Navigation Links | |
Exit Print View | |
![]() |
Oracle Solaris Cluster Data Services Developer's Guide Oracle Solaris Cluster 4.0 |
1. Overview of Resource Management
3. Resource Management API Reference
6. Data Service Development Library
8. Sample DSDL Resource Type Implementation
X Font Server Configuration File
Naming Conventions for Functions and Callback Methods
Validating the Service Before Starting the X Font Server
Starting the Service With svc_start()
Determining the Fault Monitor Action
9. Oracle Solaris Cluster Agent Builder
12. Cluster Reconfiguration Notification Protocol
A. Sample Data Service Code Listings
B. DSDL Sample Resource Type Code Listings
C. Requirements for Non-Cluster-Aware Applications
D. Document Type Definitions for the CRNP
Because the xfnts_start method uses scds_pmf_start() to start the service under the PMF, xfnts_stop uses scds_pmf_stop() to stop the service.
Note - The first call in xfnts_stop is to scds_initialize(), which performs some necessary housekeeping functions. scds_initialize() Function and the scds_initialize(3HA) man page contain more information.
The xfnts_stop method calls the svc_stop() method, which is defined in the xfnts.c file, as follows:
scds_syslog(LOG_ERR, "Issuing a stop request."); err = scds_pmf_stop(scds_handle, SCDS_PMF_TYPE_SVC, SCDS_PMF_SINGLE_INSTANCE, SIGTERM, scds_get_rs_stop_timeout(scds_handle)); if (err != SCHA_ERR_NOERR) { scds_syslog(LOG_ERR, "Failed to stop HA-XFS."); return (1); } scds_syslog(LOG_INFO, "Successfully stopped HA-XFS."); return (SCHA_ERR_NOERR); /* Successfully stopped */
Note the following points about the call in svc_stop() to the scds_pmf_stop() function:
The SCDS_PMF_TYPE_SVC argument identifies the program to stop as a data service application. This method can also stop a fault monitor or some other type of application.
The SCDS_PMF_SINGLE_INSTANCE argument identifies the signal.
The SIGTERM argument identifies the signal to use to stop the resource instance. If this signal fails to stop the instance, scds_pmf_stop() sends SIGKILL to stop the instance, and if that fails, returns with a timeout error. See the scds_pmf_stop(3HA) man page for details.
The timeout value is that of the Stop_timeout property of the resource.
Note - Before it exits, the xfnts_stop method calls scds_close() to reclaim resources that are allocated by scds_initialize(). scds_initialize() Function and the scds_close(3HA) man page contain more information.