Monday, May 4, 2015

Error CREATEing SolrCore 'new_core': Unable to create core [new_core] Caused by: Can't find resource 'solrconfig.xml' in classpath..

if you are new to solr it is very likely that you may end up with the below error while creating the first core or I would say collection. 

org.apache.solr.common.SolrException: Error CREATEing SolrCore 'new_core': Unable to create core [new_core] Caused by: Can't find resource 'solrconfig.xml' in classpath or 'C:\SOLR\solr-5.1.0\server\solr\new_core\conf'

So what is the solution 

Easy : 

1. Create a folder name same as what you core name. I am creating a core called Collection1.. so my folder name would be Collection1. This should be created @ "C:\SOLR\solr-5.1.0\server\solr\Collection1@

2. Now navigate to "C:\SOLR\solr-5.1.0\server\solr\configsets\basic_configs" and copy the "conf" folder

3. Navigate back to Collection1 folder and paste the "conf" folder.. 


You are done.. you should now be able to create the core. 

Happy learning..