Apache Tomcat 8 Login issues

August 3, 2017 Leave a comment

Issue:
After installing Apache Tomcat7/8 in Linux/windows everybody facing common issue is 403 Access Denied after you click on manager gui/server status etc..

http://10.207.47.128:8080/

Download apache Tomcat8 from below link: https://tomcat.apache.org/download-80.cgi

Resolution :

Option 1: 

To overcome this issues, follow below 3 step.

Step:1
Need to add below entries in /app/tomcat8/conf/tomcat-users.xml file

<role rolename=”manager-gui,manager-script,manager-jmx,manager-status”/>
<user username=”admin” password=”admin” roles=”manager-gui,manager-script,manager-jmx,manager-status”/>
</tomcat-users>

Note: I given credentials for POC purpose, please change as per your requirement.

Step2:

To get authenticate for manager GUI go to /app/tomcat8/webapps/manager/META-INF/context.xml and comment below entry

<Context antiResourceLocking=”false” privileged=”true” >
<!– <Valve className=”org.apache.catalina.valves.RemoteAddrValve”
allow=”127\.\d+\.\d+\.\d+|::1|0:0:0:0:0:0:0:1″ />
–>
<Manager sessionAttributeValueClassNameFilter=”java\.lang\.(?:Boolean|Integer|Long|Number|String)|org\.apache\.catalina\.filters\.CsrfPreventionFilter\$LruCache(?:\$1)?|java\.util\.(?:Linked)?HashMap”/>

Step 3:

To authenticate host-manager gui
Goto path /app/tomcat8/webapps/host-manager/META-INF/context.xml and comment below Value tag

<Context antiResourceLocking=”false” privileged=”true” >
<!– <Valve className=”org.apache.catalina.valves.RemoteAddrValve”
allow=”127\.\d+\.\d+\.\d+|::1|0:0:0:0:0:0:0:1″ />
–>
<Manager sessionAttributeValueClassNameFilter=”java\.lang\.(?:Boolean|Integer|Long|Number|String)|org\.apache\.catalina\.filters\.CsrfPreventionFilter\$LruCache(?:\$1)?|java\.util\.(?:Linked)?HashMap”/>
</Context>

 

Option 2:

we can create two files under below path
/app/tomcat8/conf/Catalina/localhost

manager.xml:

<Context privileged=”true” antiResourceLocking=”false” docBase=”${catalina.home}/webapps/manager”>
<Valve className=”org.apache.catalina.valves.RemoteAddrValve” allow=”^.*$” />
</Context>

host-manager.xml

<Context privileged=”true” antiResourceLocking=”false” docBase=”${catalina.home}/webapps/host-manager”>
<Valve className=”org.apache.catalina.valves.RemoteAddrValve” allow=”^.*$” />
</Context>

After changes done ,need to restart tomcat and you will be authenticate using the credentials which you mentioned in tomcat-users.xml  file

 

Advertisements
Categories: Apache tomcat Tags:

100-shell-script-examples

April 20, 2017 Leave a comment
Categories: Unix info

Power-user plugin for powerpoint

February 8, 2017 Leave a comment
Categories: Articles Tags:

Kolanu Bharathi

December 6, 2016 Leave a comment

This below blog will help you are going to kolanu bharathi for there child Aksharabhaysam

http://bharatdevotional.blogspot.in/2015/09/andhra-pradesh-saraswathi-temple-kolanu.html

 

Categories: Uncategorized

Thread and GC logs Analysis

November 25, 2016 Leave a comment

Here is best free online tools for analyzing the thread dump and GC logs

Thread Dump–>http://fastthread.io/

GC Logs–> http://gceasy.io/

Note: formats  (uncompressed or .zip, .gz formats,.txt,.log )

Categories: JVM Tags:

50 Ways to Relax Without Spending Money

November 8, 2016 Leave a comment

50 Ways to Relax Without Spending Money

Categories: Articles Tags:

One more KB article

October 27, 2016 Leave a comment

Here is one more URL ,where you can find everything for system admin requirement

https://geekflare.com/

https://geekflare.com/category/web-infrastructure/

Categories: Articles Tags: