老师,我这个报404错误怎么回事

老师,我这个报404错误怎么回事

server里output面的内容:

"C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35\bin\catalina.bat" run
[2019-05-07 03:07:22,665] Artifact icake:war exploded: Waiting for server connection to start artifact deployment...
Using CATALINA_BASE:   "C:\Users\贾远志\.IntelliJIdea2019.1\system\tomcat\Unnamed_icake_4"
Using CATALINA_HOME:   "C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35"
Using CATALINA_TMPDIR: "C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35\temp"
Using JRE_HOME:        "C:\Program Files\Java\jdk1.8.0_181"
Using CLASSPATH:       "C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35\bin\bootstrap.jar;C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35\bin\tomcat-juli.jar"
Connected to the target VM, address: '127.0.0.1:54354', transport: 'socket'
07-May-2019 15:07:23.844 警告 [main] org.apache.catalina.startup.ClassLoaderFactory.validateFile Problem with directory [C:\Users\??????\Desktop\java note\apache-tomcat-8.5.35\lib], exists: [false], isDirectory: [false], canRead: [false]
07-May-2019 15:07:23.846 警告 [main] org.apache.catalina.startup.ClassLoaderFactory.validateFile Problem with directory [C:\Users\??????\Desktop\java note\apache-tomcat-8.5.35\lib], exists: [false], isDirectory: [false], canRead: [false]
07-May-2019 15:07:24.263 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server version:        Apache Tomcat/8.5.35
07-May-2019 15:07:24.264 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server built:          Nov 3 2018 17:39:20 UTC
07-May-2019 15:07:24.264 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Server number:         8.5.35.0
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Name:               Windows 10
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log OS Version:            10.0
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Architecture:          amd64
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Java Home:             C:\Program Files\Java\jdk1.8.0_181\jre
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Version:           1.8.0_181-b13
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Vendor:            Oracle Corporation
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_BASE:         C:\Users\贾远志\.IntelliJIdea2019.1\system\tomcat\Unnamed_icake_4
07-May-2019 15:07:24.267 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_HOME:         C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.config.file=C:\Users\贾远志\.IntelliJIdea2019.1\system\tomcat\Unnamed_icake_4\conf\logging.properties
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -agentlib:jdwp=transport=dt_socket,address=127.0.0.1:54354,suspend=y,server=n
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -javaagent:C:\Users\贾远志\.IntelliJIdea2019.1\system\captureAgent\debugger-agent.jar
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote=
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote.port=1099
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote.ssl=false
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote.password.file=C:\Users\贾远志\.IntelliJIdea2019.1\system\tomcat\Unnamed_icake_4\jmxremote.password
07-May-2019 15:07:24.268 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcom.sun.management.jmxremote.access.file=C:\Users\贾远志\.IntelliJIdea2019.1\system\tomcat\Unnamed_icake_4\jmxremote.access
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.rmi.server.hostname=127.0.0.1
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djdk.tls.ephemeralDHKeySize=2048
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.protocol.handler.pkgs=org.apache.catalina.webresources
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dignore.endorsed.dirs=
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.base=C:\Users\贾远志\.IntelliJIdea2019.1\system\tomcat\Unnamed_icake_4
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.home=C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35\temp
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR based Apache Tomcat Native library [1.2.18] using APR version [1.6.5].
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true].
07-May-2019 15:07:24.269 信息 [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
07-May-2019 15:07:24.273 信息 [main] org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL successfully initialized [OpenSSL 1.1.1  11 Sep 2018]
07-May-2019 15:07:24.526 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8080"]
07-May-2019 15:07:24.554 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
07-May-2019 15:07:24.600 信息 [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["ajp-nio-8009"]
07-May-2019 15:07:24.605 信息 [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
07-May-2019 15:07:24.606 信息 [main] org.apache.catalina.startup.Catalina.load Initialization processed in 709 ms
07-May-2019 15:07:24.662 信息 [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina]
07-May-2019 15:07:24.663 信息 [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.5.35
07-May-2019 15:07:24.673 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8080"]
07-May-2019 15:07:24.687 信息 [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["ajp-nio-8009"]
07-May-2019 15:07:24.693 信息 [main] org.apache.catalina.startup.Catalina.start Server startup in 86 ms
Connected to server
[2019-05-07 03:07:24,958] Artifact icake:war exploded: Artifact is being deployed, please wait...
07-May-2019 15:07:26.800 信息 [RMI TCP Connection(3)-127.0.0.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.
[2019-05-07 03:07:26,909] Artifact icake:war exploded: Artifact is deployed successfully
[2019-05-07 03:07:26,910] Artifact icake:war exploded: Deploy took 1,953 milliseconds
07-May-2019 15:07:34.675 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35\webapps\manager]
07-May-2019 15:07:34.844 信息 [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.
07-May-2019 15:07:34.873 信息 [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [C:\Users\贾远志\Desktop\java note\apache-tomcat-8.5.35\webapps\manager] has finished in [197] ms


http://img1.sycdn.imooc.com//climg/5cd12f2d00013d1018330447.jpg

正在回答 回答被采纳积分+1

登陆购买课程后可参与讨论,去登陆

4回答
好帮手慕阿满 2019-05-07 18:54:27

问一下同学在web.xml中有如下的servlet和servlet-mapping吗?

http://img1.sycdn.imooc.com//climg/5cd1636c0001835506130172.jpg

在GlobalController类中是否有如下的判断呢。

http://img1.sycdn.imooc.com//climg/5cd163ad0001ca0f05090315.jpg

建议同学检查一下。如果有,并且还报错,建议同学将web.xml和GlobalController的代码贴一下,贴代码时,记得贴在回答中。

祝:学习愉快~

好帮手慕阿满 2019-05-07 17:52:03

同学你好,问一下同学在web.xml中是否配置如下过滤器呢?

http://img1.sycdn.imooc.com//climg/5cd1552800019df506130197.jpg

建议同学检查一下。

祝:学习愉快~

  • 提问者 再也不玩游戏 #1
    我是跟着老师的步骤走的,这一步还没有写这个LoginFilter过滤器呢,视频里就可以就可以启动项目了啊
    2019-05-07 17:59:13
提问者 再也不玩游戏 2019-05-07 16:34:27

http://img1.sycdn.imooc.com//climg/5cd142ff0001b75418320942.jpg

这是我4.4的页面

好帮手慕阿满 2019-05-07 16:30:33

同学你好,404错误是访问资源不存在的问题。问一下同学的访问路径是什么。建议将报404错误的页面贴一下。

祝:学习愉快~

问题已解决,确定采纳
还有疑问,暂不采纳

恭喜解决一个难题,获得1积分~

来为老师/同学的回答评分吧

0 星
Java数据库开发与实战应用2018版
  • 参与学习           人
  • 提交作业       277    份
  • 解答问题       4297    个

Java数据库开发的必备技能,从流行的MySQL数据库开始,到Java原生的数据库管理接口JDBC的使用,再到常用的数据持久化框架MyBatis,让你向Java工程师的目标又迈进了一步!

了解课程
请稍等 ...
意见反馈 帮助中心 APP下载
官方微信

在线咨询

领取优惠

免费试听

领取大纲

扫描二维码,添加
你的专属老师