summaryrefslogtreecommitdiff
path: root/source4/scripting
diff options
context:
space:
mode:
Diffstat (limited to 'source4/scripting')
-rw-r--r--source4/scripting/python/samba/netcmd/domain.py10
-rw-r--r--source4/scripting/python/samba/netcmd/fsmo.py2
2 files changed, 6 insertions, 6 deletions
diff --git a/source4/scripting/python/samba/netcmd/domain.py b/source4/scripting/python/samba/netcmd/domain.py
index f7e060f730..0ab35a63aa 100644
--- a/source4/scripting/python/samba/netcmd/domain.py
+++ b/source4/scripting/python/samba/netcmd/domain.py
@@ -164,7 +164,7 @@ class cmd_domain_level(Command):
domain_dn = samdb.domain_dn()
- res_forest = samdb.search("CN=Partitions," + samdb.get_config_basedn(),
+ res_forest = samdb.search("CN=Partitions,%s" % samdb.get_config_basedn(),
scope=ldb.SCOPE_BASE, attrs=["msDS-Behavior-Version"])
assert len(res_forest) == 1
@@ -172,7 +172,7 @@ class cmd_domain_level(Command):
attrs=["msDS-Behavior-Version", "nTMixedDomain"])
assert len(res_domain) == 1
- res_dc_s = samdb.search("CN=Sites," + samdb.get_config_basedn(),
+ res_dc_s = samdb.search("CN=Sites,%s" % samdb.get_config_basedn(),
scope=ldb.SCOPE_SUBTREE, expression="(objectClass=nTDSDSA)",
attrs=["msDS-Behavior-Version"])
assert len(res_dc_s) >= 1
@@ -279,7 +279,7 @@ class cmd_domain_level(Command):
samdb.modify(m)
# Under partitions
m = ldb.Message()
- m.dn = ldb.Dn(samdb, "CN=" + lp.get("workgroup") + ",CN=Partitions," + ldb.get_config_basedn())
+ m.dn = ldb.Dn(samdb, "CN=" + lp.get("workgroup") + ",CN=Partitions,%s" % ldb.get_config_basedn())
m["nTMixedDomain"] = ldb.MessageElement("0",
ldb.FLAG_MOD_REPLACE, "nTMixedDomain")
try:
@@ -298,7 +298,7 @@ class cmd_domain_level(Command):
# Under partitions
m = ldb.Message()
m.dn = ldb.Dn(samdb, "CN=" + lp.get("workgroup")
- + ",CN=Partitions," + ldb.get_config_basedn())
+ + ",CN=Partitions,%s" % ldb.get_config_basedn())
m["msDS-Behavior-Version"]= ldb.MessageElement(
str(new_level_domain), ldb.FLAG_MOD_REPLACE,
"msDS-Behavior-Version")
@@ -323,7 +323,7 @@ class cmd_domain_level(Command):
if new_level_forest > level_domain:
raise CommandError("Forest function level can't be higher than the domain function level(s). Please raise it/them first!")
m = ldb.Message()
- m.dn = ldb.Dn(samdb, "CN=Partitions," + ldb.get_config_basedn())
+ m.dn = ldb.Dn(samdb, "CN=Partitions,%s" % ldb.get_config_basedn())
m["msDS-Behavior-Version"]= ldb.MessageElement(
str(new_level_forest), ldb.FLAG_MOD_REPLACE,
"msDS-Behavior-Version")
diff --git a/source4/scripting/python/samba/netcmd/fsmo.py b/source4/scripting/python/samba/netcmd/fsmo.py
index 78a2014825..06a2de1c2c 100644
--- a/source4/scripting/python/samba/netcmd/fsmo.py
+++ b/source4/scripting/python/samba/netcmd/fsmo.py
@@ -139,7 +139,7 @@ class cmd_fsmo_show(Command):
domain_dn = samdb.domain_dn()
self.infrastructure_dn = "CN=Infrastructure," + domain_dn
- self.naming_dn = "CN=Partitions," + samdb.get_config_basedn()
+ self.naming_dn = "CN=Partitions,%s" % samdb.get_config_basedn()
self.schema_dn = samdb.get_schema_basedn()
self.rid_dn = "CN=RID Manager$,CN=System," + domain_dn