0
我已將Web應用程序部署到Tomcat 7.0.47,但是我看到404狀態。 我可以正常訪問Tomcat主頁和Tomcat應用程序管理器。Tomcat 7已部署Web應用程序404狀態
下面是日誌文件: catalina.2016-07-13
Jul 13, 2016 8:51:29 AM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jdk1.8.0_31\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:\ProgramData\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Intel\OpenCL SDK\3.0\bin\x86;C:\Program Files (x86)\Intel\OpenCL SDK\3.0\bin\x64;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;F:\MATLAB\R2014a\runtime\win64;F:\MATLAB\R2014a\bin;C:\Program Files\MATLAB\R2012a\runtime\win64;C:\Program Files\MATLAB\R2012a\bin;C:\Program Files (x86)\PharosSystems\Core;c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\;c:\Program Files (x86)\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files (x86)\MySQL\MySQL Fabric 1.5 & MySQL Utilities 1.5\;C:\Program Files (x86)\MySQL\MySQL Fabric 1.5 & MySQL Utilities 1.5\Doctrine extensions for PHP\;C:\Program Files\apache-maven-3.3.9-bin\bin;C:\Program Files (x86)\Skype\Phone\;C:\Program Files (x86)\MiKTeX 2.9\miktex\bin\;.
Jul 13, 2016 8:51:29 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Jul 13, 2016 8:51:29 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Jul 13, 2016 8:51:29 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 514 ms
Jul 13, 2016 8:51:29 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Jul 13, 2016 8:51:29 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.47
Jul 13, 2016 8:51:29 AM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deploying web application archive C:\apache-tomcat-7.0.47\webapps\cs144.war
Jul 13, 2016 8:51:30 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory C:\apache-tomcat-7.0.47\webapps\docs
Jul 13, 2016 8:51:30 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory C:\apache-tomcat-7.0.47\webapps\examples
Jul 13, 2016 8:51:30 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory C:\apache-tomcat-7.0.47\webapps\host-manager
Jul 13, 2016 8:51:31 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory C:\apache-tomcat-7.0.47\webapps\manager
Jul 13, 2016 8:51:31 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory C:\apache-tomcat-7.0.47\webapps\ROOT
Jul 13, 2016 8:51:31 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory C:\apache-tomcat-7.0.47\webapps\Struts2Example
Jul 13, 2016 8:51:31 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory C:\apache-tomcat-7.0.47\webapps\zurmo
Jul 13, 2016 8:51:31 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Jul 13, 2016 8:51:31 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
Jul 13, 2016 8:51:31 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 1435 ms
localhost.2016-07-13
Jul 13, 2016 8:51:30 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
Jul 13, 2016 8:51:30 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
Jul 13, 2016 8:51:30 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: attributeAdded('org.apache.jasper.compiler.TldLocationsCache', '[email protected]')
localhost_access_log.2016-07-13
0:0:0:0:0:0:0:1 - admin [13/Jul/2016:08:53:14 +0430] "POST /manager/html/upload?org.apache.catalina.filters.CSRF_NONCE=210FE5528CB1E9D58F23E5A11655B102 HTTP/1.1" 403 3287
0:0:0:0:0:0:0:1 - - [13/Jul/2016:08:53:14 +0430] "GET /favicon.ico HTTP/1.1" 200 21630
0:0:0:0:0:0:0:1 - - [13/Jul/2016:08:53:18 +0430] "GET /manager/ HTTP/1.1" 302 -
0:0:0:0:0:0:0:1 - admin [13/Jul/2016:08:53:18 +0430] "GET /manager/html?org.apache.catalina.filters.CSRF_NONCE=7D8792E571C6ABBD8D35351293AF54B8 HTTP/1.1" 200 20949
0:0:0:0:0:0:0:1 - - [13/Jul/2016:08:53:33 +0430] "GET /cs144/ HTTP/1.1" 404 963
manager.2016-07-13
Jul 13, 2016 8:53:14 AM org.apache.catalina.core.ApplicationContext log
INFO: HTMLManager: init: Associated with Deployer 'Catalina:type=Deployer,host=localhost'
Jul 13, 2016 8:53:14 AM org.apache.catalina.core.ApplicationContext log
INFO: HTMLManager: init: Global resources are available
Jul 13, 2016 8:53:18 AM org.apache.catalina.core.ApplicationContext log
INFO: HTMLManager: list: Listing contexts for virtual host 'localhost'
「cs144」webapp是如何配置的?它是否包含'index.jsp'或'index.html'文件?還是有一個servlet被配置爲處理'/'請求? –
感謝您的迴應,它包含results.jsp,但我不知道如何配置servlet來處理/請求。你能告訴我我該怎麼做嗎? –
使用'web.xml'中的''工具。在嘗試之前,請繼續查看對/ cs144/results.jsp的請求是否成功。如果是這樣,你只需要一個''將'/'的請求重新路由到'/ results.jsp'。 –