This post is more than 5 years old
1 Rookie
•
32 Posts
0
996
January 14th, 2014 08:00
Meta-Hyper-Masking Report
Hello everyone,
We are looking at creating a report for Symm volumes in the following format :
SymID DeviceID Hyper Size No.Of Hypers Masked (Y/N)
Last column is optional.
This report will be used for migration analysis where multiple DMXs/VMAXs will be consolidated into a single large VMAX and we want to make sure we have enough addressable space available on the target FA ports if we do not change the hyper sizes during migration.
Appreciate your help in this !
Regards,
Girish
0 events found
No Events found!


seancummins
2 Intern
•
226 Posts
0
January 14th, 2014 14:00
BTW, if you happen to be using Solaris, you'll need to modify the script a bit, since its grep and awk implementations are limited... you can use sed instead of grep, and nawk instead of awk to achieve the same results:
DELIM="\t"; \
echo "SymID${DELIM}SymDev${DELIM}MemSz${DELIM}#Mems"; \
for SID in 0235 0240; do
symdev -sid $SID list -cyl -meta |sed -n "/^[0-9a-fA-F]\{4\}/p" | nawk -v OFS=$DELIM -v SID=$SID {'print SID,$1,$(NF)/$(NF-1),$(NF-1)'}
symdev -sid $SID list -cyl |sed -n "/^[0-9a-fA-F]\{4\}/p" |sed "/([mM])/d" | nawk -v OFS=$DELIM -v SID=$SID {'print SID,$1,$(NF),"1"'}
done
seancummins
2 Intern
•
226 Posts
0
January 14th, 2014 09:00
Girish,
I'm assuming that by "hypers" you actually mean meta members, and not hypervolumes/splits on physical disks.
The symcfg list output shows the total number of Symm Devices on a given array, including single devs and meta heads & members. If you don't need masking/mapping info, and you don't mind the fact that this counts "overhead" devices like gatekeepers, this is probably fine for your use case.
If you want to see only mapped devices, you can use the "symdev list -firstport" command. This will show all devices that are mapped to an FA port, including single devs, meta head & members.
Thanks,
- Sean
girishp1
1 Rookie
•
32 Posts
0
January 14th, 2014 10:00
Sean,
Yes, by hypers I mean meta-members only.
Symcfg list will not be enough as we need to filter out devices that are not mapped along with their meta members. The logic that I was working on was, a) to have a report in the format I mentioned , b) create a symmaskb report for only those WWNs that are logged in which will give us the device IDs, c) “grep” devices listed in (b) from (a)….and d) add up “no. of hypers” from c) to generate the exact addressable space required.
We have to do this for 10 arrays that we are migrating.
Unless someone on the forum has a better way of doing this analysis ☺
Girish
seancummins
2 Intern
•
226 Posts
0
January 14th, 2014 12:00
Here's a quick & dirty shell script that produces everything except the "Masking (Y/N)" column... you could filter the report to show only mapped devices by adding the "-firstport" flag to the symdev command though.
The report shows a "1" in the #Mems column for non-metas, and the MemSz (Member Size) column assumes that all members of a particular meta are the same size. You can change the delimiter in the output by changing the DELIM variable (e.g. DELIM="," for CSV).
DELIM="\t"; \
echo "SymID${DELIM}SymDev${DELIM}MemSz${DELIM}#Mems"; \
for SID in 5185 3491; do
symdev -sid $SID list -cyl -meta |grep -e "^\s*[0-9a-fA-F]\{4\}\b" | awk -v OFS=$DELIM -v SID=$SID {'print SID,$1,$(NF)/$(NF-1),$(NF-1)'}
symdev -sid $SID list -cyl |grep -e "^\s*[0-9a-fA-F]\{4\}\b" |grep -ve "\b\([mM]\)\b" | awk -v OFS=$DELIM -v SID=$SID {'print SID,$1,$(NF),"1"'}
done
Here's an example screenshot of the output --
seancummins
2 Intern
•
226 Posts
0
January 14th, 2014 12:00
Hey Dynamox,
It's zsh and powerline, with powerline patched fonts and the solarized color scheme for OS X iTerm2
Here's some info:
https://powerline.readthedocs.org/en/latest/overview.html
The agnoster theme for oh-my-zsh produces a somewhat similar prompt as well...
dynamox
9 Legend
•
20.4K Posts
0
January 14th, 2014 12:00
I like your PS1 prompt, can you share the string
girishp1
1 Rookie
•
32 Posts
0
January 14th, 2014 14:00
That worked like a charm, Sean ! Thanks for all your help today.
dynamox
9 Legend
•
20.4K Posts
0
January 14th, 2014 18:00
zsh ..i don't know if i want to go to the dark side, pretty comfortable with my bash/korn ..look like bash is supported though.