快速业务通道

Linux 加入域的那些事儿!

作者 佚名技术 来源 Linux系统 浏览 发布时间 2012-03-29

说明:本文为LINUX加入WINDOWS域的具体情况作一些说明,关于如何加入到域,本文不再详述,仅提供一个配置样板,如果有不了解的,可以再查看相关文章.

*-====================-*
* Linux To Windows AD
*-====================-*

- 基本概念
* PDC - 主域控制器
* BDC - 备份域控制器
* KDC - 密钥颁发中心,Kerberos服务器
* PAM - 可插拨认证模块
* SRV - DNS服务资源记录
- 域模式
* PRC - LINUX以Windows2000/NT4样式加入到域中
* ADS - 活动目录,Windows2003,WindowsXP
* 混合 - 有最好的兼容性

- 软件包Sw
* Samba: yum install samba.* samba-common.* samba-winbind-client.*
* Winbind: yum install samba-winbind.*
* Samba4: yum install samba4.* ;A newer version of samba
* Kerberos5: yum install pam_krb5.* krb5-workstation.* krb5-libs.*
* ldconfig
* ldconfig -v | grep winbind
* ls /usr/lib/libnss_winbind.so

- 配置文件
- NSS: /etc/nsswitch.conf
; 指示系统如何查找系统配置文件
; ACTION=Modify
* password: files winbind
* group: files winbind

- Samba: /etc/smb.conf
; 与共享文件夹相关的配置
; DomainMode = ActiveDirectory
*-------------------------------*
[global]
client use spnego = no
server signing = auto
workgroup = CAMPUS
# The SHORT-DOMAIN name of your domain, you need to modify
wins support = yes
wins server = 10.0.0.4
# Controller of the domain, You need to modify it to your own
wins proxy = yes
security = ADS
# or AD,ADS,domain, DOMAIN is the RPC mode
acl compatibility = win2k
idmap uid = 16777216-33554431
# Set based on your user count
idmap gid = 16777216-33554431
password server = 10.0.0.4
# Domain Controller
map to guest = bad user
guest ok = no
realm = CAMPUS.COM
# You need to keep the same with file krb5.conf defined
# encrypt psswords = yes
# Encrypt PASS, not supported by some version of samba
winbind use default domain = yes
# winbind separator = %
template homedir = /home/%D/%U
# A mode 777 should be set on /home/%D
template shell = /bin/bash
[homes]
comment = %S
path =/home/%D/%S
writeable = yes
browsable = yes
; valid users = %S
valid users = CAMPUS/%S
*-------------------------------*

* Kerberos: /etc/krb5.conf
*-------------------------------*
[logging]
default = FILE:/var/log/krb5libs.log
kdc = FILE:/var/log/krb5kdc.log
admin_server = FILE:/var/log/kadmind.log
[libdefaults]
default_realm = CAMPUS.COM
dns_lookup_realm = false
dns_lookup_kdc = false
[realms]
CAMPUS.COM = {
kdc = ADS.CAMPUS.COM:88
admin_server = ADS.CAMPUS.COM:749
default_domain = campus.com
}
# This is a REALMS to DOMAIN MAPPING, REALMS Format is uppercase
[domain_realm]
.campus.com = CAMPUS.COM
campus.com = CAMPUS.COM
# Build the mapping
[kdc]
profile = /var/kerberos/krb5kdc/kdc.conf
[appdefaults]
pam = {
debug = false
ticket_lifetime = 36000
renew_lifetime = 36000
forwardable = true
krb4_convert = false
}
*-------------------------------*

* 重启samba: service smb restart
* 重启Winbind: service winbind restart
* 初

凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢!

分享到: 更多

Copyright ©1999-2011 厦门凌众科技有限公司 厦门优通互联科技开发有限公司 All rights reserved

地址(ADD):厦门软件园二期望海路63号701E(东南融通旁) 邮编(ZIP):361008

电话:0592-5908028 传真:0592-5908039 咨询信箱:web@lingzhong.cn 咨询OICQ:173723134

《中华人民共和国增值电信业务经营许可证》闽B2-20100024  ICP备案:闽ICP备05037997号