From 4a77a1f6a2f1c8ddd53c1bed792d56a46d6bf456 Mon Sep 17 00:00:00 2001 From: Valera V Harseko Date: Thu, 25 Jun 2026 20:46:15 +0300 Subject: [PATCH] Fix duplicate SNMP connection handler entries in packaged config.ldif The `snmp` profile assembles the server template config.ldif in two antrun steps: `copy-config-ldif` copies the pristine resource/config/config.ldif into target/template/config, and `generate-config-ldif` appends config.snmp.ldif to it with `concat append="true"`. The copy used Ant's default `overwrite="false"`, so on an incremental build (without `clean`) the already-populated target file was newer than the source and was not refreshed, while the concat appended the SNMP fragment again on every build. Repeated builds therefore accumulated several `cn=SNMP Connection Handler,cn=Connection Handlers,cn=config` entries, and `setup` then failed with "Entry Already Exists ... multiple times". Add `overwrite="true"` to the config.ldif copy so the SNMP fragment is always appended to a freshly copied base file, making config.ldif generation idempotent regardless of incremental builds. --- opendj-server-legacy/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opendj-server-legacy/pom.xml b/opendj-server-legacy/pom.xml index 9d53b1d0bc..53024af3db 100644 --- a/opendj-server-legacy/pom.xml +++ b/opendj-server-legacy/pom.xml @@ -1107,7 +1107,7 @@ generate-resources - +