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 2008 Sun Microsystems, Inc. All rights reserved. 25 # Use is subject to license terms. 26 # 27 #ident "@(#)probe_SAA.ksh 1.8 08/07/21 SMI" 28 # 29 30 PERFORM_REAL_MONITORING=0 31 32 typeset opt 33 34 while getopts 'R:G:P' opt 35 do 36 case "$opt" in 37 R) RESOURCE=$OPTARG;; 38 G) RESOURCEGROUP=$OPTARG;; 39 P) PERFORM_REAL_MONITORING=1;; 40 *) exit 1;; 41 esac 42 done 43 44 . `dirname $0`/../etc/config 45 . `dirname $0`/functions 46 47 validate_options 48 49 debug_message "Method: `basename $0` - Begin" 50 $SET_DEBUG 51 52 validate 53 54 if [ "${rc_validate}" -ne 0 ] 55 then 56 debug_message "Method: `basename $0` - End (Exit 100)" 57 exit 100 58 fi 59 60 get_SAA_version 61 62 if [ "${saa_version}" = "6.2" ]; then 63 check_DB_SAA 64 else 65 if [ -z "$use_dce" ]; then 66 log_message err "Error: Can not determine SAA version!" 67 debug_message "Method: `basename $0` - End (Exit 100)" 68 exit 100 69 fi 70 71 if [ "$use_dce" -eq 1 ]; then 72 check_dce 73 if [ "${rc_check_dce}" -ne 0 ] 74 then 75 debug_message "Method: `basename $0` - End (Exit 100)" 76 exit 100 77 fi 78 fi 79 80 check_SAA 81 fi 82 83 if [ "${rc_check_SAA}" -ne 0 ] 84 then 85 debug_message "Method: `basename $0` - End (Exit 100)" 86 exit 100 87 fi 88 89 debug_message "Method: `basename $0` - End (Exit 0)" 90 exit 0 91