Issue 9002 - Add option to slapcat to honor rtxnsize setting
Summary: Add option to slapcat to honor rtxnsize setting
Status: UNCONFIRMED
Alias: None
Product: OpenLDAP
Classification: Unclassified
Component: slapd (show other issues)
Version: 2.4.47
Hardware: All All
: --- enhancement
Target Milestone: 2.7.0
Assignee: OpenLDAP project
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-03-29 19:58 UTC by Quanah Gibson-Mount
Modified: 2021-10-28 21:21 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Quanah Gibson-Mount 2019-03-29 19:58:25 UTC
Full_Name: Quanah Gibson-Mount
Version: 2.4.47
OS: N/A
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (47.208.144.40)


There is currently an issue with back-mdb, where if the database is quite large
(10GB+) and the environment is experiencing a heavy write load, that if you
start a backup (slapcat or mdb_copy), the database will heavily fragment and
grow significantly in size due to the read lock from the slapcat/mdb_copy
process.

To work around this, slapcat could be given an option to honor the rtxnsize
setting in slapd.conf/cn=config.  This would allow the read lock to be released
periodically and thus reduce the amount of fragmentation that occurs during the
backup process.  There is not (at this time) a solution proposed for mdb_copy.

It should be noted in the man page section for this option that the value of
such a backup is of dubious quality, since it is no longer an exact "point in
time" representation of the database but rather a bunch of different "point in
times" stitched together into a single file.
Comment 1 Michael Ströder 2019-03-29 20:13:38 UTC
On 3/29/19 8:58 PM, quanah@openldap.org wrote:
> To work around this, slapcat could be given an option to honor the rtxnsize
> setting in slapd.conf/cn=config.
> [..]
> It should be noted in the man page section for this option that the value of
> such a backup is of dubious quality, since it is no longer an exact "point in
> time" representation of the database but rather a bunch of different "point in
> times" stitched together into a single file.

Even if slapcat now outputs an exact "point in time" representation of
the database this does not say anything about consistency of related
LDAP entries anyway.

But I wonder how rtxnsize is supposed to interop with
LDAP transactions in 2.5.

Comment 2 Howard Chu 2019-03-29 20:28:09 UTC
michael@stroeder.com wrote:
> On 3/29/19 8:58 PM, quanah@openldap.org wrote:
>> To work around this, slapcat could be given an option to honor the rtxnsize
>> setting in slapd.conf/cn=config.
>> [..]
>> It should be noted in the man page section for this option that the value of
>> such a backup is of dubious quality, since it is no longer an exact "point in
>> time" representation of the database but rather a bunch of different "point in
>> times" stitched together into a single file.
> 
> Even if slapcat now outputs an exact "point in time" representation of
> the database this does not say anything about consistency of related
> LDAP entries anyway.
> 
> But I wonder how rtxnsize is supposed to interop with
> LDAP transactions in 2.5.

There is no interaction. LDAP transactions only affect write ops.

-- 
  -- Howard Chu
  CTO, Symas Corp.           http://www.symas.com
  Director, Highland Sun     http://highlandsun.com/hyc/
  Chief Architect, OpenLDAP  http://www.openldap.org/project/