# krb服务器
yum -y install krb5-server openldap-clients
# 客户端
yum -y install krb5-devel krb5-workstation
配置krb5.conf
/etc/krb5.conf
# Configuration snippets may be placed in this directory as well
includedir /etc/krb5.conf.d/
[logging]
default = FILE:/var/log/krb5libs.log
kdc = FILE:/var/log/krb5kdc.log
admin_server = FILE:/var/log/kadmind.log
[libdefaults]
default_realm = FOO.COM
dns_lookup_realm = false
ticket_lifetime = 24h
renew_lifetime = 7d
forwardable = true
rdns = false
pkinit_anchors = FILE:/etc/pki/tls/certs/ca-bundle.crt
default_ccache_name = KEYRING:persistent:%{uid}
[realms]
DTSTACK.COM = {
kdc = host1
admin_server = host1
}
[domain_realm]
.foo.com = FOO.COM
foo.com = FOO.COM
*分发krb5.conf至所有client: 这部CDH会帮着做,所以可以跳过
pscp -h slaves krb5.conf /tmp
pssh -h slaves "cp /tmp/krb5.conf /etc"
配置kdc.conf
/var/kerberos/krb5kdc/kdc.conf
[kdcdefaults]
kdc_ports = 88
kdc_tcp_ports = 88
[realms]
FOO.COM = {
#master_key_type = aes256-cts
acl_file = /var/kerberos/krb5kdc/kadm5.acl
dict_file = /usr/share/dict/words
admin_keytab = /var/kerberos/krb5kdc/kadm5.keytab
supported_enctypes = aes128-cts:normal des3-hmac-sha1:normal arcfour-hmac:normal camellia256-cts:normal camellia128-cts:normal des-hmac-sha1:normal des-cbc-md5:normal des-cbc-crc:normal
max_life = 25h
max_renewable_life = 8d
}
参考
https://blog.csdn.net/u011026329/article/details/79167884
JCE问题
Encryption type AES256CTS mode with HMAC SHA1-96 is not supported/enabled
locate 'jre/lib/security' | grep 'lib/security$'
/usr/java/jdk1.7.0_67-cloudera/jre/lib/security
pscp UnlimitedJCEPolicy/*.jar /usr/java/jdk1.7.0_67-cloudera/jre/lib/security