This week's book giveaway is in the Java in General forum.
We're giving away four copies of Think Java: How to Think Like a Computer Scientist and have Allen B. Downey & Chris Mayfield on-line!
See this thread for details.
Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

username and password for tomcat manager

 
PS Toh
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I download the tomcat5.5.20 zip file and unzip it. when I access localhost:8080, the first page appear, however what is the username and password for status and tomcat manager at the admin panel. The default should be admin for username and blank for password, but it cannot be used here.

Anyone know what is the default username and password?

Thanks.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is no default username/password.
This is intentional and was done this way for security purposes.
You can set them yourself by editing the tomcat/conf/tomcat-users.xml file.
 
PS Toh
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for reply.

I change username and tomcat below to "admin", but I still cannot use it to access tomcat manager.

<?xml version='1.0' encoding='utf-8'?>
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="role1"/>
<user username="tomcat" password="tomcat" roles="tomcat"/>
<user username="both" password="tomcat" roles="tomcat,role1"/>
<user username="role1" password="tomcat" roles="role1"/>
</tomcat-users>


May I know how to modify and set the username and password.

Thanks.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The admin and manager apps are two separate things.
Here's a snapshot of a tomcat-users.xml file that works.


Obviously, you'll want to replace the username and password (in caps).
 
PS Toh
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ya, it works, thanks for helping.
 
Michael Carlson
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm having the same problem, but this did not work for me. I get invaled username or password. I'm using netbeans 5.0 if this makes a difference.
Thank you
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Michael,
Try starting a new thread in the IDEs forum.
If that config file doesn't work in your Tomcat install, then maybe Netbeans has altered it's embedded version of Tomcat.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic