Direct access to HTML error under Tomcat, said resource not found (404) __java base

Source: Internet
Author: User

Today, because of work needs, I want to put an HTML directly into Tomcat (clean tomcat) without any modifications. To access, and then based on experience directly under the WebApps created a folder test, and then the need to test.html to the following, through Localhost:8080/test/test.html, the interface appeared 404 errors, thinking that they think wrong, Started online search, someone on the internet said to be under test to create a web-inf directory, There's a corresponding web.xml, then according to the corresponding operation began to do, found still not, the following I have tried a lot of online solutions, are not, finally colleagues said to me a copy of his tomcat, he gave me is Tomcat6, I also tried, found not yet. But found the error, title is still TOMCAT5 title, finally I found the problem, because my local configuration of Catalina_home, so the root is not my this tomcat, is another, finally I put the environment variable in Catalina _home Remove, reboot, OK, and do not create web-inf directory to access directly,

Finally I found the problem is this, if it is a clean tomcat, if the native environment variables are not configured in the Catalina_home, it is not start up, you need to specify the corresponding java_home, this network a lot of, I added set Java_home=d:\program files\java\jdk1.6.0_18 directly in the Catalina.bat. After startup, it's OK.

Are some very superficial things, in this record, for the same as my small white reference.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.