solr Hybris -我无法启动服务器,由于一些未知的错误

ezykj2lf  于 2022-11-05  发布在  Solr
关注(0)|答案(5)|浏览(254)

我试着用ant build,ant clean all,SVN checkout 一个干净的,然后在我工作的文件服务器上重新下载一个副本。它在其他机器上(我的同事)运行得很好,但对我来说,它似乎不能在hybridserver.bat之后启动,我找不到问题。
我想这可能和Solr服务器有关。
以下是显示的一些控制台消息:

>         at de.hybris.platform.core.Registry.startup(Registry.java:422)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.startRegistry(H
> ybrisContextLoaderListener.java:237)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.doInitWebApplic
> ationContext(HybrisContextLoaderListener.java:135)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.initWebApplicat
> ionContext(HybrisContextLoaderListener.java:125)
>         at org.springframework.web.context.ContextLoaderListener.contextInitiali
> zed(ContextLoaderListener.java:106)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.contextInitiali
> zed(HybrisContextLoaderListener.java:80)
>         at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
> t.java:5016)
>         at org.apache.catalina.core.StandardContext.startInternal(StandardContex
> t.java:5524)
>         at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>         at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.
> java:1575)
>         at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.
> java:1565)
>         at java.util.concurrent.FutureTask.run(FutureTask.java:266)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
> java:1142)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
> .java:617)
>         at java.lang.Thread.run(Thread.java:748) INFO  [localhost-startStop-1] [HybrisContextFactory] Initializing <<global>>
> Spr ing ApplicationContext took: (22.52 I¼s)
> de.hybris.platform.core.UninstantiableCoreApplicationContextException:
> Error cre ating Spring application context.
>         at de.hybris.platform.core.AbstractTenant.doStartupSafe(AbstractTenant.j
> ava:728)
>         at de.hybris.platform.core.AbstractTenant.doStartUp(AbstractTenant.java:
> 658)
>         at de.hybris.platform.core.Registry.assureTenantStarted(Registry.java:63
> 9)
>         at de.hybris.platform.core.Registry.activateTenant(Registry.java:700)
>         at de.hybris.platform.core.Registry.setCurrentTenant(Registry.java:544)
>         at de.hybris.platform.core.Registry.activateMasterTenant(Registry.java:6
> 07)
>         at de.hybris.platform.core.Registry.startup(Registry.java:422)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.startRegistry(H
> ybrisContextLoaderListener.java:237)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.doInitWebApplic
> ationContext(HybrisContextLoaderListener.java:135)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.initWebApplicat
> ionContext(HybrisContextLoaderListener.java:125)
>         at org.springframework.web.context.ContextLoaderListener.contextInitiali
> zed(ContextLoaderListener.java:106)
>         at de.hybris.platform.spring.HybrisContextLoaderListener.contextInitiali
> zed(HybrisContextLoaderListener.java:80)
>         at org.apache.catalina.core.StandardContext.listenerStart(StandardContex
> t.java:5016)
>         at org.apache.catalina.core.StandardContext.startInternal(StandardContex
> t.java:5524)
>         at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>         at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.
> java:1575)
>         at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.
> java:1565)
>         at java.util.concurrent.FutureTask.run(FutureTask.java:266)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
> java:1142)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
> .java:617)
>         at java.lang.Thread.run(Thread.java:748) Caused by: org.springframework.beans.FatalBeanException: Context hybris Global C
> ontext Factory  couldn't  be created correctly due to, Error creating
> bean with name 'defaultSolrServerService' defined in class path
> resource [global-solrserve r-spring.xml]: Invocation of init method
> failed; nested exception is de.hybris.p
> latform.solrserver.SolrServerException: Error while executing Solr
> start command  for instance: [name: default, port: 8983]
>         at de.hybris.platform.core.HybrisContextFactory.build(HybrisContextFacto
> ry.java:317)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ldSelf(HybrisContextFactory.java:189)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ld(HybrisContextFactory.java:175)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstanceCached(H
> ybrisContextHolder.java:134)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstance(HybrisC
> ontextHolder.java:113)
>         at de.hybris.platform.core.HybrisContextHolder.getAppCtxFactory(HybrisCo
> ntextHolder.java:164)
>         at de.hybris.platform.core.HybrisContextHolder.getApplicationInstance(Hy
> brisContextHolder.java:90)
>         at de.hybris.platform.core.AbstractTenant.createCoreApplicationContext(A
> bstractTenant.java:686)
>         at de.hybris.platform.core.AbstractTenant.doStartupSafe(AbstractTenant.j
> ava:724)
>         ... 20 more Error creating Spring application context. Shutting down hybris platform since t he system cannot be used without
> working Spring context... shutting down hybris registry.. INFO 
> [Thread-1] [HybrisContextFactory] Initializing <<global>> Spring
> Applicati onContext took: (16.99 I¼s) ERROR [Thread-1] [JMXBeanLoader]
> Can't unregister jmxbeans on shutdown of the te nant <<master>>
> org.springframework.beans.FatalBeanException: Context hybris Global
> Context Fact ory  couldn't  be created correctly due to, Error
> creating bean with name 'defau ltSolrServerService' defined in class
> path resource [global-solrserver-spring.xm l]: Invocation of init
> method failed; nested exception is de.hybris.platform.sol
> rserver.SolrServerException: Error while executing Solr start command
> for instan ce: [name: default, port: 8983]
>         at de.hybris.platform.core.HybrisContextFactory.build(HybrisContextFacto
> ry.java:317)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ldSelf(HybrisContextFactory.java:189)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ld(HybrisContextFactory.java:175)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstanceCached(H
> ybrisContextHolder.java:134)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstance(HybrisC
> ontextHolder.java:113)
>         at de.hybris.platform.core.Registry.getSingletonGlobalApplicationContext
> (Registry.java:1059)
>         at de.hybris.platform.core.JMXBeanLoader.getMBeanRegistry(JMXBeanLoader.
> java:155)
>         at de.hybris.platform.core.JMXBeanLoader.beforeTenantShutDown(JMXBeanLoa
> der.java:116)
>         at de.hybris.platform.core.AbstractTenant.notifyTenantListenersBeforeShu
> tdown(AbstractTenant.java:1236)
>         at de.hybris.platform.core.AbstractTenant.doShutdown(AbstractTenant.java
> :987)
>         at de.hybris.platform.core.AbstractTenant.doShutDown(AbstractTenant.java
> :948)
>         at de.hybris.platform.core.Registry.destroy(Registry.java:309)
>         at de.hybris.platform.util.RedeployUtilities.shutdown(RedeployUtilities.
> java:74)
>         at de.hybris.platform.util.RedeployUtilities$1.run(RedeployUtilities.jav
> a:38) error notifying tenant listener : null
> java.lang.NullPointerException
>         at de.hybris.platform.jalo.JaloConnection$AbstractSynchronizedPropertyGe
> tter.get(JaloConnection.java:1142)
>         at de.hybris.platform.jalo.JaloConnection.getExtensionManager(JaloConnec
> tion.java:1084)
>         at de.hybris.platform.mobileservices.jalo.MobileManager.getInstance(Mobi
> leManager.java:130)
>         at de.hybris.platform.mobileservices.jalo.MobileManager$1.beforeTenantSh
> utDown(MobileManager.java:92)
>         at de.hybris.platform.core.AbstractTenant.notifyTenantListenersBeforeShu
> tdown(AbstractTenant.java:1236)
>         at de.hybris.platform.core.AbstractTenant.doShutdown(AbstractTenant.java
> :987)
>         at de.hybris.platform.core.AbstractTenant.doShutDown(AbstractTenant.java
> :948)
>         at de.hybris.platform.core.Registry.destroy(Registry.java:309)
>         at de.hybris.platform.util.RedeployUtilities.shutdown(RedeployUtilities.
> java:74)
>         at de.hybris.platform.util.RedeployUtilities$1.run(RedeployUtilities.jav
> a:38) INFO  [Thread-1] [HybrisContextFactory] Initializing <<global>>
> Spring Applicati onContext took: (22.52 I¼s) ERROR [Thread-1]
> [RegionCacheAdapter] Unable to clear cache. Failed on region nu ll.
> Last key null null org.springframework.beans.FatalBeanException:
> Context hybris Global Context Fact ory  couldn't  be created correctly
> due to, Error creating bean with name 'defau ltSolrServerService'
> defined in class path resource [global-solrserver-spring.xm l]:
> Invocation of init method failed; nested exception is
> de.hybris.platform.sol rserver.SolrServerException: Error while
> executing Solr start command for instan ce: [name: default, port:
> 8983]
>         at de.hybris.platform.core.HybrisContextFactory.build(HybrisContextFacto
> ry.java:317)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ldSelf(HybrisContextFactory.java:189)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ld(HybrisContextFactory.java:175)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstanceCached(H
> ybrisContextHolder.java:134)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstance(HybrisC
> ontextHolder.java:113)
>         at de.hybris.platform.core.Registry.getSingletonGlobalApplicationContext
> (Registry.java:1059)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.getController(Region
> CacheAdapter.java:76)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.clear(RegionCacheAda
> pter.java:288)
>         at de.hybris.platform.core.AbstractTenant.shutdownCache(AbstractTenant.j
> ava:1061)
>         at de.hybris.platform.core.AbstractTenant.doShutdown(AbstractTenant.java
> :1003)
>         at de.hybris.platform.core.AbstractTenant.doShutDown(AbstractTenant.java
> :948)
>         at de.hybris.platform.core.Registry.destroy(Registry.java:309)
>         at de.hybris.platform.util.RedeployUtilities.shutdown(RedeployUtilities.
> java:74)
>         at de.hybris.platform.util.RedeployUtilities$1.run(RedeployUtilities.jav
> a:38) org.springframework.beans.FatalBeanException: Context hybris
> Global Context Fact ory  couldn't  be created correctly due to, Error
> creating bean with name 'defau ltSolrServerService' defined in class
> path resource [global-solrserver-spring.xm l]: Invocation of init
> method failed; nested exception is de.hybris.platform.sol
> rserver.SolrServerException: Error while executing Solr start command
> for instan ce: [name: default, port: 8983]
>         at de.hybris.platform.core.HybrisContextFactory.build(HybrisContextFacto
> ry.java:317)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ldSelf(HybrisContextFactory.java:189)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ld(HybrisContextFactory.java:175)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstanceCached(H
> ybrisContextHolder.java:134)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstance(HybrisC
> ontextHolder.java:113)
>         at de.hybris.platform.core.Registry.getSingletonGlobalApplicationContext
> (Registry.java:1059)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.getController(Region
> CacheAdapter.java:76)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.clear(RegionCacheAda
> pter.java:288)
>         at de.hybris.platform.core.AbstractTenant.shutdownCache(AbstractTenant.j
> ava:1061)
>         at de.hybris.platform.core.AbstractTenant.doShutdown(AbstractTenant.java
> :1003)
>         at de.hybris.platform.core.AbstractTenant.doShutDown(AbstractTenant.java
> :948)
>         at de.hybris.platform.core.Registry.destroy(Registry.java:309)
>         at de.hybris.platform.util.RedeployUtilities.shutdown(RedeployUtilities.
> java:74)
>         at de.hybris.platform.util.RedeployUtilities$1.run(RedeployUtilities.jav
> a:38) INFO  [Thread-1] [HybrisContextFactory] Initializing <<global>>
> Spring Applicati onContext took: (10.27 I¼s) ERROR [Thread-1]
> [RegionCacheAdapter] Unable to clear cache. Failed on region nu ll.
> Last key null null org.springframework.beans.FatalBeanException:
> Context hybris Global Context Fact ory  couldn't  be created correctly
> due to, Error creating bean with name 'defau ltSolrServerService'
> defined in class path resource [global-solrserver-spring.xm l]:
> Invocation of init method failed; nested exception is
> de.hybris.platform.sol rserver.SolrServerException: Error while
> executing Solr start command for instan ce: [name: default, port:
> 8983]
>         at de.hybris.platform.core.HybrisContextFactory.build(HybrisContextFacto
> ry.java:317)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ldSelf(HybrisContextFactory.java:189)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ld(HybrisContextFactory.java:175)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstanceCached(H
> ybrisContextHolder.java:134)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstance(HybrisC
> ontextHolder.java:113)
>         at de.hybris.platform.core.Registry.getSingletonGlobalApplicationContext
> (Registry.java:1059)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.getController(Region
> CacheAdapter.java:76)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.clear(RegionCacheAda
> pter.java:288)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.destroy(RegionCacheA
> dapter.java:521)
>         at de.hybris.platform.core.AbstractTenant.shutdownCache(AbstractTenant.j
> ava:1071)
>         at de.hybris.platform.core.AbstractTenant.doShutdown(AbstractTenant.java
> :1003)
>         at de.hybris.platform.core.AbstractTenant.doShutDown(AbstractTenant.java
> :948)
>         at de.hybris.platform.core.Registry.destroy(Registry.java:309)
>         at de.hybris.platform.util.RedeployUtilities.shutdown(RedeployUtilities.
> java:74)
>         at de.hybris.platform.util.RedeployUtilities$1.run(RedeployUtilities.jav
> a:38) org.springframework.beans.FatalBeanException: Context hybris
> Global Context Fact ory  couldn't  be created correctly due to, Error
> creating bean with name 'defau ltSolrServerService' defined in class
> path resource [global-solrserver-spring.xm l]: Invocation of init
> method failed; nested exception is de.hybris.platform.sol
> rserver.SolrServerException: Error while executing Solr start command
> for instan ce: [name: default, port: 8983]
>         at de.hybris.platform.core.HybrisContextFactory.build(HybrisContextFacto
> ry.java:317)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ldSelf(HybrisContextFactory.java:189)
>         at de.hybris.platform.core.HybrisContextFactory$GlobalContextFactory.bui
> ld(HybrisContextFactory.java:175)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstanceCached(H
> ybrisContextHolder.java:134)
>         at de.hybris.platform.core.HybrisContextHolder.getGlobalInstance(HybrisC
> ontextHolder.java:113)
>         at de.hybris.platform.core.Registry.getSingletonGlobalApplicationContext
> (Registry.java:1059)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.getController(Region
> CacheAdapter.java:76)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.clear(RegionCacheAda
> pter.java:288)
>         at de.hybris.platform.cache.impl.RegionCacheAdapter.destroy(RegionCacheA
> dapter.java:521)
>         at de.hybris.platform.core.AbstractTenant.shutdownCache(AbstractTenant.j
> ava:1071)
>         at de.hybris.platform.core.AbstractTenant.doShutdown(AbstractTenant.java
> :1003)
>         at de.hybris.platform.core.AbstractTenant.doShutDown(AbstractTenant.java
> :948)
>         at de.hybris.platform.core.Registry.destroy(Registry.java:309)
>         at de.hybris.platform.util.RedeployUtilities.shutdown(RedeployUtilities.
> java:74)
>         at de.hybris.platform.util.RedeployUtilities$1.run(RedeployUtilities.jav
> a:38) INFO  [Thread-1] [DefaultClusterNodeManagementService]
> Unregistering assigned cl uster node id 0... <-- Wrapper Stopped

