selftest: Use the correct smb.conf for ldbsearch
authorAndreas Schneider <asn@samba.org>
Fri, 17 Jun 2016 11:03:34 +0000 (13:03 +0200)
committerAndreas Schneider <asn@cryptomilk.org>
Fri, 17 Jun 2016 16:15:21 +0000 (18:15 +0200)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
selftest/target/Samba4.pm

index 184b9492e123de4166df5ad2668cf038093d13db..9d0b7496e7f4f942b8813d71530b5c14a9e39d9e 100755 (executable)
@@ -215,8 +215,9 @@ sub wait_for_start($$)
            my $base_dn = "DC=".join(",DC=", split(/\./, $testenv_vars->{REALM}));
            my $rid_set_dn = "cn=RID Set,cn=$testenv_vars->{NETBIOSNAME},ou=domain controllers,$base_dn";
            my $max_wait = 60;
+           my $cmd = "$ldbsearch $testenv_vars->{CONFIGURATION} -H ldap://$testenv_vars->{SERVER} -U$testenv_vars->{USERNAME}%$testenv_vars->{PASSWORD} -s base -b \"$rid_set_dn\" rIDAllocationPool";
            sleep(1);
-           while (system("$ldbsearch -H ldap://$testenv_vars->{SERVER} -U$testenv_vars->{USERNAME}%$testenv_vars->{PASSWORD} -s base -b \"$rid_set_dn\" rIDAllocationPool > /dev/null") != 0) {
+           while (system("$cmd >/dev/null") != 0) {
                $count++;
                if ($count > $max_wait) {
                    warn("Timed out ($max_wait sec) waiting for working LDAP and a RID Set to be allocated by $testenv_vars->{NETBIOSNAME} PID $testenv_vars->{SAMBA_PID}");