According to the instructions in some blogs I tried to modify the C:\Program Files\Apache Software Foundation\Tomcat 7.0\conf\tomcat-users.xml
file as
<?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"/> --> <role rolename="manager"/> <role rolename="admin"/> <user username="admin" password="admin" roles="admin,manager"/> </tomcat-users>
But Save Failed dialog box is appearing with the text " Please check if this file is opened in another program". But I am sure that none of the programs are started/running related to this file. The modification permission is denied. what is the reason..?
Open the tomcat-users. xml file, which is located by default in $CATALINA_HOME\conf\tomcat-users. xml.
XML. The server. xml file is Tomcat's main configuration file, and is responsible for specifying Tomcat's initial configuration on startup as well as defining the way and order in which Tomcat boots and builds.
Solution. To change the Apache Tomcat Administration Console password, perform the following: Edit the [CCMS Web Path]/apache-tomcat-[version]/conf/tomcat-users. xml file and update the password.
I think the reason is that you can't edit files in "Program Files" without administrator rights.
I had that kind of problem several times and I usually solve it by running my text editor with admin rights.
For example, to edit file with notepad in Windows 7: Find it in your start menu, click on it with right mouse button. You should be able to choose "run as administrator" from the context menu. Now edit the file and you should be able to save it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With