You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@solr.apache.org by Matthew Castrigno <ca...@slhs.org> on 2023/01/27 20:09:15 UTC

Fresh install resulting in error

Hello,

We have been running SOLR 9.0 on Red Hat nix. We spun up another server and installed SOLR 9.0 on it.
We believe we have identical installs however the same calls produce this 500 error.
Any insights are appreciated.
Thank you,
Matthew
HTTP ERROR 500 java.lang.NoClassDefFoundError: Lorg/apache/lucene/index/Term;
URI:    /solr/talix/index
STATUS: 500
MESSAGE:        java.lang.NoClassDefFoundError: Lorg/apache/lucene/index/Term;
SERVLET:        default
CAUSED BY:      java.lang.NoClassDefFoundError: Lorg/apache/lucene/index/Term;
CAUSED BY:      java.lang.ClassNotFoundException: org.apache.lucene.index.Term
Caused by:

java.lang.NoClassDefFoundError: Lorg/apache/lucene/index/Term;
        at java.base/java.lang.Class.getDeclaredFields0(Native Method)
        at java.base/java.lang.Class.privateGetDeclaredFields(Class.java:3061)
        at java.base/java.lang.Class.privateGetPublicFields(Class.java:3088)
        at java.base/java.lang.Class.getFields(Class.java:1814)
        at jdk.dynalink/jdk.dynalink.beans.FacetIntrospector.getFields(FacetIntrospector.java:112)
        at jdk.dynalink/jdk.dynalink.beans.AbstractJavaLinker.<init>(AbstractJavaLinker.java:138)
        at jdk.dynalink/jdk.dynalink.beans.BeanLinker.<init>(BeanLinker.java:92)
        at jdk.dynalink/jdk.dynalink.beans.BeansLinker$1.computeValue(BeansLinker.java:144)
        at jdk.dynalink/jdk.dynalink.beans.BeansLinker$1.computeValue(BeansLinker.java:136)
        at java.base/java.lang.ClassValue.getFromHashMap(ClassValue.java:228)
        at java.base/java.lang.ClassValue.getFromBackup(ClassValue.java:210)
        at java.base/java.lang.ClassValue.get(ClassValue.java:116)
        at jdk.dynalink/jdk.dynalink.beans.BeansLinker.getStaticLinkerForClass(BeansLinker.java:210)
        at jdk.dynalink/jdk.dynalink.beans.BeansLinker.getLinkerForClass(BeansLinker.java:180)
        at jdk.dynalink/jdk.dynalink.beans.BeansLinker.getGuardedInvocation(BeansLinker.java:333)
        at jdk.scripting.nashorn/jdk.nashorn.internal.runtime.linker.NashornBeansLinker.getGuardedInvocation(NashornBeansLinker.java:169)
        at jdk.scripting.nashorn/jdk.nashorn.internal.runtime.linker.NashornBeansLinker.getGuardedInvocation(NashornBeansLinker.java:156)
        at jdk.dynalink/jdk.dynalink.linker.support.CompositeGuardingDynamicLinker.getGuardedInvocation(CompositeGuardingDynamicLinker.java:109)
        at jdk.dynalink/jdk.dynalink.LinkerServicesImpl.lambda$getGuardedInvocation$0(LinkerServicesImpl.java:137)
        at jdk.dynalink/jdk.dynalink.LinkerServicesImpl.getWithLookupInternal(LinkerServicesImpl.java:168)
        at jdk.dynalink/jdk.dynalink.LinkerServicesImpl.getGuardedInvocation(LinkerServicesImpl.java:135)
        at jdk.dynalink/jdk.dynalink.DynamicLinker.relink(DynamicLinker.java:242)
        at jdk.scripting.nashorn.scripts/jdk.nashorn.internal.scripts.Script$Recompilation$4$331A$\^eval\_.processAdd(<eval>:22)
        at jdk.scripting.nashorn/jdk.nashorn.internal.runtime.ScriptFunctionData.invoke(ScriptFunctionData.java:657)
        at jdk.scripting.nashorn/jdk.nashorn.internal.runtime.ScriptFunction.invoke(ScriptFunction.java:513)
        at jdk.scripting.nashorn/jdk.nashorn.internal.runtime.ScriptRuntime.apply(ScriptRuntime.java:527)
        at jdk.scripting.nashorn/jdk.nashorn.api.scripting.ScriptObjectMirror.callMember(ScriptObjectMirror.java:202)
        at jdk.scripting.nashorn/jdk.nashorn.api.scripting.NashornScriptEngine.invokeImpl(NashornScriptEngine.java:393)
        at jdk.scripting.nashorn/jdk.nashorn.api.scripting.NashornScriptEngine.invokeFunction(NashornScriptEngine.java:197)
        at org.apache.solr.scripting.update.ScriptUpdateProcessorFactory$ScriptUpdateProcessor.invokeFunctionUnsafe(ScriptUpdateProcessorFactory.java:446)
        at org.apache.solr.scripting.update.ScriptUpdateProcessorFactory$ScriptUpdateProcessor$1.run(ScriptUpdateProcessorFactory.java:436)
        at org.apache.solr.scripting.update.ScriptUpdateProcessorFactory$ScriptUpdateProcessor$1.run(ScriptUpdateProcessorFactory.java:433)
        at java.base/java.security.AccessController.doPrivileged(Native Method)
        at org.apache.solr.scripting.update.ScriptUpdateProcessorFactory$ScriptUpdateProcessor.invokeFunction(ScriptUpdateProcessorFactory.java:432)
        at org.apache.solr.scripting.update.ScriptUpdateProcessorFactory$ScriptUpdateProcessor.processAdd(ScriptUpdateProcessorFactory.java:386)
        at org.apache.solr.handler.loader.JsonLoader$SingleThreadedJsonLoader$1.handle(JsonLoader.java:286)
        at org.apache.solr.common.util.JsonRecordReader$Node.handleObjectStart(JsonRecordReader.java:369)
        at org.apache.solr.common.util.JsonRecordReader$Node.parse(JsonRecordReader.java:270)
        at org.apache.solr.common.util.JsonRecordReader.streamRecords(JsonRecordReader.java:124)
        at org.apache.solr.handler.loader.JsonLoader$SingleThreadedJsonLoader.handleSplitMode(JsonLoader.java:264)
        at org.apache.solr.handler.loader.JsonLoader$SingleThreadedJsonLoader.processUpdate(JsonLoader.java:174)
        at org.apache.solr.handler.loader.JsonLoader$SingleThreadedJsonLoader.load(JsonLoader.java:158)
        at org.apache.solr.handler.loader.JsonLoader.load(JsonLoader.java:84)
        at org.apache.solr.handler.UpdateRequestHandler$1.load(UpdateRequestHandler.java:101)
        at org.apache.solr.handler.ContentStreamHandlerBase.handleRequestBody(ContentStreamHandlerBase.java:84)
        at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:207)
        at org.apache.solr.core.SolrCore.execute(SolrCore.java:2866)
        at org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:887)
        at org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:606)
        at org.apache.solr.servlet.SolrDispatchFilter.dispatch(SolrDispatchFilter.java:239)
        at org.apache.solr.servlet.SolrDispatchFilter.lambda$doFilter$0(SolrDispatchFilter.java:207)
        at org.apache.solr.servlet.ServletUtils.traceHttpRequestExecution2(ServletUtils.java:257)
        at org.apache.solr.servlet.ServletUtils.rateLimitRequest(ServletUtils.java:227)
        at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:202)
        at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:184)
        at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:201)
        at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601)
        at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:548)
        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
        at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:600)
        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235)
        at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1624)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)
        at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1434)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)
        at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:501)
        at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1594)
        at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)
        at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1349)
        at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
        at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:191)
        at org.eclipse.jetty.server.handler.InetAccessHandler.handle(InetAccessHandler.java:177)
        at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:146)
        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
        at org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler.java:322)
        at org.eclipse.jetty.server.handler.gzip.GzipHandler.handle(GzipHandler.java:763)
        at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)
        at org.eclipse.jetty.server.Server.handle(Server.java:516)
        at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:400)
        at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:645)
        at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:392)
        at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277)
        at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)
        at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105)
        at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104)
        at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883)
        at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034)
        at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: java.lang.ClassNotFoundException: org.apache.lucene.index.Term
        at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:476)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:589)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
        at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:538)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
        ... 89 more


 [cid:5e3a8e58-bb1f-4bae-be71-c6d8e3ec7d84]

