summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--python/samba/provision/backend.py22
-rw-r--r--source4/setup/slapd.conf53
2 files changed, 72 insertions, 3 deletions
diff --git a/python/samba/provision/backend.py b/python/samba/provision/backend.py
index b50055de9f..58aab9829f 100644
--- a/python/samba/provision/backend.py
+++ b/python/samba/provision/backend.py
@@ -417,6 +417,8 @@ class OpenLDAPBackend(LDAPBackend):
mmr_serverids_config = ""
mmr_syncrepl_schema_config = ""
mmr_syncrepl_config_config = ""
+ mmr_syncrepl_domaindns_config = ""
+ mmr_syncrepl_forestdns_config = ""
mmr_syncrepl_user_config = ""
if self.ol_mmr_urls is not None:
@@ -456,6 +458,22 @@ class OpenLDAPBackend(LDAPBackend):
"MMR_PASSWORD": mmr_pass})
rid = rid + 1
+ mmr_syncrepl_domaindns_config += read_and_sub_file(
+ setup_path("mmr_syncrepl.conf"), {
+ "RID" : str(rid),
+ "MMRDN": "dc=DomainDNSZones," + self.names.domaindn,
+ "LDAPSERVER" : url,
+ "MMR_PASSWORD": mmr_pass})
+
+ rid = rid + 1
+ mmr_syncrepl_forestdns_config += read_and_sub_file(
+ setup_path("mmr_syncrepl.conf"), {
+ "RID" : str(rid),
+ "MMRDN": "dc=ForestDNSZones," + self.names.domaindn,
+ "LDAPSERVER" : url,
+ "MMR_PASSWORD": mmr_pass})
+
+ rid = rid + 1
mmr_syncrepl_user_config += read_and_sub_file(
setup_path("mmr_syncrepl.conf"), {
"RID" : str(rid),
@@ -508,6 +526,8 @@ class OpenLDAPBackend(LDAPBackend):
"MMR_SERVERIDS_CONFIG": mmr_serverids_config,
"MMR_SYNCREPL_SCHEMA_CONFIG": mmr_syncrepl_schema_config,
"MMR_SYNCREPL_CONFIG_CONFIG": mmr_syncrepl_config_config,
+ "MMR_SYNCREPL_DOMAINDNS_CONFIG": mmr_syncrepl_domaindns_config,
+ "MMR_SYNCREPL_FORESTDNS_CONFIG": mmr_syncrepl_forestdns_config,
"MMR_SYNCREPL_USER_CONFIG": mmr_syncrepl_user_config,
"OLC_SYNCREPL_CONFIG": olc_syncrepl_config,
"OLC_MMR_CONFIG": olc_mmr_config,
@@ -515,6 +535,8 @@ class OpenLDAPBackend(LDAPBackend):
"INDEX_CONFIG": index_config,
"NOSYNC": nosync_config})
+ self.setup_db_config(os.path.join(self.ldapdir, "db", "forestdns"))
+ self.setup_db_config(os.path.join(self.ldapdir, "db", "domaindns"))
self.setup_db_config(os.path.join(self.ldapdir, "db", "user"))
self.setup_db_config(os.path.join(self.ldapdir, "db", "config"))
self.setup_db_config(os.path.join(self.ldapdir, "db", "schema"))
diff --git a/source4/setup/slapd.conf b/source4/setup/slapd.conf
index c2d92eca39..2eb65a3773 100644
--- a/source4/setup/slapd.conf
+++ b/source4/setup/slapd.conf
@@ -81,12 +81,13 @@ access to dn.sub="cn=config"
########################################
### cn=schema ###
-database hdb
+database mdb
suffix ${SCHEMADN}
rootdn cn=Manager,${SCHEMADN}
directory ${LDAPDIR}/db/schema
${NOSYNC}
${INDEX_CONFIG}
+maxsize 1073741824
#syncprov is stable in OpenLDAP 2.3, and available in 2.2.
#We need this for the contextCSN attribute and mmr.
@@ -102,12 +103,13 @@ ${MIRRORMODE}
#########################################
### cn=config ###
-database hdb
+database mdb
suffix ${CONFIGDN}
rootdn cn=Manager,${CONFIGDN}
directory ${LDAPDIR}/db/config
${NOSYNC}
${INDEX_CONFIG}
+maxsize 1073741824
#syncprov is stable in OpenLDAP 2.3, and available in 2.2.
#We need this for the contextCSN attribute and mmr.
@@ -122,13 +124,58 @@ ${MMR_SYNCREPL_CONFIG_CONFIG}
${MIRRORMODE}
########################################
+### domaindns
+database mdb
+suffix dc=domaindnszones,${DOMAINDN}
+rootdn cn=Manager,${DOMAINDN}
+directory ${LDAPDIR}/db/domaindns
+${NOSYNC}
+${INDEX_CONFIG}
+maxsize 1073741824
+
+#syncprov is stable in OpenLDAP 2.3, and available in 2.2.
+#We need this for the contextCSN attribute and mmr.
+overlay syncprov
+syncprov-sessionlog 100
+syncprov-checkpoint 100 10
+
+overlay rdnval
+
+### Multimaster-Replication of domainDNS context ###
+${MMR_SYNCREPL_DOMAINDNS_CONFIG}
+${MIRRORMODE}
+
+########################################
+### forestdns ###
+database mdb
+suffix dc=forestdnszones,${DOMAINDN}
+rootdn cn=Manager,${DOMAINDN}
+directory ${LDAPDIR}/db/forestdns
+${NOSYNC}
+${INDEX_CONFIG}
+maxsize 1073741824
+
+#syncprov is stable in OpenLDAP 2.3, and available in 2.2.
+#We need this for the contextCSN attribute and mmr.
+overlay syncprov
+syncprov-sessionlog 100
+syncprov-checkpoint 100 10
+
+overlay rdnval
+
+### Multimaster-Replication of forestDNS context ###
+${MMR_SYNCREPL_FORESTDNS_CONFIG}
+${MIRRORMODE}
+
+########################################
### cn=users /base-dn ###
-database hdb
+database mdb
suffix ${DOMAINDN}
rootdn cn=Manager,${DOMAINDN}
directory ${LDAPDIR}/db/user
${NOSYNC}
${INDEX_CONFIG}
+maxsize 1073741824
#syncprov is stable in OpenLDAP 2.3, and available in 2.2.
#We need this for the contextCSN attribute and mmr.