'Preamble: Stop DS running on port %s' % master.getPort() { 'location' : masterHost, 'dsPath' : masterPath, 'dsHost' : masterHost, 'dsAdminPort' : master.getAdminPort(), 'dsBindDN' : master.getRootDn(), 'dsBindPwd' : master.getRootPwd() } { 'location' : masterHost , 'entry' : ldifFile , 'attribute' : 'TYPE' } 'Preamble: File %s does not exist, create it' % ldifFile 'Preamble: Make an make-ldif template file' { 'suffix' : synchroSuffix, 'numEntries' : numberOfEntries , 'additionalAttributes' : True , 'extraLine' : 'userpassword: password' , 'templateFile' : ldifTemplate , 'templateLocation' : masterHost } 'Preamble: Make the ldif file' { 'location' : masterHost, 'dsPath' : masterPath, 'templateFile' : ldifTemplate , 'ldifFile' : ldifFile } 'Preamble: File %s exists, do nothing' % ldifFile 'Preamble: Import the ldif file' { 'location' : masterHost , 'dsPath' : masterPath, 'ldifFile' : ldifFile , 'backEnd' : 'userRoot' } 'Preamble: Start DS to run on port %s' % master.getPort() { 'location' : masterHost, 'dsPath' : masterPath } 'Preamble: Perform the total update' { 'location' : clientHost, 'dsPath' : clientPath, 'sourceInstanceHost' : masterHost, 'sourceInstanceAdminPort' : master.getAdminPort(), 'replicationDnList' : [synchroSuffix] } 'Preamble: Verify the tree synchronization' [ clientHost, clientPath, master, consumerList, synchroSuffix ] 'Test Name = %s' % STAXCurrentTestcase { 'stepMessage' : 'ModRate.' } { 'dsPath' : masterPath, 'dsInstanceHost' : masterHost, 'dsInstancePort' : master.getPort(), 'dsInstanceDn' : master.getRootDn(), 'dsInstancePswd' : master.getRootPwd(), 'dsBaseDN' : '"uid=user.%s,ou=People,o=example"', 'extraParams' : '-g "rand(0,%s)" -g "randstr(40)" -c 10' % (numberOfEntries - 1), 'attribute' : 'description' , 'formatString' : '"%s"', 'outputFile' : 'replication_modrate.res', 'outputPath' : remote.temp } { 'location' : masterHost , 'filename' : '%s/replication_modrate.res' % remote.temp } cmdResult 'Error found during modrate' { 'stepMessage' : 'Do search on the master.' } { 'dsPath' : masterPath, 'dsInstanceHost' : masterHost, 'dsInstancePort' : master.getPort(), 'dsInstanceDn' : master.getRootDn(), 'dsInstancePswd' : master.getRootPwd(), 'dsBaseDN' : synchroSuffix, 'dsFilter' : 'objectclass=*', 'dsAttributes' : 'dn' } { 'stepMessage' : 'Do search on the client.' } { 'dsPath' : clientPath, 'dsInstanceHost' : clientHost, 'dsInstancePort' : client.getPort(), 'dsInstanceDn' : client.getRootDn(), 'dsInstancePswd' : client.getRootPwd(), 'dsBaseDN' : synchroSuffix, 'dsFilter' : 'objectclass=*', 'dsAttributes' : 'dn' } { 'stepMessage' : 'Verify the tree synchronization.' } [ clientHost, clientPath, master, consumerList, synchroSuffix ] '%s: Test failed. eInfo(%s)' % (eType,eInfo) 'Test Name = %s' % STAXCurrentTestcase { 'stepMessage' : 'Addrate.' } { 'dsPath' : masterPath, 'dsInstanceHost' : masterHost, 'dsInstancePort' : master.getPort(), 'dsInstanceDn' : master.getRootDn(), 'dsInstancePswd' : master.getRootPwd(), 'templateFile' : addTemplate, 'extraParams' : '-g "inc(%s,%s)" -g "randstr(5)" -g "randstr(5)" -g "randstr(5)" -g "randstr(5)" -m 100000' \ % (numberOfEntries, 2 * numberOfEntries), 'outputFile' : 'replication_addrate.res', 'outputPath' : remote.temp } { 'location' : masterHost , 'filename' : '%s/replication_addrate.res' % remote.temp } cmdResult 'Error found during addrate' { 'stepMessage' : 'Do search on the master and check number of entries.' } { 'dsPath' : masterPath, 'dsInstanceHost' : masterHost, 'dsInstancePort' : master.getPort(), 'dsInstanceDn' : master.getRootDn(), 'dsInstancePswd' : master.getRootPwd(), 'dsCountEntries' : 'True' , 'dsBaseDN' : synchroSuffix, 'dsFilter' : 'objectclass=*', 'dsAttributes' : 'dn', 'outputFile' : 'ldapsearch_add_master.out' , 'outputPath' : remote.temp } { 'location' : STAF_REMOTE_HOSTNAME , 'filename' : '%s/ldapsearch_add_master.out' % remote.temp , 'testString': 'Total number of matching entries: 200002' } { 'stepMessage' : 'Do search on the client and check number of entries.' } { 'dsPath' : clientPath, 'dsInstanceHost' : clientHost, 'dsInstancePort' : client.getPort(), 'dsInstanceDn' : client.getRootDn(), 'dsInstancePswd' : client.getRootPwd(), 'dsCountEntries' : 'True' , 'dsBaseDN' : synchroSuffix, 'dsFilter' : 'objectclass=*', 'dsAttributes' : 'dn', 'outputFile' : 'ldapsearch_add_client.out' , 'outputPath' : remote.temp } { 'location' : STAF_REMOTE_HOSTNAME , 'filename' : '%s/ldapsearch_add_client.out' % remote.temp , 'testString': 'Total number of matching entries: 200002' } { 'stepMessage' : 'Verify the tree synchronization.' } [ clientHost, clientPath, master, consumerList, synchroSuffix ] '%s: Test failed. eInfo(%s)' % (eType,eInfo) 'Test Name = %s' % STAXCurrentTestcase { 'stepMessage' : 'DelRate.' } { 'dsPath' : masterPath, 'dsInstanceHost' : masterHost, 'dsInstancePort' : master.getPort(), 'dsInstanceDn' : master.getRootDn(), 'dsInstancePswd' : master.getRootPwd(), 'dsBaseDN' : '"uid=user.%s,ou=People,o=example"', 'extraParams' : '-g "inc(0,%s)" -m 100000' % (numberOfEntries - 1), 'outputFile' : 'replication_delrate.res', 'outputPath' : remote.temp } { 'location' : masterHost , 'filename' : '%s/replication_delrate.res' % remote.temp } cmdResult 'Error found during delrate' { 'stepMessage' : 'Do search on the master and check number of entries.' } { 'dsPath' : masterPath, 'dsInstanceHost' : masterHost, 'dsInstancePort' : master.getPort(), 'dsInstanceDn' : master.getRootDn(), 'dsInstancePswd' : master.getRootPwd(), 'dsCountEntries' : 'True' , 'dsBaseDN' : synchroSuffix, 'dsFilter' : 'objectclass=*', 'dsAttributes' : 'dn', 'outputFile' : 'ldapsearch_del_master.out' , 'outputPath' : remote.temp } { 'location' : STAF_REMOTE_HOSTNAME , 'filename' : '%s/ldapsearch_del_master.out' % remote.temp , 'testString': 'Total number of matching entries: 100002' } { 'stepMessage' : 'Do search on the client and check number of entries.' } { 'dsPath' : clientPath, 'dsInstanceHost' : clientHost, 'dsInstancePort' : client.getPort(), 'dsInstanceDn' : client.getRootDn(), 'dsInstancePswd' : client.getRootPwd(), 'dsCountEntries' : 'True' , 'dsBaseDN' : synchroSuffix, 'dsFilter' : 'objectclass=*', 'dsAttributes' : 'dn', 'outputFile' : 'ldapsearch_del_client.out' , 'outputPath' : remote.temp } { 'location' : STAF_REMOTE_HOSTNAME , 'filename' : '%s/ldapsearch_del_client.out' % remote.temp , 'testString': 'Total number of matching entries: 100002' } { 'stepMessage' : 'Verify the tree synchronization.' } [ clientHost, clientPath, master, consumerList, synchroSuffix ] '%s: Test failed. eInfo(%s)' % (eType,eInfo)