presto - the Prestoserve pseudodevice driver
#include <sys/presto.h> #include <sys/prestoioctl.h> pseudo-device presto
The Prestoserve pseudodevice driver presto caches synchronous writes in nonvolatile memory. Prestoserve causes synchronous writes to be performed at memory speeds, rather than at disk speeds. Synchronous writes that result in Prestoserve cache hits do not perform the earlier physical disk writes, because only the last write is actually performed by Prestoserve. Therefore, 50% to 65% of all the physical disk write operations are avoided, because every sequential NFS write to a file also causes the inode and the indirect block to be synchronously written.
The presto driver is layered on other disk drivers, and it intercepts the other drivers' I/O requests by replacing the entry points of the original driver in the bdevsw and cdevsw tables. The presto driver caches the intercepted synchronous write requests in the Prestoserve cache's nonvolatile memory. When Prestoserve needs to perform actual I/O, it calls the original driver's entry points to perform the I/O. A modified form of Least Recently Used (LRU) replacement determines when the Prestoserve cache data needs to be written to the intended disks.
An accelerated disk device (one that has the presto pseudodevice driver layered on top of its driver), uses the same major and minor devices that it used before it was accelerated.
The Prestoserve nonvolatile memory must be found at boot time in order for Prestoserve to perform its write-caching function. In addition, Prestoserve must pass diagnostic tests, and there must be sufficient backup battery power to guarantee a reasonable amount of cache data stability (measured in days or weeks) in the event of a power or hardware failure.
If the Prestoserve nonvolatile memory is not found or if there is not enough backup battery power, then the disks are not accelerated; however they can be opened and used as usual. In this case, the presto driver simply passes all I/O requests directly through to the appropriate device.
When Prestoserve is in the PRDOWN state, there is no data in the Prestoserve cache, no data is put into the Prestoserve cache, and all disk requests are passed directly to the real disk driver.
When Prestoserve is in the PRERROR state, the data in the Prestoserve cache can not be written to the intended disks because of a disk, system, or hardware error.
When the system is shut down normally by using the reboot system call from the shutdown, halt, or reboot command, the Prestoserve cache data is written to the intended disks, and Prestoserve enters the PRDOWN state. This allows you to fix any system or disk error or to upgrade or change your system without losing the data in the Prestoserve cache or corrupting your disks.
If your system was shut down without following normal shutdown procedures, and you reboot the system, any data in the Prestoserve cache is written to the intended disks, if possible. If the data is successfully written to the intended disks (and if the nonvolatile memory and backup battery passed the diagnostic tests), Prestoserve enters the PRDOWN state. If an error occurs, Prestoserve enters the PRERROR state.
If an error from a disk device occurs or if the backup battery power is insufficient, Prestoserve writes the cache data to the intended disks, if possible, and enters the PRERROR state. When Prestoserve is in the PRERROR state, new data that is written to a block not found in the Prestoserve cache is passed directly to the real disk driver. If new data is written to a block that is found in the cache, Prestoserve replaces the existing block and attempts to write the block to the real disk driver to determine if the error condition on that block still exists. If the write is successful and if all the Prestoserve cache data can be written to the intended disks, Prestoserve leaves the PRERROR state.
The Prestoserve cache never discards data without being explicitly told to do so by using a PRRESET ioctl command. This can be done by using the presto -R command. This command should only be used when there is a fatal disk error and when the data is not important.
Prestoserve license not registered
This message is displayed if you attempt to use Prestoserve on a system that has not had its license registered. It is necessary to register a valid license in order to use Prestoserve.
presto: Block device N currently not present, delay writing of its buffers
During a system reboot, dirty buffers were found for a block device with the major number N. The dirty buffers could not be written to the device because the device was not registered with Prestoserve. Prestoserve will remain in the ERROR state until the device with major number N registers itself with Prestoserve, at which time the dirty buffers will be flushed back to the device.
presto: using %d bytes of NVRAM at 0x%x
This message is displayed at boot time and indicates that Prestoserve recognized its control information portion of the cache. It is a normal Prestoserve startup message.
presto: initializing %d bytes of NVRAM at 0x%x
This message is displayed at boot time and indicates that Prestoserve did not recognize the cache as being in either a clean (containing no data) or a dirty (containing data) state. The message is usually displayed when the cache is used for the first time, after the cache has been cleared by using a diagnostic command, or after backup battery failure.
presto: NVRAM tested %s
This message is displayed at boot time, and it indicates that the cache tested as either "read/write ok" or "readonly ok." The message is a normal Prestoserve startup message.
presto: %s battery %s
The status for the primary battery or a secondary battery, if applicable, is reported as either OK , LOW , or DISABLED . This message is displayed at boot time and when there is a change in the state of the backup battery power level.
presto: cache contains dirty data
This message is displayed at boot time if Prestoserve was not shut down by using the normal system shutdown procedures.
presto: %d dirty buffers found
This message indicates that dirty buffers were found after the system rebooted. The data is written to the intended disks as soon as possible, usually when the first I/O request occurs for any accelerated device.
presto: writing dirty buffers
This message indicates that Prestoserve has begun to write the data in the dirty buffers to the intended disks.
presto: dirty buffers written
This message indicates that the data in the dirty buffers has been successfully written to the intended disks.
presto: using software version %d -- version %d last used
This message is displayed at boot time and indicates that the kernel is now being run with a version of the Prestoserve software that is different from the version used previously. Usually, this message is displayed when you first boot the system after performing a software upgrade.
presto: expected sizes %d, %d -- found %d, %d
This message indicates that the block size and fragment size in the Prestoserve control information portion of the cache are different from the information that was expected. This message should only be displayed when you first boot the system after performing a software upgrade.
presto: NVRAM increased from %d to %d bytes at 0x%x
This message indicates that only a portion of the Prestoserve cache was being used when the system was shut down, but now Prestoserve is using the entire cache. The presto -s command, which changes the size of the Prestoserve cache, is described in presto(8).
presto: decreased from %d to %d bytes!
This message indicates that a hardware or software problem exists because the size of the Prestoserve cache at reboot is less than the size of the cache when the system shut down.
presto: dirty buffers found for host id 0x%x,
which is different from this host's id (0x%x)
This message is displayed at boot time and indicates that Prestoserve was not shut down normally and that the cache contents were previously in a different system (for example, either the cache was moved or the system ID, which is usually the on-board Ethernet hardware address, has changed). Prestoserve allows you to do one of the following interactively: discard the data, write the data to disk, or halt the machine.
The Prestoserve cache failed memory self-tests.
The cache may contain data which has not been written to disk yet.
When these messages are displayed, Prestoserve allows you to do one of the following interactively: continue with the boot or halt the machine.
presto: error %d opening dev (%d, %d), skipping writing of its buffers...
This message indicates that dirty Prestoserve buffers were found after the system rebooted, and the data in the dirty buffers could not be written to the specified device because the device failed to open. You should verify that the device is online and that the kernel successfully found the device at boot time. Refer to errno(2) for a complete description of the error.
presto: error %d opening block device (%d, %d)
This message indicates that the specified device failed to open. You should check your disk configuration and make sure that the drive is on line. Refer to errno(2) for a complete description of the error.
presto: error %d ioctl'ing dev (%d, %d)
This message indicates that an ioctl failed for the specified device. Refer to errno(2) for a complete description of the error.
presto: can NOT do direct I/0 for block device (%d, %d)
presto: using block device (%d, %d) in `bounceio' mode
These messages indicate that the disk controller for the specified device could not directly address the cache when Prestoserve was enabled on the file system.
presto: flush dirty buffers
This message is displayed when Prestoserve is in the PRERROR state and receives a request to write the data in a dirty buffer to the intended disks.
presto: Block device %d not present or is not Presto-ized in this kernel!
This message indicates that Prestoserve was not shut down cleanly, and the system was previously running a kernel with an accelerated device that the current kernel does not accelerate. You should boot a kernel that accelerates all the devices that were previously accelerated.
presto: NVRAM probe error
This message is displayed at system startup if a Prestoserve cache read/write error occurred, and it indicates that the cache could not be accessed. It indicates a hardware or software error.
presto: failed to write and read 0x%x from 0x%x
This message indicates that the Prestoserve cache failed the read/write test at the specified address.
presto: error on dev (%d, %d)
This message indicates that an I/O error occurred on the specified disk during a Prestoserve write-back operation.
presto: not enough backup battery power!
This message indicates that there is inadequate backup battery power. Prestoserve attempts to write all Prestoserve cache data to the intended disks and then enters the PRERROR state.
This message indicates that Prestoserve disabled itself because of inadequate backup battery power or because a disk error occurred during a write to disk.
presto: back online!
This message indicates that a disk error or low backup battery power condition has been corrected and that Prestoserve is enabled again.
errno(2), ioctl(2), presto(8), dxpresto(8X),
prestoctl_svc(8), prestosetup(8), prestotab(4)
Guide to Prestoserve delim off