How to add a disk drive This document covers the steps in software to add a disk drive. After you have connected the new drive, and restarted the system do the following. Step 1: Verify a disk adapter is present using hwstat or devcfg: # hwstat I/O Configuration: Bus0: HVME Bus1: (none) Bus2: (none) Bus3: (none). 5 Devices Configured: Device Major/Minor Bus Bus I/O Addr Std I/O Addr ======================== ============== ==== ============ ============ IE 0 Ethernet ( 7, 91 ) Bus0 0x97100000 0x00000000 RTC 0 RT Clocks ( 38, 0 ) Bus0 0x9C000000 0x00000000 HSA 0 Disk 0/0 ( 101, 0 ) Bus0 0xCA040000 0x00000000 IS 0 Disk 0/0 ( 101, 28672) Bus0 0x97200000 0x00000000 IS 0 Tape 5/0 ( 103, 29952) Bus0 0x97200000 0x00000000 Step 2: Verify the proper entry in the /etc/conf/node.d/gd file reflects the drive you are configuring: #Driver Node Node Adapter Adapter SCSI SCSI Owner Group Modes Level #Name Name Type Type Number ID LUN #---- ---- ---- ------- ------- ---- ---- ----- ----- ----- ----- # gd dsk/0 D hsa 0 0 0 0 3 0640 2 gd dsk/1 D is 0 0 0 0 3 0640 2 We show adding two drives to both adapters adding the following two lines: gd dsk/2 D hsa 0 1 0 0 3 0640 2 gd dsk/3 D is 0 1 0 0 3 0640 2 The adapter number must match the one shown in the hwstat output. Step 3: Create the device special files for the partitions being configured using the /etc/bin/idmknod command: # /etc/conf/bin/idmknod -M gd This command creates the special device files in the /dev/rdsk and /dev/dsk directories. Step 4: The new drive must have partitions formatted onto the drive using the /etc/format utility program: # /etc/format 1 Opening '/dev/rdsk/1s7'. Reading the geometry block. /dev/rdsk/1s7 Integral SCSI revision 0, SCSI disk model 12 megabytes: 496 physical cylinders per drive: 1983 physical heads per cylinder : 16 physical sectors per head : 32 physical bytes per sector : 512 physical 512 drive description blocks at block 1013760 1024 diagnostic blocks at block 1014272 3600 revolutions per minute geometry block version 2 flaw map size is 0 bytes partition 0 307200 kbytes 0 start kbyte partition 1 199680 kbytes 307200 start kbyte partition 2 0 kbytes 0 start kbyte partition 3 0 kbytes 0 start kbyte partition 4 0 kbytes 0 start kbyte partition 5 0 kbytes 0 start kbyte partition 6 0 kbytes 0 start kbyte partition 7 768 kbytes 506880 start kbyte 507648 kbytes used 0 kbytes unused format: Use the format "p" command to set partition sizes and the "w" command to update the geometry block for the disk with new partitions and "quit" format. Step 5: The disk needs to be formatted with file system structures: # /sbin/newfs -F ufs /dev/rdsk/1s1 # To create a "ufs" type file system, # /sbin/newfs -F xfs /dev/rdsk/1s1 # To create an "xfs" type file system. Note: The SFS file system is obsolete. Please do not use the sfs type file system. Step 6: A mount point under "/" (root) needs to be made to mount the partition: # /usr/bin/mkdir /usr1 Step 7: The /etc/vfstab file needs updating to enable the file system to be mounted when the system boots: #special fsckdev mountp fstype fsckpass automnt mntopts /dev/root /dev/rroot / sfs 0 yes - /dev/swap - - swap - yes - /dev/usr /dev/rusr /usr sfs 1 yes - /dev/var /dev/rvar /var sfs 0 yes - /proc - /proc proc - no - /dev/fd - /dev/fd fdfs - no - /system/processor - /system/processor profs - no - # #New Disk Partitions: # /dev/dsk/1s0 - - swap - yes - /dev/dsk/1s1 /dev/rdsk/1s1 /usr1 ufs 1 yes - # Step 8: At this point you may want to run the file system checker program fsck on the new partition to verify it was created accurately. # /sbin/fsck /dev/rdsk/1s1 Step 9: Now the file system may be mounted using the standard mount command: # /etc/mount /dev/rdsk/1s1 # which is seldom used, or # /etc/mount /dev/dsk/1s1 # or more commonly # /etc/mount /usr1 The disk is now accessible for file access. For more information see format(1), gd(7), idmknod(1), mkfs(1), mount(1), newfs(1), and vfstab(4).