本文整理汇总了Python中bug_harness.DSAdminHarness.createAndSetupReplica方法的典型用法代码示例。如果您正苦于以下问题:Python DSAdminHarness.createAndSetupReplica方法的具体用法?Python DSAdminHarness.createAndSetupReplica怎么用?Python DSAdminHarness.createAndSetupReplica使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类bug_harness.DSAdminHarness
的用法示例。
在下文中一共展示了DSAdminHarness.createAndSetupReplica方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1:
# 需要导入模块: from bug_harness import DSAdminHarness [as 别名]
# 或者: from bug_harness.DSAdminHarness import createAndSetupReplica [as 别名]
'suffix': basedn,
'bename': "userRoot",
'binddn': "cn=replrepl,cn=config",
'bindcn': "replrepl",
'bindpw': "replrepl",
'bindmethod': 'SASL/GSSAPI',
'starttls': True,
'log' : False
}
#os.environ['USE_DBX'] = "1"
m1 = DSAdmin.createAndSetupReplica({
'newrootpw': 'password',
'newhost': host1,
'newport': port1,
'newinst': 'm1',
'newsuffix': basedn,
'verbose': False,
'no_admin': True
}, m1replargs
)
#del os.environ['USE_DBX']
m2replargs = m1replargs
#os.environ['USE_DBX'] = 1
m2 = DSAdmin.createAndSetupReplica({
'newrootpw': 'password',
'newhost': host2,
'newport': port2,
'newinst': 'm2',
'newsuffix': basedn,
示例2:
# 需要导入模块: from bug_harness import DSAdminHarness [as 别名]
# 或者: from bug_harness.DSAdminHarness import createAndSetupReplica [as 别名]
'ConfigFile': configfile,
'no_admin': True
}
m1replargs = {
'suffix': basedn,
'bename': "userRoot",
'binddn': "cn=replrepl,cn=config",
'bindcn': "replrepl",
'bindpw': "replrepl",
'bindmethod': 'SASL/GSSAPI',
'log' : False
}
#os.environ['USE_GDB'] = "1"
m1 = DSAdmin.createAndSetupReplica(hostargs, m1replargs)
#del os.environ['USE_GDB']
hostargs['newhost'] = host2
hostargs['newport'] = port2
hostargs['newinst'] = 'm2'
m2replargs = m1replargs
m2 = DSAdmin.createAndSetupReplica(hostargs, m2replargs)
hostargs['newhost'] = host3
hostargs['newport'] = port3
hostargs['newinst'] = 'm3'
m3replargs = m2replargs
m3 = DSAdmin.createAndSetupReplica(hostargs, m3replargs)
示例3:
# 需要导入模块: from bug_harness import DSAdminHarness [as 别名]
# 或者: from bug_harness.DSAdminHarness import createAndSetupReplica [as 别名]
'winsync': True,
'newwingroups': 'true',
'log': False
}
configfile = []
schemafile = []
#os.environ['USE_VALGRIND'] = "1"
os.environ['USE_GDB'] = "1"
ds = DSAdmin.createAndSetupReplica({
'newrootpw': rootpw1,
'newhost': host1,
'newport': port1,
'newinst': 'ds',
'newsuffix': suffix,
'verbose': False,
'no_admin': True,
'ConfigFile': configfile,
'SchemaFile': schemafile
}, replargs
)
#os.environ['USE_VALGRIND'] = ''
#os.environ.pop('USE_VALGRIND')
#try:
# foo = os.environ['USE_VALGRIND']
#except KeyError:
# print "should no longer have USE_VALGRIND env. var"
if useds:
ad = DSAdmin.createInstance({
'newrootpw': rootpw2,
示例4:
# 需要导入模块: from bug_harness import DSAdminHarness [as 别名]
# 或者: from bug_harness.DSAdminHarness import createAndSetupReplica [as 别名]
#os.environ['USE_DBX'] = "1"
m1replargs = {
'suffix': "dc=example,dc=com",
'bename': "userRoot",
'binddn': "cn=replrepl,cn=config",
'bindcn': "replrepl",
'bindpw': "replrepl"
}
m1 = DSAdmin.createAndSetupReplica({
'cfgdshost': host1,
'cfgdsport': cfgport,
'cfgdsuser': 'admin',
'cfgdspwd': 'admin',
'newrootpw': 'password',
'newhost': host1,
'newport': port1,
'newinst': 'm1',
'newsuffix': 'dc=example,dc=com',
'verbose': True,
'have_admin': True
}, m1replargs)
#del os.environ['USE_DBX']
#os.environ['USE_DBX'] = 1
m2replargs = {
'suffix': "dc=example,dc=com",
'bename': "userRoot",
'binddn': "cn=replrepl,cn=config",
'bindcn': "replrepl",
'bindpw': "replrepl"
示例5:
# 需要导入模块: from bug_harness import DSAdminHarness [as 别名]
# 或者: from bug_harness.DSAdminHarness import createAndSetupReplica [as 别名]
basedn = 'dc=example,dc=com'
replargs = {}
srvs = []
m1replargs = {
'suffix': basedn,
'bename': "userRoot",
'binddn': "cn=replrepl,cn=config",
'bindcn': "replrepl",
'bindpw': "replrepl"
}
os.environ['USE_GDB'] = "1"
m1 = DSAdmin.createAndSetupReplica({
'newrootpw': 'password',
'newhost': host1,
'newport': port1,
'newinst': 'm1',
'newsuffix': basedn,
'no_admin': True
}, m1replargs
)
del os.environ['USE_GDB']
replargs[m1] = m1replargs
srvs.append(m1)
m2replargs = m1replargs
m2 = DSAdmin.createAndSetupReplica({
'newrootpw': 'password',
'newhost': host2,
'newport': port2,
'newinst': 'm2',
'newsuffix': basedn,
示例6:
# 需要导入模块: from bug_harness import DSAdminHarness [as 别名]
# 或者: from bug_harness.DSAdminHarness import createAndSetupReplica [as 别名]
m1replargs = {
'suffix': "dc=example,dc=com",
'bename': "userRoot",
'binddn': "cn=replrepl,cn=config",
'bindcn': "replrepl",
'bindpw': "replrepl",
'log' : True
}
#os.environ['USE_DBX'] = "1"
m1 = DSAdmin.createAndSetupReplica({
'newrootpw': 'password',
'newhost': host1,
'newport': cfgport+10,
'newinst': 'm1',
'newsuffix': 'dc=example,dc=com',
'verbose': True,
'no_admin': True
}, m1replargs
)
#del os.environ['USE_DBX']
m2replargs = {
'suffix': "dc=example,dc=com",
'bename': "userRoot",
'binddn': "cn=replrepl,cn=config",
'bindcn': "replrepl",
'bindpw': "replrepl",
'log' : True
}
#os.environ['USE_DBX'] = 1