When a device in a storage pool becomes permanently unreliable or non-functional, you can take the device offline with the following command:
# zpool offline [option] pool device
where the name of device can either be the short name or the full path.
When you take a device offline, its OFFLINE state becomes persistent. For a nonpersistent OFFLINE state, use the –t option, which takes the device temporarily offline. When the system is rebooted, the device is automatically restored to the ONLINE state.
Caution - Do not take devices offline such that the pool itself becomes unavailable. For example, you cannot take offline two devices in a raidz1 configuration, nor can you take offline a top-level virtual device. The following error message would be displayed:
cannot offline c0t5000C500335F95E3d0: no valid replicas
The OFFLINE state does not mean that the device is detached from the pool. Therefore, you cannot use that device for another pool. Otherwise, an error message is generated similar to the following example:
device is part of exported or potentially active ZFS pool. Please see zpool(8)
To use the device for another pool, first restore the device to the ONLINE state, and then destroy the pool to which the device belongs.
If you do not want to destroy the pool, replace the offlined device with a comparable device. The replaced device then becomes available for a different pool.
# zpool online [option] pool device
Any data that has been written to the pool is resynchronized with the newly available device.
If you try to bring online a device whose state is UNAVAIL, a message about a faulted device is displayed, similar to the following example:
warning: device 'device' onlined, but remains in faulted state use 'zpool clear' to restore a faulted device
Messages about faulted device might also be displayed on the console or written to the /var/adm/messages file.
For more information about replacing a faulted device, see Resolving a Missing or Removed Device.
To expand a LUN, use the zpool online –e command. By default, a LUN that is added to a pool is not expanded to its full size unless the autoexpand pool property is enabled. If the property is disabled, use the command to expand the LUN automatically. You can run the command regardless of whether the LUN is offline or already online.