HP-UX 11i v3 Using LVM Logical Volume Snapshots (September 2010)
13
Enabling the automatic increase of pre-allocated extents does not ensure that the snapshot logical
volume does not get marked as over-commit. You must select a proper threshold value based on the
purpose of snapshot, the duration for which the snapshot is kept, and the I/O activity on the original
logical volume.
If the I/O activity on the original logical volume is greater, choose a higher threshold value so the
threshold is reached faster and more pre-allocated extents are allocated at a time.
Example
An original logical volume /dev/vg01/lvol1 has 200 extents. For snapshot logical volume
/dev/vg01/lvol1_S2 with 100 extents and threshold value 70%, the lvdisplay output is
as follows:
# lvdisplay /dev/vg01/lvol1_S2
--- Logical volumes ---
LV Name /dev/vg01/lvol1_S2
VG Name /dev/vg01
LV Permission read-only
LV Status available/syncd, snapshot,space efficient
Snapshot Status operative
Mirror copies 0
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 400
Current LE 200
Allocated PE 0
Stripes 0
Stripe Size (Kbytes) 0
Bad block NONE
Allocation strict
IO Timeout (Seconds) default
Pre-allocated LE 100
Current pre-allocated LE 100
Unshared LE 0
Current pre-allocated PE 100
Original LV /dev/vg01/lvol1
Timestamp Wed Apr 28 14:01:14 2010
Auto Pre-allocation Enabled
Threshold Percent 70
When a write operation comes to an original logical volume, data unsharing is initiated on the
snapshot logical volume. If the number of extents in the pre-allocated pool size is less than or equal to
the threshold value, automatic increase of pre-allocated extents is initiated and the number of pre-
allocated extents increases by the threshold value.
In the previous example, if the number of extents remaining in the pre-allocated pool reaches the
threshold value (70% of number of pre-allocated extents), the number of pre-allocated extents is
automatically incremented by the threshold value (70 extents). Now, the number of pre-allocated
extents is 170.
The following is the output of lvdisplay of a snapshot logical volume /dev/vg01/lvol1_S2
after automatic increase of pre-allocated extents:
# lvdisplay /dev/vg01/lvol1_S2
--- Logical volumes ---
LV Name /dev/vg01/lvol1_S2
VG Name /dev/vg01
LV Permission read-only
LV Status available/syncd, snapshot,space efficient
Snapshot Status operative