错误详情如下
apache.solr.core.SolrResourceNotFoundException: Can't find resource 'solr-data-config.xml' in classpath or '/usr/sft/ranger-solr-8.10.1/ranger_audits'
at org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:402)
at org.apache.solr.handler.dataimport.DataImportHandler.handleRequestBody(DataImportHandler.java:145)
at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:216)
at org.apache.solr.core.SolrCore.execute(SolrCore.java:2637)
at org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:794)
at org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:567)
关键信息
apache.solr.core.SolrResourceNotFoundException: Can't find resource 'solr-data-config.xml' in classpath or '/usr/sft/ranger-solr-8.10.1/ranger_audits'
standlone版本安装了Solr-8.10.1,在启动时出现这个错误,之前也遇到过类似问题,都是在solr安装目录下找一个然后挪到对应目录上面去。
如下图示
然后把对应文件挪到目标目录下重启solr后问题解决
cp ./example/example-DIH/solr/solr/conf/solr-data-config.xml /usr/sft/ranger-solr-8.10.1/ranger_audits/conf/