You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Pierre GOSSÉ <pi...@arisem.com> on 2012/08/01 16:22:06 UTC

Cloud and cores

Hi all,

I'm playing around with SolrCloud and followed indications I found at http://wiki.apache.org/solr/SolrCloud/

-          Started Instance 1 with embedded zk

-          Started Instances 2 3 and 4 using Instance 1 as zk server.

Everything works fine.

Then, using CoreAdmin, I add a second core in collection1 for Instance 1 and 3 ... everything is ok in the admin GUI, meaning that the graph show 2 shards of 3 server addresses each, those having 2 cores showing to time on the graph.

collection1          shard1                  wks-pge:7574
wks-pge:8900
wks-pge:8983
shard2                  wks-pge:8983
wks-pge:7500
wks-pge:8900

On instances 1 and 3 I have 2 cores both at the bottom of the left column, and in the CoreAdmin screen.

I restart everything, and find the server in what seems to be an inconsistent state : i.e. graph still showing 2 shards of 3 server addresses, but CoreAdmin not showing my additional cores any more.

Is there a problem in SolrCloud or CoreAdmin, or did I just do something stupid here ? :)

Pierre


RE: Cloud and cores

Posted by Pierre GOSSÉ <pi...@arisem.com>.
It may have something to do with SOLR-3425, but I'm not that sure it fits.

I made some more tests.

Case 1 : with SolrCloud
I can create a new core on one of the server by the admin GUI or by CREATE directive in URL. The data folder is created (but no conf folder, I believe zk conf is used). However ./solr/solr.xml is not updated with the new core parameter.
If I restart the server, the core is lost (but data folder is kept)

Case 2 : on a single solr server
Creation of new core fails by the gui with error :
GRAVE: org.apache.solr.common.SolrException: Error executing default implementation of CREATE
        at org.apache.solr.handler.admin.CoreAdminHandler.handleCreateAction(CoreAdminHandler.java:396)
        at org.apache.solr.handler.admin.CoreAdminHandler.handleRequestBody(CoreAdminHandler.java:141)
        at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:129)
        at org.apache.solr.servlet.SolrDispatchFilter.handleAdminRequest(SolrDispatchFilter.java:359)
        at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:175)
        at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1337)
        at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:484)
        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119)
        at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:524)
        at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:233)
        at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1065)
        at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:413)
        at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:192)
        at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:999)
        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
        at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:250)
        at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:149)
        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:111)
        at org.eclipse.jetty.server.Server.handle(Server.java:351)
        at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:454)
        at org.eclipse.jetty.server.BlockingHttpConnection.handleRequest(BlockingHttpConnection.java:47)
        at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:890)
        at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:944)
        at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:634)
        at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:230)

        at org.eclipse.jetty.server.BlockingHttpConnection.handle(BlockingHttpConnection.java:66)
        at org.eclipse.jetty.server.bio.SocketConnector$ConnectorEndPoint.run(SocketConnector.java:254)
        at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:599)
        at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:534)
        at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.RuntimeException: Can't find resource 'solrconfig.xml' in classpath or 'solr\core2\conf/', cwd=F:\solr-4.0\Test
        at org.apache.solr.core.SolrResourceLoader.openResource(SolrResourceLoader.java:294)
        at org.apache.solr.core.SolrResourceLoader.openConfig(SolrResourceLoader.java:260)
        at org.apache.solr.core.Config.<init>(Config.java:111)
        at org.apache.solr.core.Config.<init>(Config.java:78)
        at org.apache.solr.core.SolrConfig.<init>(SolrConfig.java:117)
        at org.apache.solr.core.CoreContainer.create(CoreContainer.java:742)
        at org.apache.solr.handler.admin.CoreAdminHandler.handleCreateAction(CoreAdminHandler.java:391)
        ... 29 more

Using an URL CREATE and giving relative pathes for solrconfig.xml and shema.xml fails later on stopwords.txt

Again solr/solr.xml is not updated, but the runtime exception could explain that in this case.

Pierre
-----Message d'origine-----
De : Pierre GOSSÉ [mailto:pierre.gosse@arisem.com] 
Envoyé : mercredi 1 août 2012 16:22
À : solr-user@lucene.apache.org
Objet : Cloud and cores

Hi all,

I'm playing around with SolrCloud and followed indications I found at http://wiki.apache.org/solr/SolrCloud/

-          Started Instance 1 with embedded zk

-          Started Instances 2 3 and 4 using Instance 1 as zk server.

Everything works fine.

Then, using CoreAdmin, I add a second core in collection1 for Instance 1 and 3 ... everything is ok in the admin GUI, meaning that the graph show 2 shards of 3 server addresses each, those having 2 cores showing to time on the graph.

collection1          shard1                  wks-pge:7574
wks-pge:8900
wks-pge:8983
shard2                  wks-pge:8983
wks-pge:7500
wks-pge:8900

On instances 1 and 3 I have 2 cores both at the bottom of the left column, and in the CoreAdmin screen.

I restart everything, and find the server in what seems to be an inconsistent state : i.e. graph still showing 2 shards of 3 server addresses, but CoreAdmin not showing my additional cores any more.

Is there a problem in SolrCloud or CoreAdmin, or did I just do something stupid here ? :)

Pierre