Jump to content

Jboss and PostgresSQL Tuning for Muthoot ERP Environment: Difference between revisions

From TetraWiki
Line 61: Line 61:


  #  JAVA_OPTS="-Xms128m -Xmx512m -XX:MaxPermSize=256m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"
  #  JAVA_OPTS="-Xms128m -Xmx512m -XX:MaxPermSize=256m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"
  JAVA_OPTS="-Xms12288m -Xmx12288m -XX:MaxPermSize=256m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"
  JAVA_OPTS="'''-Xms12288m -Xmx12288m''' -XX:MaxPermSize=256m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"


Test via  
Test via  


  ps -ef | grep java
  ps -ef | grep java

Revision as of 11:21, 12 August 2013


Objective : Tuning of Jboss (192.168.1.129) and PostgreSQl (Cluster- 192.168.1.140) for Muthoot Group


Issue : long Report from Application makes the JBOSS Server to hung and Finally we have restart the server . The Long report was not coming even after 1+ hours .

Approach :

  1. Tune postgreSql to use high available memory
  2. Tune JBOSS to use high available memory


PostgreSQL Tuning and Process

Install pgtune rpm package

yum install pgtune

Create a Sample configuration file based on current environment

pgtune -i /var/lib/pgsql/data/postgresql.conf -o post-pgtune.conf.sample

Check the difference between the created "post-pgtune.conf.sample" and Current "/var/lib/pgsql/data/postgresql.conf" diff post-pgtune.conf.sample /var/lib/pgsql/data/postgresql.conf

As Muthoot Environment is on Redhat Cluster suite , check the cluster status via

clustat 

Stop the Cluster Services , which will bring down the postgresql too

clusvcadm -s Cluster-Service
cd /var/lib/pgsql/data/
chown postgres.postgres post-pgtune.conf.sample
cp -pvr postgresql.conf postgresql.conf.org_backedup_on_25_july_2013
cp -pvr post-pgtune.conf.sample postgresql.conf

Start the cluster so that PostgreSQL will start along

clusvcadm -R Cluster-Service

Test the environment

clustat 
ps -ef | grep postgre

JBOSS Tuning and Process

The Ram allocated to Jboss was less so needs to increase

Open the Jboss's run.conf file

vi /usr/bin/jboss-6.0.0.Final/bin/run.conf

Modify the old to new as shown below

#   JAVA_OPTS="-Xms128m -Xmx512m -XX:MaxPermSize=256m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"
JAVA_OPTS="-Xms12288m -Xmx12288m -XX:MaxPermSize=256m -Dorg.jboss.resolver.warning=true -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"

Test via

ps -ef | grep java