After installing a new Tomcat server, there will be no user created by default to access Administrator and Manager web interfaces. After completing the installation set up Tomcat Admin and Manager user accounts and set their passwords. You can also visit our following articles about installing Tomcat on Linux systems. How to Change Tomcat Administrator Password To create user account edit conf/tomcat-users.xml file in editor and copy below configuration inside the <tomcat-users>…</tomcat-users> tags.
1 2 3 4 5 6 7 | <tomcat-users> <!-- User admin can access manager and admin section both --> <role rolename="admin-gui" /> <user username="admin" password="_SECRET_PASSWORD_" roles="manager-gui,admin-gui" /> </tomcat-users> |
How to Change Tomcat Manager Password
1 2 3 4 5 6 7 8 9 10 11 | <tomcat-users> <!-- User manager can access only manager section --> <role rolename="manager-gui" /> <user username="manager" password="_SECRET_PASSWORD_" roles="manager-gui" /> <!-- User admin can access manager and admin section both --> <role rolename="admin-gui" /> <user username="admin" password="_SECRET_PASSWORD_" roles="manager-gui,admin-gui" /> </tomcat-users> |
As per the above configuration user manager only can access the manager web interface but the admin can access…