参考:
Joining Samba to a Windows 2008 R2 Domain (http://itscblog.tamu.edu/joining-samba-to-a-windows-2008-r2-domain/)
Linux加入Windows域之完美解决方案 (http://wenku.baidu.com/view/b680831014791711cc79179d.html)
CentOS使用Winbind与AD集成认证 (http://hi.baidu.com/jiasha2008/blog/item/0607620167d58c04738da5b7.html)
利用Samba做Linux和Windows整合 (http://wenku.baidu.com/view/d6fa146d58fafab069dc02e2.html)
总结:
走setup, 使用winbind验证
需要知道域控的机器名和有域管理员权限的帐号密码
net join -w 域名 -S 预控的全名 -U 拥有域管理员权限的帐号
net join -w XXXMASTER -S rnop-dci03.IS.AD.XXX.COM -U xxx
然后按照后面的命令来一遍
kinit domainuser@DOMAIN.COM
klist
net ads join -U domainadminuser
$ /etc/init.d/smb start
$ /etc/init.d/winbind start
$ chkconfig smb on
$ chkconfig winbind on
net ads keytab create -U domainadminuser
klist -ke
$ /etc/init.d/smb restart
$ /etc/init.d/winbind restart
net ads info
net ads testjoin
wbinfo -t
wbinfo -u
wbinfo -g
wbinfo -a domainuser
id domainuser
再加入下行自动创建啊home目录的到 /etc/pam.d/system-auth-ac
session required pam_mkhomedir.so silent skel=/etc/skel umask=0077
打完收工