I recently used the ssm framework when doing a practical training project. After the project environment was set up, I kept encountering a 404 page access error when running the program. The project operation log is as follows: November 13, 2020 11:56:07 AM org.apache.catalina.core.AprLifecycleListener init 信息: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: D:\java\jdk\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;D:/java/jdk/bin/../jre/bin/server;D:/java/jdk/bin/../jre/bin;D:/java/jdk/bin/../jre/lib/amd64;D:\java\jdk\bin;D:\java\JRE\bin;D:\ernv\gradle\gradle-6.6.1-all\gradle-6.6.1\bin;C:\sqlite3;C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\iCLS\;C:\Program Files\Intel\Intel(R) Management Engine Components\iCLS\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\DTS\Binn\;d:\python\Scripts;D:\爬虫所需软件\数据库\;D:\Git\cmd;D:\bin;C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft SQL Server\110\DTS\Binn\;D:\MySQL\MySQL Server 5.5\bin;D:\Python;C:\Program Files\Terminus\Terminus.exe;D:\tools\myBlog\node-v12.1.0-win-x64;D:\tools\myBlog\node-v12.1.0-win-x64\node-global;D:\tools\myBlog\node-v12.1.0-win-x64\node-global\node_modules\hexo\node_modules\.bin;D:\ernv\java\apache-maven-3.6.3-bin\apache-maven-3.6.3\bin;D:\ernv\lib\opencv\Opencv3.4.2\Opencv3.4.2\WindowSoft\opencv\build\x64\vc15\bin;I:\软件安装包\mrunit\windows系统hadoop插件-winutilsmaster\winutils-master\hadoop-2.6.3\bin;C:\Users\erbin\AppData\Local\Microsoft\WindowsApps;D:\ProGramTool\byTool\PyCharm 2018.3.2\bin;D:\爬虫所需软件\数据库\mysql-5.6.43-winx64\bin;D:\tools\Programs\Fiddler;D:\IDE\JetBrains\IDEA 2020.1\IntelliJ IDEA 2020.1\bin;C:\Users\erbin\AppData\Local\Pandoc\;D:\go\idea\GoLand 2020.1\bin;D:\eclipse-jee-neon-3-win32-x86_64\eclipse;;. November 13, 2020 11:56:07 AM org.apache.tomcat.util.digester.SetPropertiesRule begin Warning: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.j2ee.server:CRMSystem' did not find a matching property. November 13, 2020 11:56:08 AM org.apache.coyote.AbstractProtocol init INFO: Initializing ProtocolHandler ["http-nio-8080"] November 13, 2020 11:56:08 AM org.apache.tomcat.util.net.NioSelectorPool getSharedSelector Information: Using a shared selector for servlet write/read November 13, 2020 11:56:08 AM org.apache.coyote.AbstractProtocol init INFO: Initializing ProtocolHandler ["ajp-nio-8009"] November 13, 2020 11:56:08 AM org.apache.tomcat.util.net.NioSelectorPool getSharedSelector Information: Using a shared selector for servlet write/read November 13, 2020 11:56:08 AM org.apache.catalina.startup.Catalina load Information: Initialization processed in 866 ms November 13, 2020 11:56:08 AM org.apache.catalina.core.StandardService startInternal Information: Starting service Catalina November 13, 2020 11:56:08 AM org.apache.catalina.core.StandardEngine startInternal Information: Starting Servlet Engine: Apache Tomcat/8.0.5 November 13, 2020 11:56:12 AM org.apache.catalina.core.ApplicationContext log INFO: No Spring WebApplicationInitializer types detected on classpath November 13, 2020 11:56:12 AM org.apache.coyote.AbstractProtocol start INFO: Starting ProtocolHandler ["http-nio-8080"] November 13, 2020 11:56:12 AM org.apache.coyote.AbstractProtocol start INFO: Starting ProtocolHandler ["ajp-nio-8009"] November 13, 2020 11:56:12 AM org.apache.catalina.startup.Catalina start INFO: Server startup in 3826 ms November 13, 2020 11:56:13 AM org.apache.catalina.core.ApplicationContext log INFO: Initializing Spring FrameworkServlet 'SpringMVC' November 13, 2020 11:56:13 AMorg.springframework.web.servlet.DispatcherServlet initServletBean INFO: FrameworkServlet 'SpringMVC': initialization started November 13, 2020 11:56:13 AM org.springframework.web.context.support.XmlWebApplicationContext prepareRefresh INFO: Refreshing WebApplicationContext for namespace 'SpringMVC-servlet': startup date [Fri Nov 13 11:56:13 CST 2020]; root of context hierarchy November 13, 2020 11:56:13 AM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from file [G:\Language Proctice\java\pro\20201109\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\CRMSystem\WEB-INF\classes\spring\spring-dao.xml] November 13, 2020 11:56:13 AM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from file [G:\Language Proctice\java\pro\20201109\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\CRMSystem\WEB-INF\classes\spring\spring-mvc.xml] November 13, 2020 11:56:13 AM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from file [G:\Language Proctice\java\pro\20201109\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\CRMSystem\WEB-INF\classes\spring\spring-service.xml] November 13, 2020 11:56:14 AM org.springframework.context.support.PropertySourcesPlaceholderConfigurer loadProperties INFO: Loading properties file from class path resource [jdbc.properties] November 13, 2020 11:56:14 AM com.mchange.v2.log.MLog <clinit> Info: MLog clients using java 1.4+ standard logging. November 13, 2020 11:56:14 AMcom.mchange.v2.c3p0.C3P0Registry banner INFO: Initializing c3p0-0.9.1.2 [built 21-May-2007 15:04:56; debug? true; trace: 10] 11:56:14,733 |-INFO in ch.qos.logback.classic.LoggerContext[default] - Could NOT find resource [logback.groovy] 11:56:14,734 |-INFO in ch.qos.logback.classic.LoggerContext[default] - Could NOT find resource [logback-test.xml] 11:56:14,734 |-INFO in ch.qos.logback.classic.LoggerContext[default] - Found resource [logback.xml] at [file:/G:/Language%20Proctice/java/pro/20201109/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/CRMSystem/WEB-INF/classes/logback.xml] 11:56:14,868 |-INFO in ch.qos.logback.core.joran.action.AppenderAction - About to instantiate appender of type [ch.qos.logback.core.ConsoleAppender] 11:56:14,878 |-INFO in ch.qos.logback.core.joran.action.AppenderAction - Naming appender as [STDOUT] 11:56:14,911 |-INFO in ch.qos.logback.core.joran.action.NestedComplexPropertyIA - Assuming default type [ch.qos.logback.classic.encoder.PatternLayoutEncoder] for [encoder] property 11:56:15,026 |-INFO in ch.qos.logback.classic.joran.action.RootLoggerAction - Setting level of ROOT logger to DEBUG 11:56:15,026 |-INFO in ch.qos.logback.core.joran.action.AppenderRefAction - Attaching appender named [STDOUT] to Logger[ROOT] 11:56:15,029 |-INFO in ch.qos.logback.classic.joran.action.ConfigurationAction - End of configuration. 11:56:15,031 |-INFO in ch.qos.logback.classic.joran.JoranConfigurator@5ad72777 - Registering current configuration as safe fallback point 11:56:15.057 [http-nio-8080-exec-2] DEBUG org.apache.ibatis.logging.LogFactory - Logging initialized using 'class org.apache.ibatis.logging.slf4j.Slf4jImpl' adapter. 11:56:15.272 [http-nio-8080-exec-2] DEBUG org.apache.ibatis.io.VFS - Class not found: org.jboss.vfs.VFS 11:56:15.272 [http-nio-8080-exec-2] DEBUG org.apache.ibatis.io.JBoss6VFS - JBoss 6 VFS API is not available in this environment. 11:56:15.275 [http-nio-8080-exec-2] DEBUG org.apache.ibatis.io.VFS - Class not found: org.jboss.vfs.VirtualFile 11:56:15.277 [http-nio-8080-exec-2] DEBUG org.apache.ibatis.io.VFS - VFS implementation org.apache.ibatis.io.JBoss6VFS is not valid in this environment. 11:56:15.277 [http-nio-8080-exec-2] DEBUG org.apache.ibatis.io.VFS - Using VFS adapter org.apache.ibatis.io.DefaultVFS 11:56:15.279 [http-nio-8080-exec-2] DEBUG omspring.SqlSessionFactoryBean - Scanned package: 'com.crm.entity' for aliases 11:56:15.367 [http-nio-8080-exec-2] DEBUG omspring.SqlSessionFactoryBean - Parsed configuration file: 'class path resource [mybatis-config.xml]' 11:56:15.369 [http-nio-8080-exec-2] DEBUG omspring.SqlSessionFactoryBean - Property 'mapperLocations' was not specified or no matching resources found November 13, 2020 11:56:16 AM org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter initControllerAdviceCache Info: Looking for @ControllerAdvice: WebApplicationContext for namespace 'SpringMVC-servlet': startup date [Fri Nov 13 11:56:13 CST 2020]; root of context hierarchy November 13, 2020 11:56:16 AM org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter initControllerAdviceCache Info: Looking for @ControllerAdvice: WebApplicationContext for namespace 'SpringMVC-servlet': startup date [Fri Nov 13 11:56:13 CST 2020]; root of context hierarchy November 13, 2020 11:56:16 AM org.springframework.web.servlet.handler.SimpleUrlHandlerMapping registerHandler INFO: Mapped URL path [/resources/**] onto handler 'org.springframework.web.servlet.resource.ResourceHttpRequestHandler#0' November 13, 2020 11:56:16 AM org.springframework.web.servlet.handler.SimpleUrlHandlerMapping registerHandler Info: Mapped URL path [/**] onto handler 'org.springframework.web.servlet.resource.DefaultServletHttpRequestHandler#0' November 13, 2020 11:56:16 AMorg.springframework.web.servlet.DispatcherServlet initServletBean INFO: FrameworkServlet 'SpringMVC': initialization completed in 3240 ms At first, I thought it was a problem with the SSM environment and that spirng-mvc was not configured correctly, but after carefully observing the logs, I could see: Spring MVC has successfully taken over my static resources November 13, 2020 11:56:13 AMorg.springframework.web.servlet.DispatcherServlet initServletBean INFO: FrameworkServlet 'SpringMVC': initialization started November 13, 2020 11:56:16 AMorg.springframework.web.servlet.DispatcherServlet initServletBean All three spring configuration files have been loaded into the environment November 13, 2020 11:56:13 AM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from file [G:\Language Proctice\java\pro\20201109\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\CRMSystem\WEB-INF\classes\spring\spring-dao.xml] November 13, 2020 11:56:13 AM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from file [G:\Language Proctice\java\pro\20201109\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\CRMSystem\WEB-INF\classes\spring\spring-mvc.xml] November 13, 2020 11:56:13 AM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions INFO: Loading XML bean definitions from file [G:\Language Proctice\java\pro\20201109\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\CRMSystem\WEB-INF\classes\spring\spring-service.xml] The resource directory and orm mapping model directory have been loaded November 13, 2020 11:56:16 AM org.springframework.web.servlet.handler.SimpleUrlHandlerMapping registerHandler INFO: Mapped URL path [/resources/**] onto handler 'org.springframework.web.servlet.resource.ResourceHttpRequestHandler#0' November 13, 2020 11:56:16 AM org.springframework.web.servlet.handler.SimpleUrlHandlerMapping registerHandler Info: Mapped URL path [/**] onto handler 'org.springframework.web.servlet.resource.DefaultServletHttpRequestHandler#0' So to eliminate the doubts about the ssm environment configuration, I checked tomcat again. After checking that the port number was not occupied, I replaced tomcat8.0.5 with tomcat8.5 . This is the end of this article about the problem that tomcat deployed applications cannot access the front-end page. For more related content about tomcat deployment cannot access the page, please search for previous articles on 123WORDPRESS.COM or continue to browse the following related articles. I hope everyone will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: MySQL 8.0.22 installation and configuration method graphic tutorial under Windows 10
>>: Example code of vue custom component to implement v-model two-way binding data
Solution: Just set the link's target attribute...
Preface Before, I used cache to highlight the rou...
There is a difference between src and href, and t...
Table of contents Preface What is a filter How to...
Introduction By enabling the slow query log, MySQ...
hint This plug-in can only be accessed under the ...
Table of contents 1. Introduction 2. Main text 2....
1. Use the installation package to install MySQL ...
I won’t talk about the use of SSL certificates. F...
Performance of union all in MySQL 5.6 Part 1:MySQ...
Table of contents Vue.js 1. Register global guard...
The first method: dynamically add a class to show...
The database installation tutorial of MySQL-8.0.2...
Table of contents Pull a centos image Generate ng...
Table of contents Preface 1. Environment Configur...