更新/解决方案:问题是SOLR服务器不允许目录中有空格。

vmpqdwk3

vmpqdwk31#

首先,检查所有的环境变量是否正确。特别是JAVA_HOME的路径是否正确。如果仍然有问题,请尝试停止SOLR服务器:ant stopSolrServer。您还可以通过在.properties文件中添加此命令来阻止solr自动启动。

solrserver.instances.default.autostart=false

您也可以尝试更改默认端口

solrserver.instances.default.port=8984
yuvru6vn

yuvru6vn2#

同样的问题发生在我的情况下,我检查,由于一些错误的拉或在 checkout 到不同的分支,我失去了我的solr.xml文件.
试着把它加回去,它会起作用的

7gcisfzg

7gcisfzg3#

我在我的6.2安装程序中遇到过这个问题,最终能够解决这个问题。这是由于两个JAR分别是“Jackson核心和Jackson注解”,这些JAR需要更新为最新版本(我用版本2.9.2替换),这为我解决了这个问题!

dced5bon

dced5bon4#

由于以前的solr服务器仍占用端口8983,我也出现了同样的错误。我尝试停止solrserver,但没有帮助,然后我使用以下命令列出所有打开的端口:

lsof -PiTCP -sTCP:LISTEN

然后终止正在监听8983的javapid。

kill <pid>
cbwuti44

cbwuti445#

是的。我做了。添加solrserver.instances.default.autostart=false在我的配置文件夹下的文件local.properties中。它对我很有效。

相关问题