Hi Everyone,
I try to calculate the total hard disk space of a solaris machine using iostat -En command. Iterating the output and summing up all the number present near the Size: will give the exact size of the harddisk. But it is not working for a machine.
This command works in many flavors of solaris. This specific issue is with solaris 5.10 Generic_137137-09 sun4u sparc SUNW,Sun-Fire-V890.
Have attached the sample output of the iostat command's output.
Actual size of the machine is 12272.8 GB, but what i got is 25809 GB.
Kindly let me know, whether the way i calucalating the total hard disk size is wrong or is there any way to remove duplicates from the output and getting the exact size.
Since the output is too longs, i have copied the sample output,
bash-3.00$ uname -a
SunOS deltabackup01 5.10 Generic_137137-09 sun4u sparc SUNW,Sun-Fire-V890
-bash-3.00$
-bash-3.00$
-bash-3.00$
-bash-3.00$ iostat -En
c0t0d0 Soft Errors: 2 Hard Errors: 0 Transport Errors: 22
Vendor: TSSTcorp Product: DVD-ROM TS-H352C Revision: SI00 Serial No:
Size: 0.00GB <0 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 2 Predictive Failure Analysis: 0
c1t3d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: HITACHI Product: HUS1014FASUN146G Revision: 2A08 Serial No: 0610TX03WL
Size: 146.80GB <146800115712 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c1t1d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: HITACHI Product: HUS1014FASUN146G Revision: 2A08 Serial No: 0610TX040W
Size: 146.80GB <146800115712 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c1t2d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: HITACHI Product: HUS1014FASUN146G Revision: 2A08 Serial No: 0610TX01H3
Size: 146.80GB <146800115712 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c1t0d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: HITACHI Product: HUS1014FASUN146G Revision: 2A08 Serial No: 0610TX018X
Size: 146.80GB <146800115712 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c2t5006048452A6A886d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 0.00GB <2949120 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c5t5006048452A6A889d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 0.00GB <2949120 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 0.00GB <2949120 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c5t5006048452A6A8A8d0 Soft Errors: 1 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 0.00GB <2949120 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 1 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d119 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d118 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d117 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d116 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d115 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d114 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d113 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d112 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d111 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d110 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d109 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d108 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Media Error: 0 Device Not Ready: 0 No Device: 0 Recoverable: 0
Illegal Request: 3 Predictive Failure Analysis: 0
c2t5006048452A6A8A7d107 Soft Errors: 3 Hard Errors: 0 Transport Errors: 0
Vendor: EMC Product: SYMMETRIX Revision: 5773 Serial No:
Size: 73.10GB <73096888320 bytes>
Kindly let me know if there any other way to get the harddisk size by any other commands.
Thanks,
Prasanna