Platform Notes: Using luxadm Software

Removing a Disk Drive

This section describes how to configure your system to remove a disk drive while the power is on and the operating system is running. Use the procedures in this chapter if you do not intend to replace the disk drive.

You must select the disk and stop any activity or applications on it, unmount it, physically remove the drive, and configure the Solaris environment to recognize that the drive is no longer there. You must then configure your application to operate without this device in place.

Caution - Caution -

These procedures should be performed only by a qualified system administrator. Performing hot-plug operations on an active disk drive can result in data loss and/or data corruption.

Preparing to Remove the Disk Drive

The following procedure describes how to unconfigure a disk being used by one or more UFS file systems.

  1. Stop any application processes on the file systems to be unconfigured.

  2. Back up your system.

  3. Determine what file system(s) are on the disk:

    # mount | grep cwtxdysz

    For example, if the device to be removed is c2t1d0, enter the following:

    # mount | grep c2t1d0
    /export/home   (/dev/dsk/c2t1d0s7 ):   98892 blocks   142713 files
    /export/home2  (/dev/dsk/c2t1d0s5 ):  153424 blocks   112107 files

  4. Unmount any file systems on the disk.

    Note -

    If the file system(s) are on a disk that is failing or has failed, the umount operation may not complete. A large number of error messages may be displayed in the system console and in the /var directory during the umount operation. If the umount operation does not complete, you may have to restart the system.

    For each file system returned, type:

    # umount filesystem

    where: filesystem is the first field for each line returned in Step 3.

    For example:

    # umount /export/home
    # umount /export/home2

Removing the Disk Drive

  1. Use the luxadm remove_device command to remove the disk.

    The luxadm remove_device command is interactive. You will be guided through the procedure for removing a device or chain of devices.

    # luxadm remove_device /dev/rdsk/c2t1d0s2
      WARNING!!! Please ensure that no filesystems are mounted
    on these device(s).
      All data on these devices should have been backed up.
    The list of devices which will be removed is:
      1: Box Name "macs1" front slot 1
    Please enter 'q' to Quit or <Return> to Continue: 
    stopping:  Drive in "macs1" front slot 1....Done
    offlining: Drive in "macs1" front slot 1....Done
    Hit <Return> after removing the device(s).

  2. Remove the disk drive and then hit any key.

    Note -

    The yellow LED on the designated disk drive(s) should be flashing.

    The following is displayed:

    Drive in Box Name "macs1" front slot 1
        Removing Logical Nodes: 
    	Removing c2t1d0s0
    	Removing c2t1d0s1
    	Removing c2t1d0s2
    	Removing c2t1d0s3
    	Removing c2t1d0s4
    	Removing c2t1d0s5
    	Removing c2t1d0s6
    	Removing c2t1d0s7