mirror of
https://github.com/samba-team/samba.git
synced 2025-01-12 09:18:10 +03:00
selftest: Wait for the logon server to register to join the member.
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
cfb67cf623
commit
35495da4b8
@ -242,6 +242,8 @@ sub setup_s3dc($$)
|
||||
sub setup_member($$$)
|
||||
{
|
||||
my ($self, $prefix, $s3dcvars) = @_;
|
||||
my $count = 0;
|
||||
my $rc;
|
||||
|
||||
print "PROVISIONING MEMBER...";
|
||||
|
||||
@ -257,6 +259,21 @@ sub setup_member($$$)
|
||||
|
||||
$ret or return undef;
|
||||
|
||||
my $nmblookup = Samba::bindir_path($self, "nmblookup");
|
||||
do {
|
||||
print "Waiting for the LOGON SERVER registration ...\n";
|
||||
$rc = system("$nmblookup $ret->{CONFIGURATION} $ret->{DOMAIN}\#1c");
|
||||
if ($rc != 0) {
|
||||
sleep(1);
|
||||
}
|
||||
$count++;
|
||||
} while ($rc != 0 && $count < 10);
|
||||
if ($count == 10) {
|
||||
print "NMBD not reachable after 10 retries\n";
|
||||
teardown_env($self, $ret);
|
||||
return 0;
|
||||
}
|
||||
|
||||
my $net = Samba::bindir_path($self, "net");
|
||||
my $cmd = "";
|
||||
$cmd .= "SOCKET_WRAPPER_DEFAULT_IFACE=\"$ret->{SOCKET_WRAPPER_DEFAULT_IFACE}\" ";
|
||||
|
Loading…
Reference in New Issue
Block a user