Geonetwork Web界面未在Localhost中运行

发布于 2025-02-13 07:40:38 字数 3205 浏览 0 评论 0 原文

我遵循了提到的步骤在这里

 从sourceforge下载所需的geonetwork.war文件。
将战争文件复制到Tomcat的Web App文件夹中。
如果启动,Tomcat将自动部署该应用程序。如果没有,请开始tomcat进行部署。
 

我开始使用Tomcat,转到http:// localhost:8080/Manager/html,然后单击Geonetwork。该页面加载几秒钟,但 start 按钮不会更改为 stop 。它显示失败 - 在上下文路径上的应用程序[/geonetwork-4.0.5-0]无法启动

我在那里单击Geonetwork-4.0.5-0,它返回404错误。

xampp/tomcat/webapps文件夹

服务器信息

我尝试使用 href =“ https://geonetwork-opensource.org/manuals/3.10.x/en/install-guide/installing-from-zip.html” rel =“ nofollow noreferrer” 503错误

启动Tomcat后立即检查了日志,它说明了

Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\javaee-api-7.0.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\jsp-api-2.1-6.1.14.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/el/Expression.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\servlet-api-2.3.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\servlet-api-2.5-20081211.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\servlet-api-2.5-6.1.14.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class

解决此问题的任何技巧吗?

I followed the steps mentioned here

Download the desired geonetwork.war file from SourceForge.
Copy the WAR file into the webapp folder of Tomcat.
If started, Tomcat will automatically deploy the application. If not, start Tomcat to deploy.

I start Tomcat, go to http://localhost:8080/manager/html, and start and click Geonetwork. The page loads for a couple of seconds but the Start button doesn't change to Stop. It shows FAIL - Application at context path [/GeoNetwork-4.0.5-0] could not be started.

enter image description here

I click GeoNetwork-4.0.5-0 is there and it returns a 404 error.

enter image description here

xampp/tomcat/webapps folder

enter image description here

Server information

enter image description here

I tried installing using the zip file but now returns a 503 error

enter image description here

I checked the log right after starting Tomcat and it says

Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\javaee-api-7.0.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\jsp-api-2.1-6.1.14.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/el/Expression.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\servlet-api-2.3.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\servlet-api-2.5-20081211.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
Jul 04, 2022 7:13:30 PM org.apache.catalina.loader.WebappClassLoaderBase validateJarFile
INFO: validateJarFile(C:\xampp\tomcat\webapps\GeoNetwork-4.0.5-0\WEB-INF\lib\servlet-api-2.5-6.1.14.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class

Any tips on solving this?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

如若梦似彩虹 2025-02-20 07:40:38

由于您正在安装4版,因此我建议您查看相关文档在这里。需要为此版本安装一些其他服务,例如Elasticsearch。

另外,最好下载您使用的最新版本4.2.0而不是旧版本,即4.0.5。

该错误最有可能是由于Geonetwork开发人员对战争文件的杂乱包装造成的。该文件包含Tomcat已提供的库,因此将它们包装为战争文件的一部分将导致此类错误。

有关 Servlet-Api JSP-API 的警告并不重要,因为这些库存在于Tomcat上,并且无论如何都会加载。但是, javaee-api-7.0.jar 警告至关重要,因为tomcat并未完全提供Javaee API,并且未能加载此库是应用程序失败的原因:

 Caused by: java.lang.IllegalStateException: Failed to introspect Class [org.fao.geonet.api.records.attachments.ResourceLoggerStore] from ClassLoader [WebappClassLoader
   context: /GeoNetwork-4.0.5-0
   delegate: false
   repositories:
     /WEB-INF/classes/
 ----------> Parent Classloader:
 java.net.URLClassLoader@2a84aee7
 ]
         at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:481)
         at org.springframework.util.ReflectionUtils.doWithLocalMethods(ReflectionUtils.java:321)
         at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPostProcessor.java:267)
         ... 77 more
 Caused by: java.lang.NoClassDefFoundError: javax/resource/NotSupportedException
         at java.lang.Class.getDeclaredMethods0(Native Method)
         at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
         at java.lang.Class.getDeclaredMethods(Class.java:1975)
         at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:463)
         ... 79 more
 Caused by: java.lang.ClassNotFoundException: javax.resource.NotSupportedException
         at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1951)
         at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1795)
         ... 83 more

快速攻击:解决该问题将是从已部署的应用程序复制此JAR ( tomcat/webapps/geonetwork-4.0.5-0/web-inf/lib/lib/javaee-api-7.0.0.jar )至 tomcat/lib 目录和重新启动Tomcat服务器。

一种正确的方法是向Geonetwork的开发人员报告此问题,以便他们将矛盾的库中删除分布或更新文档。

Since you're instaling version 4, I would advice to check out the relevant documentation here. Some additional services, like ElasticSearch, need to be installed for this version.

Also, it's probably better to download the latest version 4.2.0 instead of an older one, 4.0.5, that you're using.

The error happens most likely due to messy packaging of the war file by the GeoNetwork developers. The file contains libraries that are already provided by Tomcat, so packaging them as part of the war file will result in such error.

The warnings about servlet-api and jsp-api are not critical, since these libraries are present on Tomcat and will be loaded anyway. However, the javaee-api-7.0.jar warning is critical, as Tomcat doesn't fully provide the JavaEE API, and the failure to load this library is the reason the application fails:

 Caused by: java.lang.IllegalStateException: Failed to introspect Class [org.fao.geonet.api.records.attachments.ResourceLoggerStore] from ClassLoader [WebappClassLoader
   context: /GeoNetwork-4.0.5-0
   delegate: false
   repositories:
     /WEB-INF/classes/
 ----------> Parent Classloader:
 java.net.URLClassLoader@2a84aee7
 ]
         at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:481)
         at org.springframework.util.ReflectionUtils.doWithLocalMethods(ReflectionUtils.java:321)
         at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPostProcessor.java:267)
         ... 77 more
 Caused by: java.lang.NoClassDefFoundError: javax/resource/NotSupportedException
         at java.lang.Class.getDeclaredMethods0(Native Method)
         at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
         at java.lang.Class.getDeclaredMethods(Class.java:1975)
         at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:463)
         ... 79 more
 Caused by: java.lang.ClassNotFoundException: javax.resource.NotSupportedException
         at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1951)
         at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1795)
         ... 83 more

A quick hack to fix the issue would be to copy this jar from the deployed application (tomcat/webapps/GeoNetwork-4.0.5-0/WEB-INF/lib/javaee-api-7.0.jar) to the tomcat/lib directory and restarting the Tomcat server.

A proper way would be to report this issue to the developers of GeoNetwork, so that they would remove the conflicting libraries from the distribution or update the documentation.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文