Managing Systems and Workgroups: A Guide for HP-UX System Administrators

Administering a System: Managing Disks and Files
Managing Disks
Chapter 6 599
Handling I/O Errors within LVM
When a device driver returns an error to LVM on an I/O request, LVM
classifies the error as either non-recoverable or recoverable. How
those errors are handled determines your course of action.
Non-Recoverable
Errors
Non-recoverable errors are considered fatal; there’s no expectation that
retrying the operation could work. LVM considers two specific situations
as non-recoverable:
If an I/O request fails because of a media error — LVM will log a
message to the console when the error occurs.
If the device associated with the I/O was not present when the volume
group was activated LVM will print an error message to the user’s
terminal and log it to the console, but only when the volume group is
activated.
If you have a current copy of the data on a separate, functioning mirror,
then LVM directs reads and writes to a mirror copy. As far as the
application accessing the logical volume is concerned, the I/O operation
completes successfully.
However, if you have no other copies of the data — that is, the only copy
of the data is on that physical volume — then LVM returns an error to
whatever subsystem is accessing the logical volume. This means that
any application directly accessing a logical volume should be prepared
for I/O requests to fail. File systems such as VxFS and most database
applications are designed to recover from error situations; for example, if
VxFS encounters an I/O error, it may disable access to a file system or a
subset of the files in it.
Dealing with
Non-Recoverable
Errors
How you deal with a non-recoverable error depends on what kind of
problem LVM encountered. For a media error, you’ll have to replace the
disk; for a procedure to do that, see “Replacing a Mirrored Disk” on
page 638. For a device that wasn’t present at activation time, either
locate the disk and restore it to service, or replace it using the same
procedure, then activate the volume group again.
Recoverable
Errors
When LVM encounters a recoverable, or “correctable” error, it will
internally retry the failed operation, under the assumption that the error
will correct itself, or that you as system administrator can take steps to
correct it. Examples of recoverable errors are device power failure, a disk
that goes missing after the volume group is activated, or a loose disk