1 #!/usr/bin/ksh 2 # 3 # CDDL HEADER START 4 # 5 # The contents of this file are subject to the terms of the 6 # Common Development and Distribution License (the License). 7 # You may not use this file except in compliance with the License. 8 # 9 # You can obtain a copy of the license at usr/src/CDDL.txt 10 # or http://www.opensolaris.org/os/licensing. 11 # See the License for the specific language governing permissions 12 # and limitations under the License. 13 # 14 # When distributing Covered Code, include this CDDL HEADER in each 15 # file and include the License file at usr/src/CDDL.txt. 16 # If applicable, add the following below this CDDL HEADER, with the 17 # fields enclosed by brackets [] replaced with your own identifying 18 # information: Portions Copyright [yyyy] [name of copyright owner] 19 # 20 # CDDL HEADER END 21 # 22 23 # 24 # Copyright 2007 Sun Microsystems, Inc. All rights reserved. 25 # Use is subject to license terms. 26 # 27 28 #ident "@(#)probe_smf_pgs.ksh 1.6 07/06/06 SMI" 29 30 # This method is called by the optional probe script of the smf method 31 # 32 # Method for the PostgresSql agents smf manifest it is called from the control script 33 # only if it is an smf probe and the project in the smf serfice is not :default 34 # This assures, that most of the probe is running under the correct project. 35 # 36 # It is started with 1 parameter 37 # 38 # $1 ist the SMF_FMRI identifier which specifies the smf service 39 # 40 41 MYNAME=`basename ${0}` 42 MYDIR=`dirname ${0}` 43 44 if [ -f /lib/svc/share/smf_include.sh ] 45 then 46 . /lib/svc/share/smf_include.sh 47 fi 48 49 . ${MYDIR}/../etc/config 50 . ${MYDIR}/../lib/functions_static 51 . ${MYDIR}/functions 52 53 debug_message "Method: ${MYNAME} ${1} - Begin" 54 ${SET_DEBUG} 55 56 # Setting SMF_FMRI 57 58 SMF_FMRI=${1} 59 60 # getting the necessary parameters and setting the variables filled 61 # in from options if it is called via gds 62 63 get_fmri_parameters 64 65 # source the parameter file before the check 66 . ${PARFILE} 67 68 # perform the check 69 check_pgs 70 rc_val=${?} 71 72 debug_message "Method: ${MYNAME} ${1} - End" 73 exit ${rc_val} 74 75