Ticket #675: 190

File 190, 21.8 KB (added by dlove, 11 years ago)
Line 
1#!/bin/sh
2#
3#
4# SGE/SGEEE startup script
5#
6# (c) 2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.
7#
8# See usage via the -help parameter
9#
10# Unix commands which may be used in this script:
11#    cat ls grep sed
12#
13# This script requires the script $SGE_ROOT/util/arch
14#
15
16PATH=/bin:/usr/bin:/sbin:/usr/sbin
17
18#---------------------------------------------------------------------------
19# The following lines provide the necessary info for adding a startup script
20# according to the Linux Standard Base Specification (LSB) which can
21# be found at:
22#
23#    http://www.linuxfoundation.org/spec/booksets/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html
24#
25### BEGIN INIT INFO
26# Provides:       gridengine.augsburg01
27# Required-Start: $network $remote_fs
28# Should-Start:   network-remotefs
29# Required-Stop:
30# Default-Start:  3 5
31# Default-Stop: 0 1 2 6
32# Description:  start GridEngine execd, qmaster, shadowd
33### END INIT INFO
34#---------------------------------------------------------------------------
35## set -x
36
37SGE_ROOT=/opt/grid; export SGE_ROOT
38SGE_CELL=default; export SGE_CELL
39SGE_CLUSTER_NAME=augsburg01; export SGE_CLUSTER_NAME
40
41unset SGE_EXECD_PORT
42unset SGE_QMASTER_PORT
43
44# obsolete environment variables
45unset CODINE_ROOT GRD_ROOT COD_CELL GRD_CELL
46#---------------------------------------------------------------------------
47# usage
48#
49usage()
50{
51cat <<USAGE
52usage: $0 [ACTION] [SERVICE] [OPTIONS]
53
54GridEngine start/stop script.
55
56action:
57  start           start qmaster, scheduler, execution daemons if applicable
58  stop            shutdown local GridEngine processes and jobs
59  softstop        shutdown local GridEngine processes, but no jobs
60  restart         a 'softstop' followed by a 'start'
61  force-reload    identical to 'restart'
62  status          query status of GridEngine processes [unimplemented]
63
64service:
65  -execd          only start/stop execution daemon
66  -qmaster        only start/stop qmaster and scheduler (if applicable)
67  -shadowd        only start/stop shadowd (if applicable)
68  -migrate        shutdown qmaster/scheduler if it is running on another host
69                  and restart it on this host.
70                  Migration only works if this host is an admin host
71options:
72  -nosmf          suppress SMF (Service Management Facility)
73
74When a service is specified, the default action is 'start'.
75When no service is specified, the default is to start/stop all components.
76
77USAGE
78   exit ${1:-1}
79}
80
81#------------------------------------------------------------------------------
82# handle command-line args - they may appear in any order
83request=start   # no explicit request corresponds to 'start'
84service=all     # default is to start/stop all components
85execd=true
86qmaster=true
87shadowd=true
88withSMF=true    # enable/disable SMF
89
90# disable SMF if the corresponding programs/files do not exist
91[ -f /usr/bin/svcs -a -f /lib/svc/share/smf_include.sh ] || withSMF=false
92
93# max of request, service, nosmf
94[ "$#" -le 3 ] || usage
95for i
96do
97   case "$i" in
98   -h | -help )
99      usage
100      ;;
101
102   -all | all )      # do not change anything
103      service=all
104      ;;
105
106   start | stop | softstop | force-reload | restart | status )
107      request=$i
108      ;;
109
110   reload | try-restart )
111      # LSB compliant exit status - unimplemented feature
112      echo "unimplemented feature '$i'"
113      echo
114      usage 3
115      ;;
116
117   -execd | execd )
118      service=execd
119      execd=true
120      qmaster=false
121      shadowd=false
122      ;;
123
124   -qmaster | qmaster )
125      service=qmaster
126      execd=false
127      qmaster=true
128      shadowd=false
129      ;;
130
131   -shadowd | shadowd )
132      service=shadowd
133      execd=false
134      qmaster=false
135      shadowd=true
136      ;;
137
138   -migrate | migrate )
139      service=migrate
140      execd=false
141      qmaster=true
142      shadowd=false
143      ;;
144
145   -nosmf | nosmf )
146      withSMF=false
147      ;;
148
149   *)
150      usage 3
151      ;;
152   esac
153done
154
155#------------------------------------------------------------------------------
156
157# wait for SGE_ROOT to become available
158count=0
159while [ ! -d "$SGE_ROOT" -a $count -le 120 ]; do
160   count=$(expr $count + 1)
161   sleep 1
162done
163
164if [ ! -d "$SGE_ROOT" ]; then
165   echo "'\$SGE_ROOT=$SGE_ROOT' not available"
166   exit # LSB compliant exit status - program is not installed
167fi
168if [ ! -x $SGE_ROOT/util/arch ]; then
169   echo "'$SGE_ROOT/util/arch' not available"
170   exit # LSB compliant exit status - program not installed
171fi
172
173# it is useful to export the architecture
174SGE_ARCH=$($SGE_ROOT/util/arch); export SGE_ARCH
175
176# general error
177if [ -z "$SGE_ARCH" ]; then
178   echo "cannot determine SGE_ARCH"
179   exit 1
180fi
181
182
183common_dir=$SGE_ROOT/$SGE_CELL/common
184if [ ! -d "$common_dir" ]; then
185   echo "cannot locate '\$SGE_ROOT/\$SGE_CELL/common' ($common_dir)"
186   exit # LSB compliant exit status - program not configured
187fi
188if [ ! -s $common_dir/bootstrap ]; then
189   echo "cannot locate '$common_dir/bootstrap'"
190   exit # LSB compliant exit status - program not configured
191fi
192
193# source optional configuration file(s) for customized environment
194for i in $common_dir/site_settings
195do
196   [ -r $i ] && . $i
197done
198
199# ensure we have the correct cluster name
200# it is useful to export the cluster name
201if [ -z "$SGE_CLUSTER_NAME" -a -r "$common_dir/cluster_name" ]; then
202   SGE_CLUSTER_NAME=$(cat $common_dir/cluster_name 2>/dev/null)
203fi
204: ${SGE_CLUSTER_NAME:=unknown}
205export SGE_CLUSTER_NAME
206
207# library path setting for architectures where RUNPATH is not supported
208case $SGE_ARCH in
209sol*|lx*|hp11-64)
210   ;;
211*)
212   shlib_path_name=$($SGE_ROOT/util/arch -lib)
213   old_value=$(eval echo '$'$shlib_path_name)
214   if [ x$old_value = x ]; then
215      eval $shlib_path_name=$SGE_ROOT/lib/$ARCH
216   else
217      eval $shlib_path_name=$old_value:$SGE_ROOT/lib/$ARCH
218   fi
219   export $shlib_path_name
220   ;;
221esac
222
223#---------------------------------------------------------------------------
224# DetectSMFService - sets SMFservice to a mask maching the name
225# $1 ... name
226#
227DetectSMFService()
228{
229   name=$1
230   SMFservice=""
231
232   [ "$withSMF" = true ] || return
233
234   . /lib/svc/share/smf_include.sh
235   smf_present || return
236
237## already done above
238##    # Check we have cluster_name file
239##    if [ ! -r "$SGE_ROOT/$SGE_CELL/common/cluster_name" ]; then
240##       echo "Error: could not find $SGE_ROOT/$SGE_CELL/common/cluster_name!"
241##       exit $SMF_EXIT_ERR_CONFIG
242##    fi
243##    # Cluster name must be unique
244##    SGE_CLUSTER_NAME=$(cat $SGE_ROOT/$SGE_CELL/common/cluster_name 2>/dev/null)
245
246   SMFservice="svc:/application/sge/$name:$SGE_CLUSTER_NAME"
247
248   if [ -n "$SMF_FMRI" -a "$SMF_FMRI" != "$SMFservice" ]; then
249      # Someone is trying to fool us
250      echo "Error: $SMFservice does not match FMRI $SMF_FMRI provided by SMF!"
251      echo "Check that service instance $SGE_CLUSTER_NAME exists on your system"
252      exit $SMF_EXIT_ERR_CONFIG
253   fi
254
255   # Check if service exists in the system
256   /usr/bin/svcs $SMFservice > /dev/null 2>&1 || SMFservice=""
257}
258
259#------------------------------------------------------------------------------
260# Shutdown
261# Send SIGTERM to process name $1 with pid in file $2
262#
263# running "stop" on a service already stopped or not running is considered
264# a success
265#
266Shutdown()
267{
268   daemon=$1
269   pidfile=$2
270
271   if [ -f $pidfile ]; then
272      pid=$(cat $pidfile)
273      count=0
274      retries=20
275      while [ $count -lt $retries ]; do
276         $utilbin_dir/checkprog $pid $daemon >/dev/null 2>&1
277         if [ $? -eq 0 ]; then
278            # keep killing (qmaster) so that child processes get killed
279            kill -TERM $pid
280         else
281            return 0
282         fi
283         sleep 2
284         count=$(expr $count + 1)
285      done
286      # still alive? really kill it
287      kill -KILL $pid
288      return $?
289   fi
290}
291
292#---------------------------------------------------------------------------
293# GetPathToBinaries
294#    echo the name of the binary_path on this system
295#    The check is fulfilled when the "qstat" binary is accessible
296#    echo "none" if the binary path cannot be determined
297GetPathToBinaries()
298{
299   cfgname=$common_dir/bootstrap
300   element=binary_path
301   value=none
302
303   if [ -f $cfgname ]; then
304      value=$(sed -ne "s/^$element *//p" $cfgname 2>/dev/null)
305      if [ -f $value/qstat ]; then
306         :
307      elif [ -f $value/$SGE_ARCH/qstat ]; then
308         value=$value/$SGE_ARCH
309      else
310         value=none
311      fi
312   fi
313
314   echo $value
315}
316
317#---------------------------------------------------------------------------
318# GetPathToUtilbin
319#    echo the path to the utilbin/ binaries
320#    The check is fulfilled when the "gethostname" binary is accessible
321#    echo "none" if the binary path cannot be determined
322GetPathToUtilbin()
323{
324   value=$SGE_ROOT/utilbin/$SGE_ARCH
325   [ -f $value/gethostname ] || value=none
326   echo $value
327}
328
329
330#------------------------------------------------------------------------------
331# ExecdSpoolDir
332# get the execution daemon spooling dir from configuration
333# precedence:
334# - local config has precedence over global cluster config
335# - fallback to reading the configuration file directly if necessary
336ExecdSpoolDir()
337{
338   element=execd_spool_dir
339   value="";
340
341   # if qmaster is running, use qconf to get the information
342   for cfgname in $UQHOST global; do
343     value=$($bin_dir/qconf -sconf $cfgname 2>/dev/null | sed -ne "s/^$element *//p")
344     [ -n "$value" ] && break
345   done
346
347   # backup method, check the files directly
348   if [ -z "$value" ]; then
349      for cfgname in $common_dir/local_conf/$HOST $common_dir/configuration
350      do
351         value=$(sed -ne "s/^$element *//p" $cfgname 2>/dev/null)
352         [ -n "$value" ] && break
353      done
354   fi
355
356   [ -n "$value" ] && echo "$value/$UQHOST" || echo ""
357}
358
359#---------------------------------------------------------------------------
360# QmasterSpoolDir
361#    Return the qmaster spool directory
362#    - do directly since the qmaster may not be running
363#
364QmasterSpoolDir()
365{
366   echo $(sed -ne "s/^qmaster_spool_dir *//p" $common_dir/bootstrap 2>/dev/null)
367}
368
369#---------------------------------------------------------------------------
370# CheckHostInFile
371#    If the $HOST exists in the file $common_dir/$1
372#    echo "true" or "false"
373#
374CheckHostInFile()
375{
376   grep -i $HOST $common_dir/$1 >/dev/null 2>&1 && echo true || echo false
377}
378
379
380#------------------------------------------------------------------------------
381# ShouldRunExecd
382#    if $isQmasterHost = true, or $isShadowHost = true, then check in the
383#    qmaster spool directory if the hostname given in $HOST is
384#    an execution host (by verifying the exec host file).
385#
386#    The purpose of the check is to avoid to start an execution daemon
387#    if this is a qmaster/shadow machine but should not run an execution
388#    daemon
389#
390#    Only on a qmaster host (and hopefully on the shadow host)
391#    can we be sure of access to the qmaster spool directory
392#
393#    If this host is *not* a qmaster/shadow machine, then always execute
394#
395ShouldRunExecd()
396{
397   value=true
398   if [ $isQmasterHost = true -o $isShadowHost = true ]; then
399      /bin/ls $qmaster_spool_dir/exec_hosts/${HOST}* >/dev/null 2>&1 || value=false
400   fi
401   echo $value
402}
403
404#---------------------------------------------------------------------------
405# PingExecd
406# checks if sge_execd is running on $HOST
407# In error case the sge_execd didn't start, silently echo "true" or "false"
408#
409# $1 = retries
410PingExecd()
411{
412   retries=${1:-20}
413   value=false
414
415   # the port number to check
416   port=${SGE_EXECD_PORT:-$($utilbin_dir/getservbyname -number sge_execd 2>/dev/null)}
417
418   count=0
419   while [ $count -lt $retries ]; do
420      $bin_dir/qping -info $HOST $port execd 1 > /dev/null 2>&1
421      if [ $? -eq 0 ]; then
422         value=true
423         break
424      else
425         sleep 1
426         count=$(expr $count + 1)
427      fi
428   done
429
430   echo $value
431}
432
433#---------------------------------------------------------------------------
434# PingQmaster
435# checks if sge_qmaster is running
436# In error case the sge_qmaster didn't start, silently
437# echo "true" or "false"
438#
439# $1 = retries
440# $2 = check (dead | alive)
441PingQmaster()
442{
443   retries=${1:-30}
444   check=${2:-alive}
445   value=false
446   act_qmaster_host=$(cat $common_dir/act_qmaster)
447
448   # the port number to check
449   port=${SGE_QMASTER_PORT:-$($utilbin_dir/getservbyname -number sge_qmaster 2>/dev/null)}
450
451   count=0
452   while [ $count -lt $retries ]; do
453      $bin_dir/qping -info $act_qmaster_host $port qmaster 1 > /dev/null 2>&1
454      ret=$?
455
456      if [ $check = dead ]; then
457         if [ $ret -ne 0 ]; then
458            value=true   # is dead
459            break
460         fi
461         sleep 2
462      else
463        if [ $ret -eq 0 ]; then
464           value=true   # is alive
465           break
466        fi
467        sleep 2
468
469        # waiting for qmaster ... act_qmaster_host may change
470        act_qmaster_host=$(cat $common_dir/act_qmaster)
471      fi
472      count=$(expr $count + 1)
473   done
474
475   echo $value
476}
477
478#---------------------------------------------------------------------------
479# MAIN Procedure ... initialize variables
480
481bin_dir=$(GetPathToBinaries)
482if [ "$bin_dir" = none ]; then
483   echo "can't determine path to GridEngine binaries"
484   exit # LSB compliant exit status - program is not installed
485fi
486
487utilbin_dir=$(GetPathToUtilbin)
488if [ "$utilbin_dir" = none ]; then
489   echo "can't determine path to GridEngine utility binaries"
490   exit # LSB compliant exit status - program is not installed
491fi
492
493
494# HOST is the aliased name (SGE name)
495# UQHOST is the local host name (unqualified name)
496HOST=$($utilbin_dir/gethostname -aname)
497UQHOST=$(echo $HOST | sed -e 's/\..*//')
498if [ -z "$UQHOST" ]; then
499   echo "cannot resolve local hostname"
500   exit 1
501fi
502
503qmaster_spool_dir=$(QmasterSpoolDir)
504if [ -z "$qmaster_spool_dir" ]; then
505   echo "cannot get qmaster spool directory"
506fi
507
508# boolean value (true|false) for the following:
509isQmasterHost=$(CheckHostInFile act_qmaster)
510isShadowHost=$(CheckHostInFile  shadow_masters)
511
512case "$request" in
513start)
514
515   if [ $qmaster = true ]; then
516
517      # if service tags are enabled
518      if [ $($SGE_ROOT/util/sgeST/sge_st enabled) = true ]; then
519         $SGE_ROOT/util/sgeST/sge_st register
520      fi
521
522      #
523      # attempt migration if -migrate was requested
524      # or when this host isPrimaryQmasterHost
525      #
526      isPrimaryQmasterHost=$(CheckHostInFile primary_qmaster)
527      act_qmaster_host=$(cat $common_dir/act_qmaster)
528
529      if [ $isQmasterHost = true ]; then
530         if [ $service = migrate ]; then
531            echo "   qmaster already running on this host. Will not migrate qmaster."
532            exit 1
533         fi
534      elif [ $service = migrate -o $isPrimaryQmasterHost = true ]; then
535         echo "   shutdown qmaster on host '$act_qmaster_host' ..."
536
537         qconf_output=$($bin_dir/qconf -ks 2>&1 | grep denied)
538         if [ -n "$qconf_output" ]; then
539            echo "   denied: host '$HOST' is no admin host."
540            exit 1
541         fi
542         $bin_dir/qconf -km 2>&1 > /dev/null
543
544         if [ $(PingQmaster 30 dead) = false ]; then
545            # qmaster is not dead (still running)
546            echo "   qmaster on host '$act_qmaster_host' still alive. Cannot migrate qmaster."
547            exit 1
548         fi
549
550         count=0
551         retries=10
552         status=0
553         while [ $count -lt $retries ]; do
554            if [ -f $qmaster_spool_dir/lock ]; then
555               status=1
556               break
557            fi
558            sleep 3
559            count=$(expr $count + 1)
560         done
561
562         if [ $status -eq 0 ]; then
563            # old qmaster did not write lock file
564            echo "   old qmaster did not write lock file. Cannot migrate qmaster."
565            echo "   Please verify that qmaster on host '$act_qmaster_host' is down"
566            echo "   and that the lock file in qmaster spool directory is readable."
567            exit 1
568         fi
569
570         # this host is the new qmaster
571         isQmasterHost=true
572      fi
573
574      #
575      # start qmaster
576      #
577      if [ $isQmasterHost = true ]; then
578
579         DetectSMFService qmaster
580         if [ -z "$SMF_FMRI" -a -n "$SMFservice" ]; then
581            # use SMF
582            echo "   starting sge_qmaster"
583            /usr/sbin/svcadm enable -st $SMFservice
584         else
585            # For -migrate with SMF, qmaster is not yet set for SMF start (2nd)
586            echo "   starting sge_qmaster"
587            $bin_dir/sge_qmaster $SGE_QMASTER_ARGS
588
589            if [ $(PingQmaster 30 alive) = false ]; then
590               echo
591               echo "sge_qmaster didn't start - please check the messages file"
592               echo
593            fi
594            ## skip /var/lock/subsys, we have two services
595            ## [ $? -eq 0 -a -d /var/lock/subsys ] && touch /var/lock/subsys/sgemaster >/dev/null 2>&1
596         fi
597      else
598         echo "   qmaster running ... $act_qmaster_host"
599      fi
600   fi
601
602   #
603   # start shadowd
604   #
605   if [ $shadowd = true -a $isShadowHost = true ]; then
606
607      # check if already running
608      for pidfile in \
609         $qmaster_spool_dir/shadowd_$UQHOST.pid \
610         $qmaster_spool_dir/shadowd_$HOST.pid \
611         ;
612      do
613         if [ -f $pidfile ]; then
614            $utilbin_dir/checkprog $(cat $pidfile) sge_shadowd >/dev/null 2>&1
615            if [ $? -eq 0 ]; then
616               shadowd=false
617               break
618            fi
619         fi
620      done
621
622      if [ $shadowd = true ]; then
623         echo "   starting sge_shadowd"
624         DetectSMFService shadowd
625         if [ -z "$SMF_FMRI" -a -n "$SMFservice" ]; then
626            # use SMF
627            /usr/sbin/svcadm enable -st $SMFservice
628         else
629            $bin_dir/sge_shadowd  $SGE_SHADOWD_ARGS
630         fi
631      else
632         echo "   found running sge_shadowd - not starting"
633      fi
634   fi
635
636   #
637   # start execd when
638   #  - this script is started with the parameter 'execd'
639   #  - qmaster *is not* running on this host
640   #  - qmaster *is* running on this host *and* there is an exec host config
641   #
642   if [ $execd = true ]; then
643      if [ $service = execd -o $(ShouldRunExecd) = true ]; then
644
645         DetectSMFService execd
646         echo "   starting sge_execd"
647         # use SMF
648         if [ -z "$SMF_FMRI" -a -n "$SMFservice"  ]; then
649            /usr/sbin/svcadm enable -st $SMFservice
650            exit $?
651         else
652            exec 1>/dev/null 2>&1
653            $bin_dir/sge_execd  $SGE_EXECD_ARGS
654
655            # wait for the daemon to come up
656            if [ $(PingExecd 60) = false ]; then
657               echo "   execd did not start in 60 seconds!"
658               exit 1
659            fi
660
661            ## skip /var/lock/subsys, we have two services
662            ## [ $? -eq 0 -a -d /var/lock/subsys ] && touch /var/lock/subsys/sgeexecd 2>/dev/null
663         fi
664      fi
665   fi
666   ;;
667
668stop | softstop)
669
670   #
671   # stop shadowd
672   #
673   if [ $shadowd = true -a $isShadowHost = true ]; then
674      echo "   shutdown sge_shadowd"
675
676      DetectSMFService shadowd
677      if [ -z "$SMF_FMRI" -a -n "$SMFservice" ]; then
678         /usr/sbin/svcadm disable -st $SMFservice
679      else
680         # Send SIGTERM to shadowd
681         for pidfile in \
682            $qmaster_spool_dir/shadowd_$UQHOST.pid \
683            $qmaster_spool_dir/shadowd_$HOST.pid \
684            ;
685         do
686            if [ -f $pidfile ]; then
687               Shutdown sge_shadowd $pidfile
688               break
689            fi
690         done
691      fi
692   fi
693
694   #
695   # stop qmaster
696   #
697   if [ $qmaster = true -a $isQmasterHost = true ]; then
698      echo "   shutdown sge_qmaster"
699
700      DetectSMFService qmaster
701      if [ -z "$SMF_FMRI" -a -n "$SMFservice" ]; then
702         /usr/sbin/svcadm disable -st $SMFservice
703      else
704         # Send SIGTERM to qmaster
705         Shutdown sge_qmaster $qmaster_spool_dir/qmaster.pid
706         ret=$?
707         if [ -f /var/lock/subsys/sgemaster ]; then
708            uid=$($utilbin_dir/uidgid -uid)
709            if [ "$uid" -eq 0 -a $ret -eq 0 ]; then
710               rm -f /var/lock/subsys/sgemaster >/dev/null 2>&1
711            else
712               echo "cannot shutdown sge_qmaster"
713            fi
714         fi
715      fi
716   fi
717
718   #
719   # stop execution daemon
720   #
721   if [ $execd = true ]; then
722      execd_spool_dir=$(ExecdSpoolDir)   # get info before stopping qmaster
723      if [ -z "$execd_spool_dir" ]; then
724         echo "cannot get execd spool directory"
725      else
726         echo "   shutdown sge_execd"
727
728         DetectSMFService execd
729         if [ -z "$SMF_FMRI" -a -n "$SMFservice" ]; then
730            /usr/sbin/svcadm disable -st $SMFservice
731         else
732            # Send SIGTERM to execd
733            Shutdown sge_execd $execd_spool_dir/execd.pid
734            ret=$?
735            if [ -f /var/lock/subsys/sgeexecd ]; then
736                uid=$($utilbin_dir/uidgid -uid)
737                if [ "$uid" -eq 0 -a "$ret" -eq 0 ]; then
738                   rm -f /var/lock/subsys/sgeexecd >/dev/null 2>&1
739                else
740                   echo "cannot shutdown sge_execd"
741                fi
742            fi
743         fi
744
745         # terminate all shepherds
746         if [ $request != softstop ]; then
747            for jobid in $(ls $execd_spool_dir/active_jobs 2>/dev/null); do
748               Shutdown sge_shepherd $execd_spool_dir/active_jobs/$jobid/pid
749            done
750         fi
751      fi
752   fi
753   ;;
754
755force-reload | restart)
756   ## Stop the service (if running) and start anew
757   $0 softstop $service
758   $0 start    $service
759   ;;
760
761status)
762   ## Check status with checkproc(8), if process is running
763   ## checkproc will return with exit status 0.
764
765   # Status has a slightly different for the status command:
766   # 0 - service running
767   # 1 - service dead, but /var/run/  pid  file exists
768   # 2 - service dead, but /var/lock/ lock file exists
769   # 3 - service not running
770
771   # NOTE: checkproc returns LSB compliant status values.
772
773   check=$service
774   # default - check all services
775   if [ -z "$check" -o "$check" = all ]; then
776      check="execd shadowd qmaster"
777   fi
778
779##    for service in $check; do
780##      echo -n "Checking for Grid Engine $service"
781##      checkproc $bin_dir/sge_$service
782##      rc_status -v
783##      rc_reset
784##    done
785   echo "this LSB compliant request is not supported '$request'"
786   exit 3
787   ;;
788
789*)
790   echo "unknown request '$request'"
791   usage 3
792   ;;
793
794esac
795
796# ----------------------------------------------------------------- end-of-file