[Samba] Recreating dns.keytab - dns-<user> issue

Maton, Brett matonb at ltresources.co.uk
Thu Sep 29 08:09:28 UTC 2016


  I'm trying to recreate dns.keytab for a DC but there seems to be a
database issue, delete says the dns user doesn't exist, but upgradedns says
it does.

CentOS 7.2
Samba  4.5.0

samba-tool user delete dns-dc01

ERROR(exception): Failed to remove user "dns-dc01" - Unable to find user
"/usr/local/samba/lib64/python2.7/site-packages/samba/netcmd/user.py", line
412, in run
  File "/usr/local/samba/lib64/python2.7/site-packages/samba/samdb.py",
line 479, in deleteuser
    raise Exception('Unable to find user "%s"' % username)

samba_upgradedns --dns-backend=BIND9_DLZ
Reading domain information
DNS accounts already exist
No zone file /usr/local/samba/private/dns/MYDOMAIN.COM.zone
DNS records will be automatically created
DNS partitions already exist
dns-dc01 account already exists
See /usr/local/samba/private/named.conf for an example configuration
include file for BIND
and /usr/local/samba/private/named.txt for further documentation required
for secure DNS updates
Finished upgrading DNS

klist -k /usr/local/samba/private/dns.keytab

Keytab name: FILE:/usr/local/samba/private/dns.keytab
klist: Key table file '/usr/local/samba/private/dns.keytab' not found while
starting keytab scan

Any help appreciated.

More information about the samba mailing list