ADSM-L

Re: Check for Process

2001-10-11 15:38:46
Subject: Re: Check for Process
From: Bill Maloney <bmaloney AT DNDCONSULT DOT COM>
Date: Thu, 11 Oct 2001 15:21:04 -0400
FYI..
 
To weed out the grep process:
 
ps -eaf | grep dsmserv | grep -v grep | wc -l
 
 

        -----Original Message----- 
        From: Charles Anderson 
        Sent: Thu 10/11/2001 2:59 PM 
        To: ADSM-L AT VM.MARIST DOT EDU 
        Cc: 
        Subject: Re: Check for Process
        
        

        Geoffrey,
        
        here ya go in bash ( I'm afraid I'm NT illiterate, so I dunno
how much help this will be )
        -Ed Anderson
        
        #!/usr/local/bin/bash
        # BEGIN  /root/bin/runTSMSERVyoubastard.bash
        #===============
        # Check for dsmserv running on solaris  / True SysV
        #===============
        
        DATE=`date`
        PATHTODSMSERV="/opt/tivoli/tsm/server/bin/dsmserv"
        ISRUNNING=`ps -aef | grep dsmserv | wc -l`
         # Should be 2, one for the real process and one for the "grep
dsmserv" process
        
        if ( "$ISRUNNING == "2" ); then
           exit
        else
           nohup $PATHTODSMSERV
           mail -s "TSM SERVER WAS RESTARTED ON $DATE"
your-address AT your.domain DOT com [email protected]
        fi  
        
        #END
        
        add this to your crontab for the root user
        1  16-7   *  *  *  /root/bin/runTSMSERVyoubastard.bash
        
        short sweet and to the point,
        ed
        
        
        >>> GEOFFREY.L.GILL AT SAIC DOT COM 10/11/01 01:47PM >>>
        I'd like to know if anyone has a script that will do the
following. Cron
        would check once an hour from 4PM to 7 AM and see if the TSM
server is up
        and running. If not to restart it. I had a problem last night
and the
        operators didn't check backups for 6 hours and most were missed
because TSM
        crashed.
        
        I'm sure this is easy to do, but my brain is mush from migrating
TSM to a
        different production server and upgrading to 4.2.1. After the
upgrade it
        crashed so most backups were missed. I can't erly on operations
to check
        backups, even though they're supposed to.
        
        Geoff Gill
        TSM Administrator
        NT Systems Support Engineer
        SAIC
        E-Mail:   gillg AT saic DOT com
        Phone:  (858) 826-4062
        Pager:   (888) 997-9614
        

<Prev in Thread] Current Thread [Next in Thread>