499
Using Celerra Command Scripts
Scripting examples
The RECOVERABLE variable contains the following errors to retry
on:
◆
Unable to acquire lock
◆
Resource temporarily unavailable
◆
Unable to connect to host
◆
Socket: All ports in use
◆
Database resource vanished
◆
Connection timed out
◆
NAS_DB locked object is stale
Following is an example of what the RECOVERABLE variable looks
like:
RECOVERABLE="unable to acquire lock|Resource
temporarily unavailable|unable to connect to
host|socket: All ports in use|database resource
vanished|Connection timed out|NAS_DB locked object is
stale".
The res variable contains the command output.
#!/bin/sh
########################################################
# File: nas_cmdrcvr.sh
# Created by: NAS Engineering
# Date: Thursday, May 25, 2006
# Version: 1.0
# Notes:
# 1) script will retry commands for specified period of
time
#2) script will log messages to file only if there's
available disk space
########################################################
NAS_DB=/nas
export NAS_DB
PATH=$PATH:$NAS_DB/bin:$NAS_DB/sbin:/usr/sbin:.
export PATH
RETRIES=60
SLEEPTIME=30
LOGDIR="/home/nasadmin"
LOGFILE="$0.log"
LOGLAST="$0.last"
DISKFULL=98
RECOVERABLE="Resource temporarily unavailable|\
unable to acquire lock|\
Содержание Celerra
Страница 6: ...Celerra Network Server Command Reference Manual 6 Contents...
Страница 10: ...10 Celerra Network Server Command Reference Manual Preface...
Страница 16: ...16 Celerra Network Server Command Reference Manual Overview...
Страница 276: ...276 Celerra Network Server Command Reference Manual The nas Commands...
Страница 347: ...server_devconfig 347 The server Commands server_4 chain 0 chain 16 done server_5 server_5 chain 0 chain 16 done...