This bug has been migrated to another issue tracking site. It has been closed here and may no longer be being monitored.

If you would like to get updates for this issue, or to participate in it, you may do so at Red Hat Issue Tracker .
Bug 2245042 - Cannot compact the replication changelog using dsconf.
Summary: Cannot compact the replication changelog using dsconf.
Keywords:
Status: CLOSED MIGRATED
Alias: None
Product: Red Hat Directory Server
Classification: Red Hat
Component: 389-ds-base
Version: 11.7
Hardware: x86_64
OS: Linux
medium
high
Target Milestone: DS12.5
: dirsrv-12.5
Assignee: LDAP Maintainers
QA Contact: LDAP QA Team
Evgenia Martynyuk
URL:
Whiteboard: sync-to-jira
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-10-19 10:03 UTC by Têko Mihinto
Modified: 2024-06-26 13:50 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2024-06-26 13:50:16 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker   DIRSRV-63 0 None None Red Hat Issue Tracker 2024-06-26 13:50:15 UTC
Red Hat Issue Tracker IDMDS-4096 0 None None None 2024-01-29 09:06:53 UTC

Description Têko Mihinto 2023-10-19 10:03:35 UTC
Description of problem:
Attempts to compact a replication changelog with the dsconf CLI are not working.
The changelog is not compacted.

Version-Release number of selected component (if applicable):

$ cat /etc/redhat-release
Red Hat Enterprise Linux release 8.8 (Ootpa)
$
$ rpm -qa | grep 389-ds
389-ds-base-1.4.3.34-1.module+el8dsrv+18528+22f7779f.x86_64
389-ds-base-libs-1.4.3.34-1.module+el8dsrv+18528+22f7779f.x86_64
$

How reproducible:
Always.

Steps to Reproduce:
1. Run the step #5 documented here:
    https://access.redhat.com/documentation/en-us/red_hat_directory_server/11/html/administration_guide/trimming_the_replication_changelog#manually_trimming_changelog

$ date ; dsconf -D "cn=Directory Manager" ldap://localhost:1389 backend compact-db --only-changelog
Thu Oct 19 11:16:57 CEST 2023
Enter password for cn=Directory Manager on ldap://localhost:1389:
Successfully started Database Compaction Task
$

Try without the option "--only-changelog":

$ date ; dsconf -D "cn=Directory Manager" ldap://localhost:1389 backend compact-db
Thu Oct 19 11:18:09 CEST 2023
Enter password for cn=Directory Manager on ldap://localhost:1389:
Successfully started Database Compaction Task
$

2. Check the errors log:

There is no mention about replication changelogs:
==================================
[19/Oct/2023:11:17:04.769616210 +0200] - NOTICE - bdb_compact - Compacting databases ...
[19/Oct/2023:11:17:04.771539140 +0200] - NOTICE - bdb_do_compact - Compacting DB start: userroot
[19/Oct/2023:11:17:04.773374311 +0200] - NOTICE - bdb_do_compact - compact userroot - 0 pages freed
...
[19/Oct/2023:11:17:04.815161860 +0200] - NOTICE - bdb_do_compact - Compacting databases finished.
...
[19/Oct/2023:11:18:16.822617190 +0200] - NOTICE - bdb_compact - Compacting databases ...
[19/Oct/2023:11:18:16.826735586 +0200] - NOTICE - bdb_do_compact - Compacting DB start: userroot
...
[19/Oct/2023:11:18:16.871960536 +0200] - NOTICE - bdb_do_compact - Compacting databases finished.
==================================

3. Try with the "COMPACT_CL5" task:

$ date ; ldapmodify -x -D "cn=Directory Manager" -W -H ldaps://localhost:1636
Thu Oct 19 11:19:10 CEST 2023
Enter LDAP Password:
dn: cn=replica,cn=dc\3Dexample\2Cdc\3Dcom,cn=mapping tree,cn=config
changetype: modify
replace: nsds5task
nsds5task: COMPACT_CL5

modifying entry "cn=replica,cn=dc\3Dexample\2Cdc\3Dcom,cn=mapping tree,cn=config"

$

Now the replication changelogs are compacted:
==================================
[19/Oct/2023:11:19:23.859362246 +0200] - NOTICE - NSMMReplicationPlugin - changelog program - cl5CompactDBs - compacting replication changelogs...
[19/Oct/2023:11:19:23.867203066 +0200] - NOTICE - NSMMReplicationPlugin - changelog program - cl5CompactDBs - compacting replication changelogs finished.
==================================

Actual results:
Cannot compact replication changelogs with the dsconf tool.

Expected results:
The documented command should work as expected.

Additional info:

Audit log:
==================================
time: 20231019111704
dn: cn=compact_db_2023-10-19T11:17:00.748218,cn=compact db,cn=tasks,cn=config
result: 0
changetype: add
objectClass: top
objectClass: extensibleObject
justchangelog: yes
cn: compact_db_2023-10-19T11:17:00.748218
creatorsName: cn=directory manager
modifiersName: cn=directory manager
createTimestamp: 20231019091700Z
modifyTimestamp: 20231019091700Z

time: 20231019111816
dn: cn=compact_db_2023-10-19T11:18:12.800716,cn=compact db,cn=tasks,cn=config
result: 0
changetype: add
objectClass: top
objectClass: extensibleObject
cn: compact_db_2023-10-19T11:18:12.800716
creatorsName: cn=directory manager
modifiersName: cn=directory manager
createTimestamp: 20231019091812Z
modifyTimestamp: 20231019091812Z

time: 20231019111923
dn: cn=replica,cn=dc\3Dexample\2Cdc\3Dcom,cn=mapping tree,cn=config
result: 0
changetype: modify
replace: nsDS5Task
nsDS5Task: COMPACT_CL5
-
replace: modifiersname
modifiersname: cn=directory manager
-
replace: modifytimestamp
modifytimestamp: 20231019091923Z
-
==================================

Comment 5 Viktor Ashirov 2024-06-26 13:50:16 UTC
This BZ has been automatically migrated to Red Hat Issue Tracker https://issues.redhat.com/browse/DIRSRV-63. All future work related to this report will be managed there.

Due to differences in account names between systems, some fields were not replicated. Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information.

In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues. You can also visit https://access.redhat.com/articles/7032570 for general account information.


Note You need to log in before you can comment on or make changes to this bug.