我无法通过“网络广告加入”(winbind)

时间:2018-11-13 22:14:49

标签: centos samba

我想使用Samba,winbind从CentOS 7连接到Windows Active Directory。 Samba已经在运行,但Winbind并未因log.winbindd出现以下错误而出错。

  

../ source3 / winbindd / winbindd_util.c:891(init_domain_list)

     

无法获取我们的SID-我们加入了吗?

我尝试“ net -d 10个广告加入-S dcserver -U poweruser”,然后获取错误日志。 什么参数无效?我没有在配置中写入什么参数? 我不知道此日志中写有“ dn”。

kerberos_kinit_password: as poweruser@DMNAME.OURCO.JP using [MEMORY:libnet_join_user_creds] as ccache and config [/var/lib/samba/lock/smb_krb5/krb5.conf.DMNAME]
Starting GENSEC mechanism spnego
Starting GENSEC submechanism gse_krb5
gse_get_client_auth_token: Server principal not found
SPNEGO(gse_krb5) creating NEG_TOKEN_INIT for ldap/dcserver failed (next[(null)]): NT_STATUS_INVALID_PARAMETER
Failed to setup SPNEGO negTokenInit request: NT_STATUS_INVALID_PARAMETER
kinit succeeded but ads_sasl_spnego_gensec_bind(KRB5) failed for ldap/dcserver with user[poweruser] realm[DMNAME.OURCO.JP]: An invalid parameter was passed to a service or function.
ads_sasl_spnego_gensec_bind(KRB5) failed for ldap/dcserver with user[poweruser] realm=[DMNAME.OURCO.JP]: An invalid parameter was passed to a service or function.
libnet_Join:
    libnet_JoinCtx: struct libnet_JoinCtx
        out: struct libnet_JoinCtx
            account_name             : 'MYCENTSV$'
            netbios_domain_name      : 'DMNAME'
            dns_domain_name          : 'dmname.OURCO.JP'
            forest_name              : 'dmname.OURCO.JP'
            dn                       : NULL
            domain_guid              : 4b8db2c2-43fd-4008-be4f-66ad75c21c2d
            domain_sid               : *
                domain_sid               : S-1-5-21-1645522239-789336058-839522115
            modified_config          : 0x00 (0)
            error_string             : 'failed to connect to AD: An invalid parameter was passed to a service or function.'
            domain_is_ad             : 0x01 (1)
            set_encryption_types     : 0x00000000 (0)
            krb5_salt                : NULL
            result                   : WERR_NERR_DEFAULTJOINREQUIRED
Failed to join domain: failed to connect to AD: An invalid parameter was passed to a service or function.
return code = -1
msg_dgm_ref_destructor: refs=(nil)

1 个答案:

答案 0 :(得分:0)

我自己解决了。 我不知道,但“ dcserver”是Active Directory中“ dcserver-1”的别名。 因此,在我将其替换为“ dcserver-1”-net ads join -S dcserver-1 -U poweruser后,它可以工作!

我想可能是在ldap配置中指定了“ dcserver-1”,但是由于我没有Active Directory管理的权限,所以我不确定。

谢谢。