NVRAM supports the fast write capability for SPARCstorage Arrays. Without NVRAM, synchronous write requests from a program must be committed to disk, and an acknowledgment must be received by the program, before another request can be submitted. The NVRAM caches write requests in non-volatile memory and periodically flushes the data to disk. Once the data is in the NVRAM, an acknowledgment is returned to the program just as if the data had been written to disk. This enhances performance of write-intensive applications using SPARCstorage Arrays.
The procedures described here use the command-line interface. However, in Solstice DiskSuite configurations, you also can use the metatool graphical user interface to administer NVRAM for a disk, tray, or controller. For more information on Solstice DiskSuite, see the Solstice DiskSuite documentation.
Use this functionality with care. It provides a powerful way to manage the SPARCstorage Array. Back up your data before using these procedures.
Fast writes can be configured:
At the controller level, affecting all drives in the SPARCstorage Array
At the drive level, setting fast write for an individual drive
At the tray level, through the Solstice DiskSuite GUI
When fast write is enabled, it can be saved--across power cycles--as part of the SPARCstorage Array's configuration.
If the NVRAM battery is low, missing, or has failed, then fast write is disabled on the controller.
Before enabling fast write, you must stop all I/O to the controller or disk. In particular, ensure that diskset ownership has been released because an implicit I/O stream exists while ownership of a diskset is maintained. The following procedure explains how to stop all I/O.
Use the luxadm(1M) command to enable and disable NVRAM. Refer to the luxadm(1M) man page for complete information on this command.
For VxVM cluster feature (as used with Oracle Parallel Server), you should disable NVRAM.
These are the high-level steps to enable or disable NVRAM:
Ensuring that you have a current backup of all data
Ensuring that you have root privilege
Identifying the controller or disk on which to enable or disable NVRAM
Stopping all I/O to the device
Enabling or disabling NVRAM
Bringing the device back up and resynchronizing the data
These are the detailed steps to enable or disable NVRAM.
Identify the controller, tray, or individual disk whose NVRAM is to be enabled or disabled.
You can use the luxadm(1M) command to display information for a specified controller, tray, or individual disk. For example, the following display identifies all of the disks on Controller c2.
phys-hahost1# luxadm display c2 SPARCstorage Array Configuration Controller path: /devices/iommu@f,e0000000/sbus@f,e0001000/SUNW,soc@0,0/SUNW,pln@a0000000,779a16:ctlr DEVICE STATUS TRAY 1 TRAY 2 TRAY 3 slot 1 Drive: 0,0 Drive: 2,0 Drive: 4,0 2 Drive: 0,1 Drive: 2,1 Drive: 4,1 3 NO SELECT NO SELECT NO SELECT 4 NO SELECT NO SELECT NO SELECT 5 NO SELECT NO SELECT NO SELECT 6 Drive: 1,0 Drive: 3,0 Drive: 5,0 7 Drive: 1,1 NO SELECT NO SELECT 8 NO SELECT NO SELECT NO SELECT 9 NO SELECT NO SELECT NO SELECT 10 NO SELECT NO SELECT NO SELECT CONTROLLER STATUS ... |
Stop all I/O to the affected device.
Solstice DiskSuite:
For a controller or tray, refer to the applicable steps in the procedure "How to Take a SPARCstorage Array Tray Out of Service (Solstice DiskSuite)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (Solstice DiskSuite)".
VxVM:
For a controller or tray, refer to the applicable steps in the procedure "How to Take a SPARCstorage Array Tray Out of Service (VxVM)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (VxVM)".
Enable or disable fast write on the controller or individual disk.
Use one of the three options to the luxadm(1M) command, depending on whether you are enabling fast write for all writes, enabling fast write only for synchronous writes, or disabling fast write.
-e enables fast write for all writes
-c enables fast write for only synchronous writes
-d disables fast write
The following example saves the NVRAM configuration across power cycles and enables fast write for all writes. See the luxadm(1M) man page for details on these options.
phys-hahost# luxadm fast_write -s -e pathname |
A confirmation appears, indicating that fast write has been enabled.
Perform the steps needed to bring the component into normal operation under Sun Cluster.
Solstice DiskSuite:
For a controller or tray, refer to the applicable steps in the procedure "How to Return a SPARCstorage Array Tray to Service (Solstice DiskSuite)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (Solstice DiskSuite)".
VxVM:
For a controller or tray, refer to the applicable steps in the procedure "How to Return a SPARCstorage Array Tray to Service (VxVM)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (VxVM)".
The luxadm sync_cache command flushes any outstanding writes from NVRAM to the disk drive. If you get an error while flushing data, you must purge the data using the luxadm purge command. Purging data "throws away" any outstanding writes in NVRAM.
Purging fast write data should be performed with caution, and only when a drive has failed, as it could result in the loss of data.
If the NVRAM battery is low, missing, or has failed, then NVRAM is non-functional and data is lost.
These are the high-level steps to flush or purge all outstanding writes for the selected controller (and all disks) or individual writes from the NVRAM to disk:
Ensuring you have a current backup of all data
Ensuring you have root privilege
Identifying the controller or disk on which to flush or purge writes
Flushing or purging all outstanding writes
Stopping all I/O to the device
Bringing the device back into service under Sun Cluster
These are the detailed steps to flush or purge NVRAM data.
Identify the controller or the individual disk to flush or purge.
You can use the luxadm(1M) command to display information for a specified controller, tray, or individual disk. For example, the following display identifies all of the disks on Controller c2.
phys-hahost1# luxadm display c2 SPARCstorage Array Configuration Controller path: /devices/iommu@f,e0000000/sbus@f,e0001000/SUNW,soc@0,0/SUNW,pln@a0000000,779a16:ctlr DEVICE STATUS TRAY 1 TRAY 2 TRAY 3 slot 1 Drive: 0,0 Drive: 2,0 Drive: 4,0 2 Drive: 0,1 Drive: 2,1 Drive: 4,1 3 NO SELECT NO SELECT NO SELECT 4 NO SELECT NO SELECT NO SELECT 5 NO SELECT NO SELECT NO SELECT 6 Drive: 1,0 Drive: 3,0 Drive: 5,0 7 Drive: 1,1 NO SELECT NO SELECT 8 NO SELECT NO SELECT NO SELECT 9 NO SELECT NO SELECT NO SELECT 10 NO SELECT NO SELECT NO SELECT CONTROLLER STATUS Vendor: SUN Product ID: SSA110 Product Rev: 1.0 Firmware Rev: 3.9 Serial Num: 000000779A16 Accumulate Performance Statistics: Enabled phys-hahost1# |
Stop all I/O to the affected device.
Solstice DiskSuite:
For a controller or tray, refer to the applicable steps in the procedure "How to Take a SPARCstorage Array Tray Out of Service (Solstice DiskSuite)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (Solstice DiskSuite)".
VxVM:
For a controller or tray, refer to the applicable steps in the procedure "How to Take a SPARCstorage Array Tray Out of Service (VxVM)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (VxVM)".
Flush or purge the NVRAM on a controller, tray, or individual disk.
If you can access drives in the SPARCstorage Array, flush the NVRAM. Only purge the NVRAM if you can no longer access the SPARCstorage Array or disk.
phys-hahost1# luxadm sync_cache pathname or phys-hahost1# luxadm purge pathname |
A confirmation appears, indicating that NVRAM has been flushed or purged.
Perform the steps needed to bring the component into normal operation under Sun Cluster.
Solstice DiskSuite:
For a controller or tray, refer to the applicable steps in the procedure "How to Return a SPARCstorage Array Tray to Service (Solstice DiskSuite)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (Solstice DiskSuite)".
VxVM:
For a controller or tray, refer to the applicable steps in the procedure "How to Return a SPARCstorage Array Tray to Service (VxVM)".
For a disk, refer to the applicable steps in the procedure "How to Replace a SPARCstorage Array Disk (VxVM)".