RE: OC4J Process Architecture

  • From: "Adrian Turner" <adrian@xxxxxxxxxxxxxxxxxxxxxx>
  • To: <oracle-l@xxxxxxxxxxxxx>
  • Date: Mon, 14 Jun 2004 20:31:52 +0100

Hi Jurijs,

OC4J started out life as the Orion Application Server. Check out
http://www.orionserver.com/ as there is a doc library there which is likely
still valid.

A good approach seems to be to build a repeatable install process using the
automation tools (dcmctl and admin.jar).  If you get a problem take a
slash/burn/rebuild approach to the whole installation; this seems to solve a
lot of corruption issues.

After that, if you still get problems, do what we have and pay to have a
technically current Oracle Corporation consultant onsite. A good one can
pretty much spot a bug 50 hours before support will. His approach is
normally to reverse engineer the code from the JAR files (actually anyone
can), check the problem out himself and then tell support what needs fixing.
At least you will know what you are dealing with if you can see the code.

Kind Regards,
Adrian

  -----Original Message-----
  From: oracle-l-bounce@xxxxxxxxxxxxx
[mailto:oracle-l-bounce@xxxxxxxxxxxxx]On Behalf Of J.Velikanovs@xxxxxxxx
  Sent: 13 June 2004 18:05
  To: oracle-l@xxxxxxxxxxxxx
  Subject: OC4J Process Architecture



  OC4J Process Architecture

  1 year ago, management of the company I am working for decided to switch
all development projects to J2EE architecture (OC4J).

  Within the year, we have running in many technical problems connected to
OC4J (stability hanging, java deadlocks, performance problems etc). We have
logged many (~10) long (100KB of text, 2-4 mount) TARs to Oracle support.
Generally there no many help from Oracle side. I have filling there no
strong competence from Oracle analyst’s side ;(

  We have learned a lot about OC4J architecture, parameters etc. during this
time (see information below). But at the moment I still have filling that we
are working in the dark, using black box method.

  I will try to explain that I mean, by comparing Oracle Database & Oracle
OC4J.
  There excellent documentation regarding Oracle Database architecture
(Oracle Concepts). There is good description about each Database process
PMON, SMON, etc, there is one process per connection (in dedicated
configuration), there is many diagnostic possibilities etc. If I have
performance issue with Oracle Database, first of all I will take a look on
TOP CPU consumers from OS respective, then I’ll go forward to Oracle
statistics or switching 10046 event etc.

  As opposite, take a look on OC4J. There is no any information like
mentioned above regarding OC4J, not in Oracle documentation, not in the Web
;(. There is just one process, which represent OC4J from OS. If there is
performance issue with OC4J, we can’t say a lot regarding which
process/activity/piece of code takes CPU etc.

  My question is:
  - Do you know any good information source about OC4J architecture; there
will be described internals (processes, communications flows etc);
  - Do you know good courses regarding this theme?
  - Information about any related book is welcomed?
  - Can you share you experience working on OC4J problems?

  Thank you in advance,
  Jurijs


  ===========================================================
  I would like to share information that we have regarding OC4J architecture
(see below).
  ============================================================

  I.
  Processes/Threads
  As I mentioned above OC4J from OS looks like one process, which consume HW
resources. OC4J use threads architecture for endow concurrency. You can see
threads dump in the Java output (in $OH opmn/logs/<component
name>.default_island.1 log file  by default) by running
  a)
  kill –3 <oc4j pid>
  command (this is any java process behavior, I believe).
  From dump we can see main threads list, as well as information about java
deadlocks if any.
  b) Below is thread types list you can see in the java output by running
kill –3 command:
  ===
  AJPConnectionListener [0.0.0.0/0.0.0.0:3001]
  ApplicationServerThread-0
  Finalizer
  JMSServer
  OC4JMonitorThread
  Reference Handler
  RMIServer [0.0.0.0/0.0.0.0:3101] count:2
  Signal Dispatcher
  Suspend Checker Thread
  TaskManager
  Thread
  VM Periodic Task Thread
  VM Thread
  ===
  Unfortunately I don’t have information about algorithms of work and what
is responsibility of each type of thread, at the moment.
  c) In addition there is garbage collector process.
  There is many information in the Web regarding this type of process.
  For example
  http://java.sun.com/docs/hotspot/gc1.4.2
  http://java.sun.com/docs/hotspot/gc1.4.2/faq.html
  http://www.cons.org/cmucl/doc/gc-tuning.html
  etc.
  -verbose:gc parameter usage is helpful in diagnostic process.

  II. The TOP parameters you need to look on is:
  a)
  File $OH/opmn/conf/opmn.xml
  numProcs="1"
  <java-option value="-Xms1024M -Xmx1024M "/>
  <log-file path="$OH//opmn/logs/ipm.log" level="3"/>
  <log-file path="$OH/opmn/logs/ons.log" level="3"/>
  b)
  File $OH/j2ee/<component name>/config/server.xml
  <global-thread-pool min="100" max="200" queue="120" keepAlive="600000"
cx-min="100" cx-max="200" cx-que ue="120" cx-keepAlive="600000" debug="true"
/>
  taskmanager-granularity="9000000"
  transaction-config timeout="500000"
  c)
  File $OH/j2ee/<component name>/config/oc4j.properties
  If you use BC4J.
  jbo.pers.max.active.nodes=1000
  jbo.pers.max.rows.per.node=1000
  jbo.doconnectionpooling=true
  jbo.initpoolsize=1
  jbo.maxpoolsize=550
  jbo.poolminavailablesize=0
  jbo.poolmaxavailablesize=600
  jbo.poolmonitorsleepinterval=600000
  jbo.poolmaxinactiveage=600000
  jbo.ampool.initpoolsize=1
  jbo.ampool.maxpoolsize=550
  jbo.ampool.minavailablesize=0
  jbo.ampool.maxavailablesize=100
  jbo.ampool.monitorsleepinterval=600000
  jbo.ampool.maxinactiveage=600000

  Hope this information will help you.

Other related posts: