How to setup local Tomcat for Eclipse

Usually, Eclipse supports Tomcat by default. However, you need to tweak some settings of Tomcat manually to make everything work as expect. The most common thing that does not work correctly is manager. After starting Tomcat, you are able to access the manager at http://localhost:8080/manager/html. However, you may get message as follow.

access to the requested resource has been denied.

The status code is 403 which indicates forbidden access. If you don't use manager, it's fine. Anyway, you might want to use manager to undeploy or deploy web applications.

Solution to this problem is very simple. You have to add manager to tomcat-users.xml as follow.



  
  
  
  
  
  
  

That means you are able to use user "tomcat" and password "tomcat" to access the manager as a manager. Note that tomcat-users.xml locates in conf/.

Tags: ,

Post new comment