Can’t find (or read) directory to add to classloader

Getting these error messages in Apache Solr administration interface when you tab logging?
Well, it’s most likely because you are using the example solrconfig.xml located in \Solr\Collection1\conf\solrconfig.xml.

Simply modify or out comment the following lines:

<lib dir="../../../contrib/extraction/lib" regex=".*\.jar"></lib>
<lib dir="../../../dist/" regex="solr-cell-\d.*\.jar"></lib>
 
<lib dir="../../../contrib/clustering/lib/" regex=".*\.jar"></lib>
<lib dir="../../../dist/" regex="solr-clustering-\d.*\.jar"></lib>
 
<lib dir="../../../contrib/langid/lib/" regex=".*\.jar"></lib>
<lib dir="../../../dist/" regex="solr-langid-\d.*\.jar"></lib>
 
<lib dir="../../../contrib/velocity/lib" regex=".*\.jar"></lib>
<lib dir="../../../dist/" regex="solr-velocity-\d.*\.jar"></lib>

You can find a issue ticket about this problem at Solr issue tracker.

12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../contrib/extraction/lib (resolved as: C:\Solr\collection1\..\..\..\contrib\extraction\lib).
12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../dist/ (resolved as: C:\Solr\collection1\..\..\..\dist).
12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../contrib/clustering/lib/ (resolved as: C:\Solr\collection1\..\..\..\contrib\clustering\lib).
12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../dist/ (resolved as: C:\Solr\collection1\..\..\..\dist).
12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../contrib/langid/lib/ (resolved as: C:\Solr\collection1\..\..\..\contrib\langid\lib).
12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../dist/ (resolved as: C:\Solr\collection1\..\..\..\dist).
12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../contrib/velocity/lib (resolved as: C:\Solr\collection1\..\..\..\contrib\velocity\lib).
12:57:57WARNSolrResourceLoaderCan’t find (or read) directory to add to classloader: ../../../dist/ (resolved as: C:\Solr\collection1\..\..\..\dist).