NutzCN Logo
问答 项目启动成功访问失败
发布于 2187天前 作者 Hamming 1465 次浏览 复制 上一个帖子 下一个帖子
标签:

项目启动成功访问失败

root@iZ8vbcqz91cgdxt8qshlxqZ:/opt/tomcat/bin# ./catalina.sh run
Using CATALINA_BASE:   /opt/tomcat
Using CATALINA_HOME:   /opt/tomcat
Using CATALINA_TMPDIR: /opt/tomcat/temp
Using JRE_HOME:        /usr/lib/jvm/java-8-oracle/jre
Using CLASSPATH:       /opt/tomcat/bin/bootstrap.jar:/opt/tomcat/bin/tomcat-juli.jar
27-Nov-2018 15:29:33.953 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server version:        Apache Tomcat/8.5.35
27-Nov-2018 15:29:33.965 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server built:          Nov 3 2018 17:39:20 UTC
27-Nov-2018 15:29:33.965 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server number:         8.5.35.0
27-Nov-2018 15:29:33.965 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log OS Name:               Linux
27-Nov-2018 15:29:33.965 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log OS Version:            4.4.0-117-generic
27-Nov-2018 15:29:33.966 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Architecture:          amd64
27-Nov-2018 15:29:33.966 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Java Home:             /usr/lib/jvm/java-8-oracle/jre
27-Nov-2018 15:29:33.967 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Version:           1.8.0_191-b12
27-Nov-2018 15:29:33.967 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Vendor:            Oracle Corporation
27-Nov-2018 15:29:33.968 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_BASE:         /opt/tomcat
27-Nov-2018 15:29:33.968 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_HOME:         /opt/tomcat
27-Nov-2018 15:29:33.968 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.config.file=/opt/tomcat/conf/logging.properties
27-Nov-2018 15:29:33.969 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
27-Nov-2018 15:29:33.970 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djdk.tls.ephemeralDHKeySize=2048
27-Nov-2018 15:29:33.970 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.protocol.handler.pkgs=org.apache.catalina.webresources
27-Nov-2018 15:29:33.970 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dorg.apache.catalina.security.SecurityListener.UMASK=0027
27-Nov-2018 15:29:33.971 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dignore.endorsed.dirs=
27-Nov-2018 15:29:33.971 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.base=/opt/tomcat
27-Nov-2018 15:29:33.971 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.home=/opt/tomcat
27-Nov-2018 15:29:33.972 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=/opt/tomcat/temp
27-Nov-2018 15:29:33.972 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib]
27-Nov-2018 15:29:34.256 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8080"]
27-Nov-2018 15:29:34.284 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
27-Nov-2018 15:29:34.313 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["ajp-nio-8009"]
27-Nov-2018 15:29:34.314 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
27-Nov-2018 15:29:34.317 INFO [main] org.apache.catalina.startup.Catalina.load Initialization processed in 1042 ms
27-Nov-2018 15:29:34.355 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina]
27-Nov-2018 15:29:34.355 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.5.35
27-Nov-2018 15:29:34.393 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive [/opt/tomcat/webapps/ROOT.war]
27-Nov-2018 15:29:37.037 INFO [localhost-startStop-1] org.apache.jasper.servlet.TldScanner.scanJars At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
27-Nov-2018 15:30:58.154 WARNING [localhost-startStop-1] org.apache.catalina.util.SessionIdGeneratorBase.createSecureRandom Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [81,110] milliseconds.
27-Nov-2018 15:30:58.178 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deployment of web application archive [/opt/tomcat/webapps/ROOT.war] has finished in [83,785] ms
27-Nov-2018 15:30:58.179 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [/opt/tomcat/webapps/host-manager]
27-Nov-2018 15:30:58.224 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [/opt/tomcat/webapps/host-manager] has finished in [45] ms
27-Nov-2018 15:30:58.224 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [/opt/tomcat/webapps/manager]
27-Nov-2018 15:30:58.255 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [/opt/tomcat/webapps/manager] has finished in [31] ms
27-Nov-2018 15:30:58.256 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [/opt/tomcat/webapps/docs]
27-Nov-2018 15:30:58.275 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [/opt/tomcat/webapps/docs] has finished in [19] ms
27-Nov-2018 15:30:58.275 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [/opt/tomcat/webapps/examples]
27-Nov-2018 15:30:58.484 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [/opt/tomcat/webapps/examples] has finished in [208] ms
27-Nov-2018 15:30:58.495 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"]
27-Nov-2018 15:30:58.504 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"]
27-Nov-2018 15:30:58.506 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in 84188 ms

