t.chdir('${PREFIX}')
t.del_files(["var", "private"])
t.run_cmd("rm -f etc/smb.conf")
- provision=['sbin/provision',
+ provision=['bin/samba-tool',
+ 'domain',
+ 'provision',
'--realm=${LCREALM}',
'--domain=${DOMAIN}',
'--adminpass=${PASSWORD1}',
'--host-ip=${INTERFACE_IP}',
'--option=bind interfaces only=yes',
'--option=rndc command=${RNDC} -c${PREFIX}/etc/rndc.conf',
- '${USE_NTVFS}',
'--dns-backend=${NAMESERVER_BACKEND}',
- '${ALLOW_DNS_UPDATES}',
- '${DNS_RECURSIVE_QUERIES}',
'${DNS_FORWARDER}']
+ if t.getvar('USE_NTVFS'):
+ provision.append('${USE_NTVFS}')
+
if t.getvar('INTERFACE_IPV6'):
provision.append('--host-ip6=${INTERFACE_IPV6}')
t.run_cmd(provision)
t.chdir("${PREFIX}")
t.run_cmd('killall -9 -q samba smbd nmbd winbindd', checkfail=False)
t.run_cmd(['sbin/samba',
- '--option', 'panic action=gnome-terminal -e "gdb --pid %d"'])
+ '--option', 'panic action=gnome-terminal -e "gdb --pid %d"', '--option', 'max protocol=nt1'])
t.port_wait("${INTERFACE_IP}", 139)
def test_smbclient(t):
t.info('Testing smbclient')
smbclient = t.getvar("smbclient")
t.chdir('${PREFIX}')
- t.cmd_contains("%s --version" % (smbclient), ["Version 4.0"])
+ t.cmd_contains("%s --version" % (smbclient), ["Version 4.1"])
t.retry_cmd('%s -L ${INTERFACE_IP} -U%%' % (smbclient), ["netlogon", "sysvol", "IPC Service"])
child = t.pexpect_spawn('%s //${INTERFACE_IP}/netlogon -Uadministrator%%${PASSWORD1}' % (smbclient))
child.expect("smb:")
child.expect("C:")
child.expect("C:")
child.sendline("dcpromo /answer:answers.txt")
- i = child.expect(["You must restart this computer", "failed", "Active Directory Domain Services was not installed", "C:"], timeout=120)
+ i = child.expect(["You must restart this computer", "failed", "Active Directory Domain Services was not installed", "C:"], timeout=240)
if i == 1 or i == 2:
child.sendline("echo off")
child.sendline("echo START DCPROMO log")
smbclient = t.getvar("smbclient")
t.chdir('${PREFIX}')
t.port_wait("${WIN_IP}", 139)
- t.retry_cmd("host -t A ${WIN_HOSTNAME}.${LCREALM}. ${INTERFACE_IP}",
+ t.retry_cmd("host -t A ${WIN_HOSTNAME}.${LCREALM}. ${NAMED_INTERFACE_IP}",
['${WIN_HOSTNAME}.${LCREALM} has address'],
retries=30, delay=10, casefold=True)
t.retry_cmd('%s -L ${WIN_HOSTNAME}.${LCREALM} -Uadministrator@${LCREALM}%%${PASSWORD1}' % (smbclient), ["C$", "IPC$", "Sharename"])
# we don't need fsync safety in these tests
t.putenv('TDB_NO_FSYNC', '1')
- if not t.getvar('NAMESERVER_BACKEND') == 'SAMBA_INTERNAL':
- if not t.skip("configure_bind"):
- t.configure_bind(kerberos_support=True, include='${PREFIX}/private/named.conf')
- if not t.skip("stop_bind"):
- t.stop_bind()
+ if not t.skip("configure_bind"):
+ t.configure_bind(kerberos_support=True, include='${PREFIX}/private/named.conf')
+ if not t.skip("stop_bind"):
+ t.stop_bind()
if not t.skip("stop_vms"):
t.stop_vms()
if not t.skip("smbclient"):
test_smbclient(t)
- t.set_nameserver(t.getvar('INTERFACE_IP'))
-
- if not t.getvar('NAMESERVER_BACKEND') == 'SAMBA_INTERNAL':
- if not t.skip("configure_bind2"):
- t.configure_bind(kerberos_support=True, include='${PREFIX}/private/named.conf')
- if not t.skip("start_bind"):
- t.start_bind()
+ if not t.skip("configure_bind2"):
+ t.configure_bind(kerberos_support=True, include='${PREFIX}/private/named.conf')
+ if not t.skip("start_bind"):
+ t.start_bind()
if not t.skip("dns"):
test_dns(t)