Please let me know


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Please let me know
# 1  
Old 11-05-2008
Please let me know

Hi,

Please let me know how to check for a disk which must satisfy below two conditions:-

1> Atleast one odd number of path must be there
2>And all partitions in that disk must be unused.

To check for atleast one odd number of paths:- ==============================================
$ hwmgr -show scsi
SCSI DEVICE DEVICE DRIVER NUM DEVICE FIRST
HWID: DEVICEID HOSTNAME TYPE SUBTYPE OWNER PATH FILE VALID PATH
-------------------------------------------------------------------------
68: 0 mullins disk none 0 1 dsk0 [0/0/0]
69: 1 mullins disk none 0 1 dsk1 [0/1/0]
71: 4 mullins disk none 0 4 scp0 [2/0/0]
72: 5 mullins disk none 2 4 dsk2 [2/0/3]
73: 6 mullins disk none 2 4 dsk3 [2/0/4]
74: 7 mullins disk none 2 4 dsk4 [2/0/6]
75: 8 mullins disk none 2 4 dsk5 [2/0/7]
76: 9 mullins disk none 2 4 dsk6 [2/0/8]
77: 10 mullins disk none 0 4 dsk7 [2/0/9]
78: 11 mullins disk none 0 4 dsk8 [2/0/10]
79: 12 mullins disk none 0 4 dsk9 [2/0/11]
80: 13 mullins disk none 0 4 dsk10 [2/0/12]
81: 14 mullins disk none 0 4 dsk11 [2/0/101]
82: 15 mullins disk none 0 4 dsk12 [2/0/102]
83: 16 mullins disk none 0 4 dsk13 [2/0/103]
84: 17 mullins disk none 0 4 dsk14 [2/0/104]
85: 18 mullins disk none 0 4 dsk15 [2/0/105]
86: 19 mullins disk none 0 4 dsk16 [2/0/106]
87: 20 mullins disk none 0 4 dsk17 [2/0/110]
88: 21 mullins disk none 0 4 dsk18 [2/0/108]
89: 22 mullins disk none 0 4 dsk19 [2/0/109]
90: 23 mullins disk none 0 4 dsk20 [2/0/112]
91: 24 mullins disk none 0 4 dsk21 [2/0/107]
92: 25 mullins disk none 0 4 dsk22 [2/0/111]
238: 2 mullins cdrom none 0 1 cdrom3 [1/4/0]
239: 3 mullins cdrom none 0 1 cdrom4 [3/0/0]


To check for unused partitions in disk:
=======================================
$ disklabel dsk1
# /dev/rdisk/dsk1c:
type: SCSI
disk: BD018635C4
label:
flags: dynamic_geometry
bytes/sector: 512
sectors/track: 254
tracks/cylinder: 20
sectors/cylinder: 5080
cylinders: 7001
sectors/unit: 35565080
rpm: 10025
interleave: 1
trackskew: 84
cylinderskew: 74
headswitch: 0 # milliseconds
track-to-track seek: 0 # milliseconds
drivedata: 0
8 partitions:
# size offset fstype fsize bsize cpg # ~Cyl values
a: 131072 0 unused 0 0 # 0 - 25*
b: 262144 131072 unused 0 0 # 25*- 77*
c: 35565080 0 unused 0 0 # 0 - 7000
d: 0 0 unused 0 0 # 0 - 0
e: 0 0 unused 0 0 # 0 - 0
f: 0 0 unused 0 0 # 0 - 0
g: 17585932 393216 unused 0 0 # 77*- 3539*
h: 17585932 17979148 unused 0 0 # 3539*- 7000


Please provide your inputs..

Thanks in Advance,
Mansa
# 2  
Old 11-05-2008
Hi,

Please let me know if you need further explanation...

Please help me...

Thanks,
Mansa
Login or Register to Ask a Question

Previous Thread | Next Thread
Login or Register to Ask a Question