9 Legend

 • 

20.4K Posts

November 10th, 2009 10:00

let me warn you that i am not a bash guru so this is very crude, hopefully you find it useful :)

modify PATH, email for your environment, to run this file:

sh myscript.sh

#!/bin/bash
PATH=$PATH:/opt/emc/SYMCLI/V7.0.0/bin
 
check_fa_login ()
{
rm no_login.out &> /dev/null
symmask list logins -sid $1 -dir ALL -p ALL | grep Fibre > login.out
 
while read line
do
 array[$i]=${line}
 let i=${i}+1
done < login.out
 
count=0
while [ $count -le `cat login.out | wc -l` ]
do
        login_status=`echo ${array[$count]} |awk '{print $6}'`
        fabric_status=`echo ${array[$count]} |awk '{print $7}'`
        if [[ "$login_status" == "No" && "$fabric_status" == "Yes" ]]
        then
        echo ${array[$count]} |awk '{print $3}'>> no_login.out
        fi
   count=$[$count+1]
done
 
if [ -e no_login.out ]
then
cat no_login.out |  mail -s "Hosts not logged-in" bhat@microsoft.com
fi
}
 
check_failed_disk ()
{
 
symdisk -sid $1 list -failed > failedisk.out 2>&1
 
if [ $? == 0 ]
then
cat failedisk.out |  mail -s "Failed disk on array $1" bhat@microsoft.com
fi
}
 
 
check_fa_login $1
check_failed_disk $1

4 Operator

 • 

2.1K Posts

October 30th, 2009 11:00

I think he is referring to a "custom" health check that would use Solutions Enabler to check and confirm key points about the health of the system.

This could certainly be done, but I don't have anything that could be reused. We use ControlCenter to monitor the health of our Symms.

124 Posts

October 31st, 2009 06:00

Yes Allen, you are spot on in terms of what i meant. Normally we don't have access to symwin so cannot use that for health monitoring.

4 Operator

 • 

2.8K Posts

October 31st, 2009 14:00

Bhat I guess the best answer is "it depends" :-)

If you trust the microcode, you don't need a "health check" script. The code will find any issue and report it to EMC. You'll simply hear an EMC CE knocking on your door. Eventually with a drive (or a board) :-)

If you have specific issues that want to check, simply tell us what you want to check and we'll help you in writing a simple monitoring script :-)

124 Posts

November 1st, 2009 20:00

Hi Stefano..
Thanks for the help offered .
I was looking at some script which would give me some sort of breif overview of what is happening on my SYMM...
Like am looking at some kind of script which would atlease provide me an info on the srdf state of the devices, in case any of the diskgroups/devices have gone into suspended or partial state for any reason, also to check the FA logins to see if any HBA is not logged in to the FA as compared to last time to have a clean environment and few commands on disk usage , what is unmapped and what is the total unused storage available on the symm or any symevent generated.

9 Legend

 • 

20.4K Posts

November 2nd, 2009 20:00

2. One has already been done called SymmPit. Its like
a mini EMC Grab and the output can be imported to
XLS.


must be EMC intranet ? Can't get to it.

Message was edited by:
Stefano Del Corno

124 Posts

November 2nd, 2009 23:00

Hi Greg,
Thanks for your inputs, but still am not able to access the below link..
seems Intranet site .. checked on google :)


Message was edited by:
Bhat

Message was edited by:
Stefano Del Corno

4 Operator

 • 

2.8K Posts

November 3rd, 2009 09:00

Greg this is the external area of EMC support Forums.

1) customers aren't allowed to run software on service processor
2) customers don't have access to CS websites

Please drop me a mail and I'll explain you why I have to modify your replies.

124 Posts

November 4th, 2009 04:00

So was that something, i cannot run on the SYMM or I can't have access to the script ?

4 Operator

 • 

2.8K Posts

November 4th, 2009 11:00

You -as a beloved EMC customer- can't run your software (either scripts or application) on the Service Processor. And as a side effect (since you can't log into EMC network) you can't obtain the script (that's however supposed to be running on the Service Processor).

124 Posts

November 10th, 2009 03:00

I understand, but is there anyway, i can get some help for the script creation using simple symcli commands ?

9 Legend

 • 

20.4K Posts

November 10th, 2009 04:00

so you just want to capture output of specific commands and if they return certain output, alert you via email ? For example output from this command:

$ symdisk -sid 0123 list -failed
 
Symmetrix ID                 : 0000000000123
Disks Selected               : 1
 
                                                        Capacity(MB)
Ident  Symb Int TID Vendor     Type       Hypers   Total    Free    Actual
------ ---- --- --- ---------- ---------- ------ -------- -------- --------
DF-16D 16D    D   9 SEAGATE    CH146LF        64   139814    14235   140014


since you will be maintaining this script, what do you prefer to use bash/perl ?

124 Posts

November 10th, 2009 04:00

Yes, dynamox, thats exactly what i need to do, create a script with few basic symcli commands and capture the data/output and have it on my email as some kind of daily check report.

Just for e.g
symmask -sid xyz list logins... to give me an o/p which will have any wwn not logged in to FA but yes on fabric

I think bash would be better, since i got some idead about it.

Thanks so much for putting your time on this :)

124 Posts

November 11th, 2009 23:00

Thanks a ton dynamox, this looks good, will check in my environment and let you know how it goes, thanks very much again for taking timeout for this.

1 Message

November 28th, 2010 22:00

I would like to perform a Health Check Status of the Box, i.e: Power Supply, Batteries, Controllers, Front and Back End, Disks, memories and so on...

By symcli, to confirm that Hardware Staff performed the Service and to ensure if I have any other related issues into the Box, to ensure if I have any others problem putting my business into risks....

I need to ensure it by soft way...

Best Regards,

Anderson Daniel

No Events found!

Top