Matthew Castrigno

IHT Developer II

St. Luke’s Health System

•  208-859-4276
•  castrigm@slhs.org<ma...@slhs.org>

----------------------------------------------------------------------
"This message is intended for the use of the person or entity to which it is addressed and may contain information that is confidential or privileged, the disclosure of which is governed by applicable law. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this information is strictly prohibited. If you have received this message by error, please notify us immediately and destroy the related message."

Re: Fresh install resulting in error

Posted by Matthew Castrigno <ca...@slhs.org>.
Thank you Shawn.

This process was used for the install:
https://tecadmin.net/how-to-install-apache-solr-on-centos-8/

As for the jar, this line was added into solrconfig.xml
  <lib dir="${solr.install.dir:../../../..}/modules/scripting/lib/" regex=".*\.jar" />


________________________________
From: Shawn Heisey <ap...@elyograg.org>
Sent: Friday, January 27, 2023 2:55 PM
To: users@solr.apache.org <us...@solr.apache.org>
Subject: Re: Fresh install resulting in error

On 1/27/2023 2: 08 PM, Matthew Castrigno wrote: > We do use one jar not listed in the default configuration. > What do steps do you recommend to resolve these potential causes? > We have attempted the install multiple times. Is there
ZjQcmQRYFpfptBannerStart
This Message Is From an External Sender
This message came from outside the St. Luke's email system.

