Start a Conversation

Unsolved

This post is more than 5 years old

2456

April 1st, 2013 13:00

naviseccli - Find and calculate all "UNBOUND" devices

Hi - How do you use naviseccli to find all "FREE" disks?

I can get just about any other info needed, but I am struggling with this.

Thank you!

9 Legend

 • 

20.4K Posts

April 1st, 2013 13:00

this is from a linux/unix client, i am not sure if findstr on windows has equivalent syntax

naviseccli -User sysadmin -Password sysadmin -Scope 0 -address 10.1.3.4 getdisk -state | grep -B1 Unbound

1.4K Posts

April 1st, 2013 13:00

naviseccli -h getdisk -state will list all the disks with its status which you can furthermore, filter it via grep if you need to as dynamox mentioned.

4.5K Posts

April 3rd, 2013 08:00

Was your question answered correctly? If so, please remember to mark your question Answered when you get the correct answer and award points to the person providing the answer. This helps others searching for a similar issue.

glen

March 30th, 2015 18:00

Following is an AWK script which should summarize the Unbound drives

$ cat vnx_unbound
#/bin/awk

# EMC VNX Unbound Disk Summary
# filter output of:
#       naviseccli -h  getdisk -drivetype -capacity -state | \
#       awk -f 
  

BEGIN {
        RS=""
}

/Unbound/ {
        bus = $2; enc = $4; disk = $6
        nl=split($0, line, "\n")
        while (nl) {
                split(line[nl--], arr, ":")
                if (arr[1]=="Drive Type") drive_type=arr[2]
                gsub("^ +", "", drive_type)
                if (arr[1]=="Capacity") capacity=arr[2]
        }
        drive_type_capacity[drive_type]+=capacity
        drive_type_count[drive_type]+=1
        printf "%d_%d_%d\t%d\t%s\n", bus, enc, disk, capacity, drive_type
}
END {
        # Summary header
        printf "#\tCap(GB)\tdr_cnt\tdrive type\n"
        for (dt in drive_type_capacity) {
                printf "#\t%'6d\t%3d\t%s\n", drive_type_capacity[dt]/2^10, drive_type_count[dt], dt


        }
}

An example

$ naviseccli -h 
    getdisk -drivetype -capacity -state | awk -f vnx_unbound
0_0_0   549691  SAS
0_0_1   549691  SAS
0_0_2   549691  SAS
0_0_3   549691  SAS
0_0_4   187847  SAS Flash
0_0_18  187847  SAS Flash VP
0_3_22  549691  SAS
0_4_22  549691  SAS
0_5_0   2817564 NL SAS
0_5_5   2817564 NL SAS
0_5_6   2817564 NL SAS
0_5_7   2817564 NL SAS
0_5_8   2817564 NL SAS
0_5_9   2817564 NL SAS
0_5_10  2817564 NL SAS
0_5_11  2817564 NL SAS
0_5_12  2817564 NL SAS
0_5_13  2817564 NL SAS
0_5_14  2817564 NL SAS
1_3_19  549691  SAS
1_4_0   2817564 NL SAS
1_4_5   2817564 NL SAS
1_4_6   2817564 NL SAS
1_4_7   2817564 NL SAS
1_4_8   2817564 NL SAS
1_4_9   2817564 NL SAS
1_4_10  2817564 NL SAS
1_4_11  2817564 NL SAS
1_4_12  2817564 NL SAS
1_4_13  2817564 NL SAS
1_4_14  2817564 NL SAS
0_1_22  549691  SAS
1_5_0   2817564 NL SAS
1_5_1   2817564 NL SAS
1_5_2   2817564 NL SAS
1_5_3   2817564 NL SAS
1_5_4   2817564 NL SAS
1_5_5   2817564 NL SAS
1_5_6   2817564 NL SAS
1_5_7   2817564 NL SAS
1_5_8   2817564 NL SAS
1_5_9   2817564 NL SAS
1_5_10  2817564 NL SAS
1_5_11  2817564 NL SAS
0_2_22  549691  SAS
1_1_21  549691  SAS
1_2_21  549691  SAS
#       Cap(GB) dr_cnt  drive type
#       93,551   34     NL SAS
#          183    1     SAS Flash
#          183    1     SAS Flash VP
#        5,904   11     SAS


   
  
 

syntax highlighted by Code2HTML

, v. 0.9.1

March 31st, 2015 06:00

... and for the more challenged GUI people (i.e. "me") use Navisphere

-> System -> Hardware -> Disks

sort by state - export to csv

No Events found!

Top