Catalina.out 中的错误"org.apache.catalina.realm.CombinedRealm startInterna"



我有一个基于SOAP的web服务正在Netbeans中实现。我在服务器端有一些问题,它给了我错误500,内部错误,因为我不能自动调试它,它告诉我检查日志,但我的卡特琳娜。Out满是这样的代码:

     Aug 20, 2011 11:01:32 PM org.apache.catalina.realm.CombinedRealm startInternal
        SEVERE: Failed to start "org.apache.catalina.realm.UserDatabaseRealm/1.0" realm
        org.apache.catalina.LifecycleException: No UserDatabase component found under key UserDatabase
            at org.apache.catalina.realm.UserDatabaseRealm.startInternal(UserDatabaseRealm.java:264)
            at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
            at org.apache.catalina.realm.CombinedRealm.startInternal(CombinedRealm.java:201)
            at org.apache.catalina.realm.LockOutRealm.startInternal(LockOutRealm.java:120)
            at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
            at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1026)
            at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:291)
            at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
            at org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)
            at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
            at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:727)
            at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
            at org.apache.catalina.startup.Catalina.start(Catalina.java:620)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:597)
            at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:303)
            at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:431)
        Aug 20, 2011 11:01:32 PM org.apache.catalina.startup.HostConfig deployWAR
        INFO: Deploying web application archive soap.war
        Aug 20, 2011 11:01:33 PM org.apache.catalina.startup.HostConfig deployDirectory
        INFO: Deploying web application directory manager
        Aug 20, 2011 11:01:34 PM org.apache.catalina.startup.HostConfig deployDirectory
        INFO: Deploying web application directory examples
        Aug 20, 2011 11:01:35 PM org.apache.catalina.startup.HostConfig deployDirectory
        INFO: Deploying web application directory ROOT
        Aug 20, 2011 11:01:35 PM org.apache.catalina.startup.HostConfig deployDirectory
        INFO: Deploying web application directory host-manager
        Aug 20, 2011 11:01:36 PM org.apache.catalina.startup.HostConfig deployDirectory
        INFO: Deploying web application directory docs
        Aug 20, 2011 11:01:37 PM org.apache.catalina.startup.HostConfig deployDirectory
        INFO: Deploying web application directory axis
        - Unable to find config file.  Creating new servlet engine config file: /WEB-INF/server-config.wsdd
        Aug 20, 2011 11:01:39 PM org.apache.coyote.AbstractProtocolHandler start
        INFO: Starting ProtocolHandler ["http-bio-8080"]
        Aug 20, 2011 11:01:39 PM org.apache.coyote.AbstractProtocolHandler start
        INFO: Starting ProtocolHandler ["ajp-bio-8009"]
        Aug 20, 2011 11:01:39 PM org.apache.catalina.startup.Catalina start
        INFO: Server startup in 7851 ms

基本上都是相同的代码,只有在我启动或关闭Tomcat时才会出现,没有什么有用的,这可能会导致我为什么给我错误500。谁能告诉我是什么原因导致

      org.apache.catalina.realm.CombinedRealm startInterna

谢谢你。

这是server.xml的一部分,我修改了它的值,根据我的DB,它的密码等。

                 <GlobalNamingResources>
        <!-- Editable user database that can also be used by
         UserDatabaseRealm to authenticate users
        -->
        <Resource name="NeuroJDBC" auth="Container"
              type="javax.sql.Datasource"
            driverClassName="com.mysql.jdbc.Driver"
            password="alpbra"
            maxIdle="2"
            maxWait="5000"
            removeAbandoned="true"
            removedTimeout="60"
            username="root"
            url="jdbc:mysql://localhost:3306/NeuroDatabase"
              description="User database that can be updated and saved"
              factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
              pathname="conf/tomcat-users.xml" />
      </GlobalNamingResources>

在我的情况下,Tomcat未能重新启动并抛出相同的消息。但问题是在POM.xml中,我提到JAVA版本为1.8,代码是在JDK 1.8上编译的。但是在服务器上安装的JDK是1.7。更改版本和创建在JDK1.7上编译的war文件解决了我的问题。希望这能帮助到一些人

<properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <java.version>1.7</java.version>
</properties>

见此链接http://tomcat.apache.org/tomcat-5.5-doc/config/realm.html(或域文档为您的tomcat版本,如果你不使用tomcat 5)。从堆栈跟踪似乎你有一个配置问题,围绕领域。

stacktrace错误:key UserDatabase下没有UserDatabase组件

在你的$CATALINA_HOME/conf/server.xml中你可以试着修改

吗?
<Resource name="NeuroJDBC" auth="Container"

<Resource name="UserDatabase" auth="Container"

相关内容

  • 没有找到相关文章

最新更新