5

i have installed eclipse on Windows Vista and i have added a new Apache Tomcat server Apache Tomcat/7.0.27.

After i start the Apache in eclipse, i type in the url the following address "localhost:8080"

i get a page saying:

HTTP Status 404 - /
type Status report
message /
description The requested resource (/) is not available.
Apache Tomcat/7.0.27
programmer
  • 4,571
  • 13
  • 49
  • 59
  • What is the default context? Cause i can't find it – programmer Jun 12 '12 at 19:12
  • 1
    possible duplicate of [Tomcat started in eclipse but unable to connect to link to http://localhost:8085/](http://stackoverflow.com/questions/2280064/tomcat-started-in-eclipse-but-unable-to-connect-to-link-to-http-localhost8085) – BalusC Jun 12 '12 at 19:23
  • Thanks, i had already tried to "Use Tomcat Installation" in the Overview window of Apache but it didn't work. The console for the logs showed a lot of 'severe' errors and access denied messages. So, the apache didn't start at all. – programmer Jun 12 '12 at 19:53
  • The problem with my installation is that the official page of Tomcat is not shown (localhost:8080). But the log console of Eclipse outputs 'INFO: Server startup in 254 ms', that means that the tomcat is running, right? – programmer Jun 12 '12 at 19:54
  • 1
    Yes. If the server didn't run, you would have gotten a browser specific connection timeout message, exactly the one you would get on `http://localhost:random-port` like `http://localhost:12345`. But you're retrieving **Tomcat's own** error page, so it runs perfectly fine, there's just nothing been deployed to the root. As to the problems which you faced when changing the server location, you might want to share the error messages which you got instead of ignoring them as if they're for decoration only. They namely contain the answer and we're able to explain them in layman's terms for you. – BalusC Jun 12 '12 at 20:11
  • Did you use the installer or just an archive? I've encountered this problem a couple of times, when using the installer. I never bothered to find out what the cause was as downloading and unpacking the zip usually did the trick. – toniedzwiedz Jun 12 '12 at 21:07
  • I found out what my problem was.I had installed apache under "C:\Program Files\apache" directory. I changed the location to be under "C:\apache" directory. After that, i was getting the same error:HTTP Status 404 - /. So, i tried again the post "http://stackoverflow.com/questions/2280064/tomcat-started-in-eclipse-but-unable-to-connect-to-link-to-http-localhost8085" and now it's working fine. – programmer Jun 13 '12 at 15:04

1 Answers1

15

Hi I faced same problem and below steps resolved the problem.

  1. In the eclipse right click on server and click on properties.
  2. If Location is set workspace/metadata click on switch location and so that it refers to /servers/tomcatv7server at localhost.server
  3. Save and close
  4. Next double click on server
  5. Under server locations mostly it would be selected as useworkspacemetadata
  6. Instead, select usetomcatinstallation
  7. Save changes
  8. Restart server and verify localhost:8080 works.
George Stocker
  • 57,289
  • 29
  • 176
  • 237
PavanJoshi
  • 151
  • 1
  • 3