访问提示

HTTP Status 404 – Not Found
Type Status Report

Message /sysadmin

Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.

Apache Tomcat/8.5.35
4 回复

重新打包 发布 错误变成

[DEBUG] 2018-11-27 16:05:06,771 org.apache.shiro.config.IniFactorySupport.createInstance(IniFactorySupport.java:122) - Creating instance from Ini [sections=main,urls]
[ERROR] 2018-11-27 16:05:07,065 org.apache.shiro.web.env.EnvironmentLoader.initEnvironment(EnvironmentLoader.java:146) - Shiro environment initialization failed
org.apache.shiro.config.ConfigurationException: Unable to instantiate class [cn.wizzer.common.shiro.realm.NutDaoRealm] for object named 'shiroDbRealm'.  Please ensure you've specified the fully qualified class name correctly.
	at org.apache.shiro.config.ReflectionBuilder.createNewInstance(ReflectionBuilder.java:151)
	at org.apache.shiro.config.ReflectionBuilder.buildObjects(ReflectionBuilder.java:119)
	at org.apache.shiro.config.IniSecurityManagerFactory.buildInstances(IniSecurityManagerFactory.java:161)
	at org.apache.shiro.config.IniSecurityManagerFactory.createSecurityManager(IniSecurityManagerFactory.java:124)
	at org.apache.shiro.config.IniSecurityManagerFactory.createSecurityManager(IniSecurityManagerFactory.java:102)
	at org.apache.shiro.config.IniSecurityManagerFactory.createInstance(IniSecurityManagerFactory.java:88)
	at org.apache.shiro.config.IniSecurityManagerFactory.createInstance(IniSecurityManagerFactory.java:46)
	at org.apache.shiro.config.IniFactorySupport.createInstance(IniFactorySupport.java:123)
	at org.apache.shiro.util.AbstractFactory.getInstance(AbstractFactory.java:47)
	at org.apache.shiro.web.env.IniWebEnvironment.createWebSecurityManager(IniWebEnvironment.java:203)
	at org.apache.shiro.web.env.IniWebEnvironment.configure(IniWebEnvironment.java:99)
	at org.apache.shiro.web.env.IniWebEnvironment.init(IniWebEnvironment.java:92)
	at org.apache.shiro.util.LifecycleUtils.init(LifecycleUtils.java:45)
	at org.apache.shiro.util.LifecycleUtils.init(LifecycleUtils.java:40)
	at org.apache.shiro.web.env.EnvironmentLoader.createEnvironment(EnvironmentLoader.java:221)
	at org.apache.shiro.web.env.EnvironmentLoader.initEnvironment(EnvironmentLoader.java:133)
	at org.apache.shiro.web.env.EnvironmentLoaderListener.contextInitialized(EnvironmentLoaderListener.java:58)
	at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4792)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5256)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:754)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:730)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)
	at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:985)
	at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
	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:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: org.apache.shiro.util.UnknownClassException: Unable to load class named [cn.wizzer.common.shiro.realm.NutDaoRealm] from the thread context, current, or system/application ClassLoaders.  All heuristics have been exhausted.  Class could not be found.
	at org.apache.shiro.util.ClassUtils.forName(ClassUtils.java:148)
	at org.apache.shiro.util.ClassUtils.newInstance(ClassUtils.java:164)
	at org.apache.shiro.config.ReflectionBuilder.createNewInstance(ReflectionBuilder.java:144)
	... 29 more

看上去编译问题

又重新打包 还是同样的错误

ERROR] 2018-11-27 16:13:53,105 org.apache.shiro.web.env.EnvironmentLoader.initEnvironment(EnvironmentLoader.java:146) - Shiro environment initialization failed
org.apache.shiro.config.ConfigurationException: Unable to instantiate class [cn.wizzer.common.shiro.realm.NutDaoRealm] for object named 'shiroDbRealm'.  Please ensure you've specified the fully qualified class name correctly.
	at org.apache.shiro.config.ReflectionBuilder.createNewInstance(ReflectionBuilder.java:151)
	at org.apache.shiro.config.ReflectionBuilder.buildObjects(ReflectionBuilder.java:119)
	at org.apache.shiro.config.IniSecurityManagerFactory.buildInstances(IniSecurityMa

有点坑 maven 打包 war 出错 还是 IDEA 打包的 maven 没问题

添加回复
请先登陆
回到顶部