Red Hat Bugzilla – Bug 421451
kernel dm-snapshot: excessive memory usage
Last modified: 2013-02-28 23:06:47 EST
+++ This bug was initially created as a clone of Bug #383031 +++
Description of problem:
Using the device mapper snapshot of an origin device to simulate a CoW devices
causes progressive memory exhaustion as the device is written to.
This bugzilla covers backporting of a simple implementation of consecutive
exceptions for in-memory storage structure.
Using consecutive counter has huge memory saving impact in some snapshot
configuration (and doesn't increase memory use otherwise).
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release. Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products. This request is not yet committed for inclusion in an Update
You can download this test kernel from http://people.redhat.com/dzickus/el5
Confirmed the -75 kernel is using less memory with the provided testcase.
[root@test177 snapshot_verify]# cat snapslab-2.6.18-75.el5
dm-snapshot-in 1533 3128 112 34 1
dm-snapshot-ex 6982 9856 32 112 1
[root@test177 snapshot_verify]# cat snapslab-2.6.18-53.1.4.el5
dm-snapshot-in 1317 2380 112 34 1
dm-snapshot-ex 24724 27888 32 112 1
Other than the increase memory usage, both kernels seemed to hold up well. I was
never able to reproduce any corrupted snapshots or other errors.
I am pretty close to having the reproducer ready to go in RHTS.
*** Bug 383031 has been marked as a duplicate of this bug. ***
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.