A P P E N D I X  D

cpudiagd Startup Script

This appendix provides the /etc/init.d/cpudiagd startup script.

#!/sbin/sh
#
#
# Copyright 2003 Sun Microsystems, Inc.  All rights reserved.
# Use is subject to license terms.
#
#ident  "@(#)init.cpudiagd  1.4  03/03/22  SMI"
 
isalist=`/usr/bin/isalist`
DAEMON=
 
#
# Automatically enabled on sparcv9+vis2 arch (supported by UltraSparc-III )
#
 
case "$isalist" in
        *sparcv9+vis2*)
                DAEMON=/usr/lib/sparcv9/cpudiagd
                ;;
        *)
                DAEMON=
                ;;
esac
 
case "$1" in
'start')
        if [ -x "$DAEMON" ];
        then
                echo 'Starting cpudiagd ... \c'
                $DAEMON -i
                echo 'done.'
        fi
        ;;
'stop')
         /usr/bin/pkill -x -u 0 '(cputst|cpudiagd)'
        ;;
*)
        echo "Usage: $0 { start | stop }"
        exit 1
        ;;
esac
exit 0