ZjQcmQRYFpfptBannerEnd

On 1/27/2023 2:08 PM, Matthew Castrigno wrote:
> We do use one jar not listed in the default configuration.
> What do steps do you recommend to resolve these potential causes?
> We have attempted the install multiple times. Is there a particular
> order of operations?
> We installed and then copied the core into the appropriate directory and
> restarted the service.

Can you describe exactly what you did to install and configure Solr,
including anything related to loading extra jars?

Thanks,
Shawn


----------------------------------------------------------------------
"This message is intended for the use of the person or entity to which it is addressed and may contain information that is confidential or privileged, the disclosure of which is governed by applicable law. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this information is strictly prohibited. If you have received this message by error, please notify us immediately and destroy the related message."

Re: Fresh install resulting in error

Posted by Shawn Heisey <ap...@elyograg.org>.
On 1/27/2023 2:08 PM, Matthew Castrigno wrote:
> We do use one jar not listed in the default configuration.
> What do steps do you recommend to resolve these potential causes?
> We have attempted the install multiple times. Is there a particular 
> order of operations?
> We installed and then copied the core into the appropriate directory and 
> restarted the service.

Can you describe exactly what you did to install and configure Solr, 
including anything related to loading extra jars?

Thanks,
Shawn

Re: Fresh install resulting in error

Posted by Matthew Castrigno <ca...@slhs.org>.
Thank you Shawn.
We do use one jar not listed in the default configuration.
What do steps do you recommend to resolve these potential causes?
We have attempted the install multiple times. Is there a particular order of operations?
We installed and then copied the core into the appropriate directory and restarted the service.

Thank you for your insights.


 [cid:f3d25570-5ac3-400c-aa2b-65941d61d1fa]

Matthew Castrigno

IHT Developer II

St. Luke’s Health System

•  208-859-4276
•  castrigm@slhs.org<ma...@slhs.org>

________________________________
From: Shawn Heisey <ap...@elyograg.org>
Sent: Friday, January 27, 2023 1:34 PM
To: users@solr.apache.org <us...@solr.apache.org>
Subject: Re: Fresh install resulting in error

On 1/27/23 13: 09, Matthew Castrigno wrote: > We have been running SOLR 9. 0 on Red Hat nix. We spun up another server > and installed SOLR 9. 0 on it. > We believe we have identical installs however the same calls produce > this 500
ZjQcmQRYFpfptBannerStart
This Message Is From an External Sender
This message came from outside the St. Luke's email system.

ZjQcmQRYFpfptBannerEnd

On 1/27/23 13:09, Matthew Castrigno wrote:
> We have been running SOLR 9.0 on Red Hat nix. We spun up another server
> and installed SOLR 9.0 on it.
> We believe we have identical installs however the same calls produce
> this 500 error.

Getting java.lang.NoClassDefFoundError: Lorg/apache/lucene/index/Term;
means that it's not able to find a very core Lucene class.  I see two
possible causes, with the second being more likely:

* The install wasn't complete and there are jar files missing.

* You have loaded the core Lucene jars more than once.  They should get
loaded once just from the default Solr install, but by enabling some
non-default functionality, you may have caused them to get loaded again.
  Java tends to have issues when the same jar gets loaded more than
once, or when the install already has a jar and a different version of
that jar also gets loaded.

Thanks,
Shawn


----------------------------------------------------------------------
"This message is intended for the use of the person or entity to which it is addressed and may contain information that is confidential or privileged, the disclosure of which is governed by applicable law. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this information is strictly prohibited. If you have received this message by error, please notify us immediately and destroy the related message."

Re: Fresh install resulting in error

Posted by Shawn Heisey <ap...@elyograg.org>.
On 1/27/23 13:09, Matthew Castrigno wrote:
> We have been running SOLR 9.0 on Red Hat nix. We spun up another server 
> and installed SOLR 9.0 on it.
> We believe we have identical installs however the same calls produce 
> this 500 error.

Getting java.lang.NoClassDefFoundError: Lorg/apache/lucene/index/Term; 
means that it's not able to find a very core Lucene class.  I see two 
possible causes, with the second being more likely:

* The install wasn't complete and there are jar files missing.

* You have loaded the core Lucene jars more than once.  They should get 
loaded once just from the default Solr install, but by enabling some 
non-default functionality, you may have caused them to get loaded again. 
  Java tends to have issues when the same jar gets loaded more than 
once, or when the install already has a jar and a different version of 
that jar also gets loaded.

Thanks,
Shawn