Uploaded image for project: 'Alfresco One Platform'
  1. Alfresco One Platform
  2. ACE-2421

SOLR4: unattended (non-Maven) war run, incomplete archive core configuration

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 5.0
    • Fix Version/s: 5.0
    • Labels:
    • Environment:
      Enterprise 5.0.0 (r78988-b52), solr4 from HEAD r 79022

      Description

      Attempt to deploy solr4 to existing tomcat instance (from the installer) fails with the following:

      12:55:34,202 ERROR [org.apache.solr.core.CoreContainer] [coreLoadExecutor-4-thread-1] Unable to create core: collection1
      org.apache.solr.common.SolrException: Could not load core configuration for core collection1
      	at org.apache.solr.core.ConfigSetService.getConfig(ConfigSetService.java:66)
      	at org.apache.solr.core.CoreContainer.create(CoreContainer.java:554)
      	at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:261)
      	at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:253)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: org.apache.solr.common.SolrException: Error loading solr config from solr/collection1\solrconfig.xml
      	at org.apache.solr.core.SolrConfig.readFromResourceLoader(SolrConfig.java:148)
      	at org.apache.solr.core.ConfigSetService.createSolrConfig(ConfigSetService.java:79)
      	at org.apache.solr.core.ConfigSetService.getConfig(ConfigSetService.java:61)
      	... 9 more
      Caused by: java.io.IOException: Can't find resource 'solrconfig.xml' in classpath or 'D:\alfresco\solr\collection1\conf'
      	at org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:362)
      	at org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:308)
      	at org.apache.solr.core.Config.<init>(Config.java:116)
      	at org.apache.solr.core.Config.<init>(Config.java:86)
      	at org.apache.solr.core.SolrConfig.<init>(SolrConfig.java:161)
      	at org.apache.solr.core.SolrConfig.readFromResourceLoader(SolrConfig.java:144)
      	... 11 more
      12:55:34,218 ERROR [org.apache.solr.core.CoreContainer] [coreLoadExecutor-4-thread-1] null:org.apache.solr.common.SolrException: Unable to create core: collection1
      	at org.apache.solr.core.CoreContainer.recordAndThrow(CoreContainer.java:911)
      	at org.apache.solr.core.CoreContainer.create(CoreContainer.java:568)
      	at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:261)
      	at org.apache.solr.core.CoreContainer$1.call(CoreContainer.java:253)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: org.apache.solr.common.SolrException: Could not load core configuration for core collection1
      	at org.apache.solr.core.ConfigSetService.getConfig(ConfigSetService.java:66)
      	at org.apache.solr.core.CoreContainer.create(CoreContainer.java:554)
      	... 8 more
      Caused by: org.apache.solr.common.SolrException: Error loading solr config from solr/collection1\solrconfig.xml
      	at org.apache.solr.core.SolrConfig.readFromResourceLoader(SolrConfig.java:148)
      	at org.apache.solr.core.ConfigSetService.createSolrConfig(ConfigSetService.java:79)
      	at org.apache.solr.core.ConfigSetService.getConfig(ConfigSetService.java:61)
      	... 9 more
      Caused by: java.io.IOException: Can't find resource 'solrconfig.xml' in classpath or 'D:\alfresco\solr\collection1\conf'
      	at org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:362)
      	at org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:308)
      	at org.apache.solr.core.Config.<init>(Config.java:116)
      	at org.apache.solr.core.Config.<init>(Config.java:86)
      	at org.apache.solr.core.SolrConfig.<init>(SolrConfig.java:161)
      	at org.apache.solr.core.SolrConfig.readFromResourceLoader(SolrConfig.java:144)
      	... 11 more
      

      Environment amendments:

      1. Comment out <security-constraint> elements under securecomms placeholder in alfresco.war -> web.xml
      2. Comment out solr.xml under tomcat/conf/Catalina/localhost
      3. Add the following to alfresco-global.properties
        solr.store.mappings.value.solrMappingAlfresco.baseUrl=/solr4/alfresco
        solr.store.mappings.value.solrMappingArchive.baseUrl=/solr4/archive
        solr.secureComms=none
        
      1. Put solr4.war from solr4/target to tomcat/webapps
      2. Removed everything from alf_data/solr and replaced with contents of solr4/target/solr-config.zip
      3. Modified data.dir.root property in solrcore.properties for both cores to point to alf_data/solr

      solr4 build command used:

      mvn -pl :alfresco-solr4 -am clean package
      

        Attachments

          Activity

            People

            • Assignee:
              closedissues Closed Issues
              Reporter:
              alfrescoqa Alfresco QA Team
            • Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: