首页 > 解决方案 > 索引器:java.io.IOException:作业失败

问题描述

我正在使用 Solr 5.4.1 和 Apache Nutch 1.12。我能够爬取数据,但在 Solr 索引的最后一步中,我遇到了以下错误。

 SOLRIndexWriter
    solr.server.url : URL of the SOLR instance
    solr.zookeeper.hosts : URL of the Zookeeper quorum
    solr.commit.size : buffer size when sending to SOLR (default 1000)
    solr.mapping.file : name of the mapping file for fields (default solrindex-mapping.xml)
    solr.auth : use authentication (default false)
    solr.auth.username : username for authentication
    solr.auth.password : password for authentication
SolrIndexer: deleting 1/1 documents
SolrIndexer: deleting 1/1 documents
Indexer: java.io.IOException: Job failed!
    at org.apache.hadoop.mapred.JobClient.runJob(JobClient.java:836)
    at org.apache.nutch.indexer.IndexingJob.index(IndexingJob.java:145)
    at org.apache.nutch.indexer.IndexingJob.run(IndexingJob.java:228)
    at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
    at org.apache.nutch.indexer.IndexingJob.main(IndexingJob.java:237)

标签: javasolrnutch

解决方案


确保您的索引名称全部小写。

检查 hbase_site.xml 中的 hbase.rootdir、hbase.data 和 hbase.zookeeper-data 以及日志文件路径是否正确。

最后,确保将 hbase_site.xml 复制到您的 nutch/conf 目录中。如果您正在运行 nutch 2.x,请在使用 ant 编译之前执行此操作,或者在它存在后重新编译(ant clean,ant runtime)。


推荐阅读