How to add users at tomcat manager in a cpanel server
Written on 4:30 AM by David S Anand
Follow the steps
nano /usr/local/apache/conf/userdata/std/1/username/domainname.com/cp_jkmount.conf
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
JkMount /servlets/* ajp13
JkMount /*.do ajp13
Add one more line "JkMount /manager/* ajp13"
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
JkMount /servlets/* ajp13
JkMount /manager/* ajp13
JkMount /*.do ajp13
Do same as above for the following:
nano /usr/local/apache/conf/userdata/std/2/username/domainname.com/cp_jkmount.conf
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
JkMount /servlets/* ajp13
JkMount /*.do ajp13
Add one more line "JkMount /manager/* ajp13"
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
JkMount /servlets/* ajp13
JkMount /manager/* ajp13
JkMount /*.do ajp13
Once done restart tomcat and httpd service and check and if you need to reset for client tomcat manager then edit the following file:
nano /usr/local/jakarta/apache-tomcat-5.5.25/conf/tomcat-users.xml
change password for the perticular user from there and then again reset apache and tomcat service and check.
================================================
Under WHM/cpanel server you can enable JSP_tomcat from WHM -->>Account Functions-->>Install Servlets-->> Select the user for which you need to enable JSP-tomcat.
Alternately you can add the servlet in command line
scripts/addserverlets2 --domain=
Once JSP_tomcat is installed from WHM then login to SSH and under httpd.conf user virtual entry you will see the following:
JkMount /servlet/* ajp13
JkMount /servlets/* ajp13
JkMount /manager/* ajp13
JkMount /*.do ajp13
And then edit "/usr/local/jakarta/jakarta-tomcat-5.5.9/conf]# nano tomcat-users.xml" change password for the perticular user from there and then again reset apache and tomcat service and check.
user username="XXXX" password="xxxxx" roles="manager"/
