本帖最后由 lyxing 于 2015-10-11 13:25 编辑
请问这是错在哪儿? 配置文件如下 : cat /etc/default/solrSOLR_PORT=8983SOLR_ADMIN_PORT=8984
SOLR_LOG=/var/log/solr
SOLR_ZK_ENSEMBLE=host-172-17-110-81:2181/solr
SOLR_HDFS_HOME=hdfs://hadoop-jkzl:8020/solr
SOLR_HDFS_CONFIG=/etc/hadoop/conf
SOLR_KERBEROS_ENABLED=true
SOLR_KERBEROS_KEYTAB=/etc/solr/conf/solr.keytab
SOLR_KERBEROS_PRINCIPAL=solr/host-172-17-110-81@JKZL
#SOLR_AUTHENTICATION_TYPE=simple
SOLR_AUTHENTICATION_TYPE=kerberos
SOLR_AUTHENTICATION_SIMPLE_ALLOW_ANON=true
SOLR_AUTHENTICATION_KERBEROS_KEYTAB=/etc/solr/conf/solr.keytab
SOLR_AUTHENTICATION_KERBEROS_PRINCIPAL=HTTP/host-172-17-110-81@JKZL
SOLR_AUTHENTICATION_KERBEROS_NAME_RULES=DEFAULT
SOLR_AUTHENTICATION_JAAS_CONF=/etc/solr/conf/jaas.conf
cat /etc/solr/conf/jaas.conf
Client { com.sun.security.auth.module.Krb5LoginModule required
useKeyTab=true
useTicketCache=false
keyTab="/etc/solr/conf/solr.keytab"
principal="solr/host-172-17-110-81@JKZL";
};
ls -l /etc/solr/conf/solr.keytab
-r--------. 1 solr hadoop 1642 Oct 8 07:50 /etc/solr/conf/solr.keytab
more hbase-indexer-site.xml
<?xml version="1.0"?>
<configuration>
<property>
<name>hbase.zookeeper.quorum</name>
<value>host-172-17-110-49,host-172-17-110-77,host-172-17-110-78</value>
</property>
<property>
<name>hbaseindexer.zookeeper.connectstring</name>
<value>host-172-17-110-49,host-172-17-110-77,host-172-17-110-78:2181</value>
</property>
<property>
<name>hbaseindexer.authentication.type</name>
<value>kerberos</value>
</property>
<property>
<name>hbaseindexer.authentication.kerberos.keytab</name>
<value>/etc/hbase/conf/hbase.keytab</value>
</property>
<property>
<name>hbaseindexer.authentication.kerberos.principal</name>
<value>HTTP/host-172-17-110-81@JKZL</value>
</property>
<property>
<name>hbaseindexer.authentication.kerberos.name.rules</name>
<value>DEFAULT</value>
</property>
</configuration>
more /etc/hbase-solr/conf/jaas.conf
Client {
com.sun.security.auth.module.Krb5LoginModule required
useKeyTab=true
useTicketCache=false
keyTab="/etc/hbase/conf/hbase.keytab"
principal="hbase/host-172-17-110-81@JKZL";
};
grep login hbase-indexer-env.sh
export HBASE_INDEXER_OPTS="$HBASE_INDEXER_OPTS -XX:+UseConcMarkSweepGC -Djava.security.auth.login.config=/etc/hbase-solr/conf/jaas.conf"我使用命令add-indexer ,hbase-solr's 日志出现如下错误: 15/10/10 03:19:41 INFO zookeeper.ZooKeeper: Initiating client connection, connectString=host-172-17-110-77:2181,host-172-17-110-49:2181,host-172-17-110-78:2181 sessionTimeout=90000 watcher=host-172-17-110-81,57865,14444471812720x0, quorum=host-172-17-110-77:2181,host-172-17-110-49:2181,host-172-17-110-78:2181, baseZNode=/hbase
15/10/10 03:19:41 INFO client.ZooKeeperSaslClient: Client will use GSSAPI as SASL mechanism.
15/10/10 03:19:41 DEBUG client.ZooKeeperSaslClient: creating sasl client: client=hbase/host-172-17-110-81@JKZL;service=zookeeper;serviceHostname=host-172-17-110-49
15/10/10 03:19:41 ERROR supervisor.IndexerSupervisor: Problem starting indexer myIndexer
java.io.IOException: Running in secure mode, but config doesn't have a keytab
at org.apache.hadoop.security.SecurityUtil.login(SecurityUtil.java:236)
at org.apache.hadoop.hbase.security.User$SecureHadoopUser.login(User.java:383)
at org.apache.hadoop.hbase.security.User.login(User.java:250)
at com.ngdata.sep.impl.SepConsumer.<init>(SepConsumer.java:163)
at com.ngdata.hbaseindexer.supervisor.IndexerSupervisor.startIndexer(IndexerSupervisor.java:234)
at com.ngdata.hbaseindexer.supervisor.IndexerSupervisor.access$1000(IndexerSupervisor.java:78)
at com.ngdata.hbaseindexer.supervisor.IndexerSupervisor$EventWorker.run(IndexerSupervisor.java:407)
at java.lang.Thread.run(Thread.java:745)
|
|