Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DISK CAPACITY

Status
Not open for further replies.

071

MIS
Aug 9, 2000
153
What command can I use to display the number of disks that I have ??
 
Hi there,


Please use the format command but be cautious not to change any parameters.
Bye

RJ
 
Thanks rkjha
The following is the output of 'format' command.

Searching for disks...done


AVAILABLE DISK SELECTIONS:
0. c0t0d0 <SUN18G cyl 7506 alt 2 hd 19 sec 248>
/pci@1f,0/pci@1,1/scsi@2/sd@0,0

What does this mean ? Do I have to use an argument as well ??? ( Its a live system so I cannot probe too much ! )
 
This is showing that the system is only seeing one disk.
C0t0d0 is the logical device name (normaly preseeded by /dev/dsk or /dev/rdsk).
C0 means it is on controller 0
t0 is scsi bus target 0
d0 is disk number 0

The rest <is information relating to the disk> ending with the physical device name.

The very first number ( in this cae 0 ) is the disk number, if you type in the number then format will then give you a list of options to perform on that disk.
If you then type 'partition' you will get more options, type 'print' next and you will get a list of partions on the disk.
I would not recomend going any further unless you know what you are doing.

If you want to know what disks the system expects to load then cat the file /etc/vfstab.

Other commands you can use are sysdef and prtconf.




Ged Jones

Top man
 
Thanks Ged
The following is the output of 'print'

Part Tag Flag Cylinders Size Blocks
0 root wm 0 - 173 400.34MB (174/0/0) 819888
1 swap wu 174 - 2781 5.86GB (2608/0/0) 12288896
2 backup wm 0 - 7505 16.86GB (7506/0/0) 35368272
3 usr wm 2782 - 4520 3.91GB (1739/0/0) 8194168
4 var wm 4521 - 5187 1.50GB (667/0/0) 3142904
5 unassigned wm 5188 - 6635 3.25GB (1448/0/0) 6822976
6 unassigned wm 0 0 (0/0/0) 0
7 home wm 6636 - 7505 1.95GB (870/0/0) 4099440



I presume it means I've 7 disks ?????
 
Nope! .. It still means you have 1 disk, formatted into 8 partitions. As Ged said, it would be worth posting a copy of /etc/vfstab if you're still in any doubt.

Greg.
 
Thanks (again),
The following is the output of the /etc/vfstab

#device device mount FS fsck mount
#to mount to fsck point type
#
#/dev/dsk/c1d0s2 /dev/rdsk/c1d0s2 /usr ufs 1 yes
fd - /dev/fd fd - no
/proc - /proc proc - no
/dev/dsk/c0t0d0s1 - - swap - no
/dev/dsk/c0t0d0s0 /dev/rdsk/c0t0d0s0 / ufs 1 no
/dev/dsk/c0t0d0s3 /dev/rdsk/c0t0d0s3 /usr ufs 1 no
/dev/dsk/c0t0d0s4 /dev/rdsk/c0t0d0s4 /var ufs 1 no
/dev/dsk/c0t0d0s7 /dev/rdsk/c0t0d0s7 /export/home ufs 2 yes
/dev/dsk/c0t0d0s5 /dev/rdsk/c0t0d0s5 /opt ufs 2 yes
swap - /tmp tmpfs - yes

What should I look out for ie what indicated the number of disks in this file ????
 
Does 'dsk' correspond to disk perhaps !!!
 
I think we can safely concur that your server has only 1 disk available, which looks to be about 32Gb in size. You can tell by looking at the controller id and disk id primarily (as Ged explained). In your case they're all c0t0d0s?, which means only 1 controller and 1 disk I'm afraid.

Whether or not you have other disks present but not configured I can't say ... but it doesn't look like it.

Greg.
 
Thanks Greg,
Much appreciated.....
 
You could try (If you haven't already :) &quot;touch /reconfigure&quot; and then init 6, or &quot;boot -r&quot; from init 0. When the system comes back up format should display any other available drives. This may be usefull if someone stuck a drive in there without availing it.

Mike.
 
Solaris is bit bizzare to me who is used to AIX in the way it handles CDROM drive. The following is result of &quot;ls /dev/rdsk&quot; on my mahchine.
# ls /dev/rdsk
c0t0d0s0 c0t0d0s2 c0t0d0s4 c0t0d0s6 c0t6d0s0 c0t6d0s2 c0t6d0s4 c0t6d0s6
c0t0d0s1 c0t0d0s3 c0t0d0s5 c0t0d0s7 c0t6d0s1 c0t6d0s3 c0t6d0s5 c0t6d0s7

This confused me as it doesn't match the result from &quot;format&quot; command where only one drive is showing.

After checking the physical SCSI connection then I realised that the &quot;c0t6d0s*&quot; is actually the CDROM drive.

BTW, I reckon the following line ( about partition 2) gives you the total size of your disk is 16.86GB instead of 32 GB. It has 7506 cylinders and 35368272 sectors.

&quot;2 backup wm 0 - 7505 16.86GB (7506/0/0) 35368272&quot;

Hope this helps.

 
Right sguo partitian 2 is the total disk size. Format only shows disks.
By default the CDROM should be target 6 for it to be bootable under Solaris.
To show all devices you have to shut the system down to the EPROM ( OK> )
prompt and run &quot;probe-scsi &quot; or &quot;probe-scsi-all &quot; if you have more than onw SCSI controller. This will show all SCSI devices.
 
071's machine has 1 disk split into 6 partitions (0, 1, 3, 4, 5 & 7)
Partition 6 is left spare although there is no spare space on the disk.

The disk itself is a Sun 18 GB (see the Format output &quot;SUN18G&quot; ) when this is formatted
it is reduced to 16.86GB as seen in partition 2 of the print output. Partition 2 is always the whole disk,
to simplify backups.

If 071 wants to see if there are any more disks he should either run &quot;prove-scsi&quot; as described above, or
take the machine down to the OK prompt, then &quot;boot -r&quot; this will cause the system to check all it's hardware.
Once the system is back up the format command will show what disks are available.
 
When I said &quot;prove-scsi&quot; I meant &quot;probe-scsi&quot;.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top