我已经下载了kie工作台并解压缩了kie-drools-wb-distribution-wars-6.2.0.Final- tomcat7.war。我以前从未使用过tomcat,但是我想使用工作台,但似乎没有选择让工作台简单地向上旋转。因此,我安装了tomcat8。完成此操作后,我访问了tomcat管理器并部署了war。(我必须增加可接受文件大小的内存限制)
kie-drools-wb-distribution-wars-6.2.0.Final- tomcat7.war
我现在已/kie-drools-wb-distribution-wars-6.2.0.Final- tomcat7列为应用程序,但不会启动。当我尝试启动它时,我得到以下信息:
/kie-drools-wb-distribution-wars-6.2.0.Final- tomcat7
FAIL - Application at context path /kie-drools-wb-distribution-wars-6.2.0.Final-tomcat7 could not be started FAIL - Encountered exception org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/kie-drools-wb-distribution-wars-6.2.0.Final-tomcat7]]
这是catalina日志文件:
01-Apr-2015 18:51:54.136 SEVERE [localhost-startStop-1] org.apache.catalina.startup.ContextConfig.processContextConfig Parse error in context.xml for /kie-drools-wb-distribution-wars-6.2.0.Final-tomcat7 org.xml.sax.SAXParseException; systemId: file:/opt/apache-tomcat-8.0.21/webapps/kie-drools-wb-distribution-wars-6.2.0.Final-tomcat7/META-INF/context.xml; lineNumber: 17; columnNumber: 81; Error at (17, 81) : bitronix.tm.integration.tomcat55.BTMLifecycleListener at org.apache.tomcat.util.digester.Digester.createSAXException(Digester.java:1914) at org.apache.tomcat.util.digester.Digester.createSAXException(Digester.java:1946) at org.apache.tomcat.util.digester.Digester.startElement(Digester.java:1187) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509) at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:182) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1343) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2786) at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777) at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213) at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:649) at org.apache.tomcat.util.digester.Digester.parse(Digester.java:1457) at org.apache.catalina.startup.ContextConfig.processContextConfig(ContextConfig.java:541) at org.apache.catalina.startup.ContextConfig.contextConfig(ContextConfig.java:500) at org.apache.catalina.startup.ContextConfig.init(ContextConfig.java:731) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:316) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.util.LifecycleBase.setStateInternal(LifecycleBase.java:402) at org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:110) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:139) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:725) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:701) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717) at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:940) at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1738) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) 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:745) Caused by: java.lang.ClassNotFoundException: bitronix.tm.integration.tomcat55.BTMLifecycleListener at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at org.apache.tomcat.util.digester.ObjectCreateRule.begin(ObjectCreateRule.java:116) at org.apache.tomcat.util.digester.Digester.startElement(Digester.java:1184) ... 31 more 01-Apr-2015 18:51:54.138 SEVERE [localhost-startStop-1] org.apache.catalina.startup.ContextConfig.processContextConfig Occurred at line 17 column 81 01-Apr-2015 18:51:55.349 SEVERE [localhost-startStop-1] org.apache.catalina.startup.ContextConfig.configureStart Marking this application unavailable due to previous error(s) 01-Apr-2015 18:51:55.362 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal Error getConfigured 01-Apr-2015 18:51:55.383 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal Context [/kie-drools-wb-distribution-wars-6.2.0.Final-tomcat7] startup failed due to previous errors 01-Apr-2015 18:51:55.412 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deployment of web application archive /opt/apache-tomcat-8.0.21/webapps/kie-drools-wb-distribution-wars-6.2.0.Final-tomcat7.war has finished in 1,348 ms 01-Apr-2015 18:51:55.414 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory /opt/apache-tomcat-8.0.21/webapps/manager 01-Apr-2015 18:51:55.675 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory /opt/apache-tomcat-8.0.21/webapps/manager has finished in 260 ms 01-Apr-2015 18:51:55.675 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory /opt/apache-tomcat-8.0.21/webapps/examples 01-Apr-2015 18:51:56.046 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory /opt/apache-tomcat-8.0.21/webapps/examples has finished in 371 ms 01-Apr-2015 18:51:56.047 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory /opt/apache-tomcat-8.0.21/webapps/ROOT 01-Apr-2015 18:51:56.067 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory /opt/apache-tomcat-8.0.21/webapps/ROOT has finished in 21 ms 01-Apr-2015 18:51:56.068 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory /opt/apache-tomcat-8.0.21/webapps/docs 01-Apr-2015 18:51:56.080 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory /opt/apache-tomcat-8.0.21/webapps/docs has finished in 11 ms 01-Apr-2015 18:51:56.082 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory /opt/apache-tomcat-8.0.21/webapps/host-manager 01-Apr-2015 18:51:56.101 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory /opt/apache-tomcat-8.0.21/webapps/host-manager has finished in 20 ms 01-Apr-2015 18:51:56.107 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"] 01-Apr-2015 18:51:56.127 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"] 01-Apr-2015 18:51:56.132 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in 2193 ms 01-Apr-2015 18:52:51.433 WARNING [http-nio-8080-exec-4] org.apache.catalina.deploy.NamingResourcesImpl.cleanUp Failed to retrieve JNDI naming context for container [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/kie-drools-wb-distribution-wars-6.2.0.Final-tomcat7]] so no cleanup was performed for that container javax.naming.NameNotFoundException: Name [comp/env] is not bound in this Context. Unable to find [comp]. at org.apache.naming.NamingContext.lookup(NamingContext.java:818) at org.apache.naming.NamingContext.lookup(NamingContext.java:166) at org.apache.catalina.deploy.NamingResourcesImpl.cleanUp(NamingResourcesImpl.java:993) at org.apache.catalina.deploy.NamingResourcesImpl.stopInternal(NamingResourcesImpl.java:975) at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232) at org.apache.catalina.core.StandardContext.stopInternal(StandardContext.java:5403) at org.apache.catalina.util.LifecycleBase.stop(LifecycleBase.java:232) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:141) at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1293) at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:673) at org.apache.catalina.manager.HTMLManagerServlet.doPost(HTMLManagerServlet.java:221) at javax.servlet.http.HttpServlet.service(HttpServlet.java:648) at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.filters.CsrfPreventionFilter.doFilter(CsrfPreventionFilter.java:213) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:108) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:614) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:142) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79) at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:610) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:518) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1091) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:668) at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:223) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1517) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1474) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:745)
我似乎在context.xml中存在某种解析错误。但是,由于这是直接从Drools下载的代码的未修改内容,因此我不知道它可能有什么问题。
在您的.war文件被tomcat分解后,您将需要CD进入/kie-drools-wb-distribution-wars-6.2.0.Final- tomcat7目录。那里有一个README.txt文件,它提供了进一步的安装说明:
在您的tomcat中安装bitronix交易管理器
在TOMCAT_HOME / conf中创建配置文件
在tomcat上为kie-wb配置JEE安全性(默认域由tomcat-users.xml支持)
(列表元素是从README.txt复制粘贴的)。按照那里的说明进行操作,它应该可以工作。我认为您遇到的错误与步骤1和bitronix事务管理器有关。
希望能有所帮助