<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>ora-solutions.net - Martin Decker &#187; 9iR2</title>
	<atom:link href="http://www.ora-solutions.net/web/category/oracle-database/9ir2/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ora-solutions.net/web</link>
	<description>Indepented Oracle consultant</description>
	<lastBuildDate>Wed, 14 Jul 2010 17:59:51 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=abc</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Out-of-Memory killer on 32bit Linux with big RAM</title>
		<link>http://www.ora-solutions.net/web/2009/08/25/out-of-memory-killer-on-32bit-linux-with-big-ram/</link>
		<comments>http://www.ora-solutions.net/web/2009/08/25/out-of-memory-killer-on-32bit-linux-with-big-ram/#comments</comments>
		<pubDate>Tue, 25 Aug 2009 13:27:30 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[10g]]></category>
		<category><![CDATA[11g]]></category>
		<category><![CDATA[9iR2]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Oracle Database]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=746</guid>
		<description><![CDATA[It is not very known that you can run into serious problems if you run Linux x86-32bit with a big amount of RAM installed, if using RHEL below 5. The official name for the issue is called &#8220;Low Memory Starvation&#8221;. The best solution is to use x86-64bit to be able to address the whole amount [...]]]></description>
			<content:encoded><![CDATA[<p>It is not very known that you can run into serious problems if you run Linux x86-32bit with a big amount of RAM installed, if using RHEL below 5. The official name for the issue is called &#8220;Low Memory Starvation&#8221;. The best solution is to use x86-64bit to be able to address the whole amount of RAM efficiently. </p>
<p>However, if that is not feasible, then make sure that you at least run the hugemem kernel if you use RHEL < 5. In RHEL5-32bit, the hugemem kernel is default.</p>
<p>A quick demonstration about what can happen if you don´t use hugemem kernel is shown here:</p>
<p>We realized that RMAN backup is taking more than 24 hours. Querying v$session, we find out that<br />
one session is in ACTION "STARTED", whereas the other sessions are FINISHED.</p>
<blockquote><pre>SQL> select program, module,action
      from v$session
      where username = 'SYS' and program like 'rman%'
/      

PROGRAM                    MODULE                       ACTION
-------------------------- ---------------------------  -------------------
rman@ora-vm1 (TNS V1-V3)    backup full datafile        0000078 FINISHED129
rman@ora-vm1 (TNS V1-V3)    backup full datafile        0000272 STARTED16
rman@ora-vm1 (TNS V1-V3)    backup full datafile        0000084 FINISHED129
rman@ora-vm1 (TNS V1-V3)    rman@ora-vm1 (TNS V1-V3)
rman@ora-vm1 (TNS V1-V3)    rman@ora-vm1 (TNS V1-V3)    0000004 FINISHED131
rman@ora-vm1 (TNS V1-V3)    backup full datafile        0000092 FINISHED129</pre>
</blockquote>
<p>Then we check the SID,serial# from v$session of this session and also query the UNIX PID from v$process.spid</p>
<blockquote><pre>SQL> select sid,serial# from v$session where event like 'RMAN%';

       SID    SERIAL#
---------- ----------
      4343       5837</pre>
</blockquote>
<p>We activate SQL Tracing for this session to determine its activity:      </p>
<blockquote><pre>SQL> select spid from v$process where addr =
   (select paddr from v$session where sid = 4343);

SPID
------------
1681

SQL> begin dbms_monitor.session_trace_enable(4343,5837,true,true);
  2  end;
  3  /</pre>
</blockquote>
<p>However, no trace file gets created. Then we start tracing system calls with strace:</p>
<blockquote><pre>ora-vm1:# strace -fp 1681
attach: ptrace(PTRACE_ATTACH, ...): Operation not permitted</pre>
</blockquote>
<p>&#8220;Not permitted&#8221;? &#8211; Although I am connected as root?</p>
<blockquote><pre>ps -ef|grep 1681
oracle    1681 1582  0 Aug24 ?        00:00:09 [oracle] &lt;defunct&gt;</pre>
</blockquote>
<p>The linux command &#8220;ps&#8221; reports the server process as &#8220;defunct&#8221;. </p>
<blockquote><pre>ora-vm1:/usr/oracle/admin/labo/udump$ ps -ef|grep 1582
oracle   1582 21578  0 Aug24 ?        00:00:02 rman oracle/product/10.2.0/bin/rman nocatalog
oracle   21663 1582  0 Aug24 ?        00:00:01 oraclelabo (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
oracle   21665 1582  0 Aug24 ?        00:00:03 oraclelabo (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
oracle   1681 1582   0 Aug24 ?        00:00:09 [oracle] &lt;defunct&gt;
oracle   21691 1582  0 Aug24 ?        00:01:36 oraclelabo (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
oracle   21695 1582  0 Aug24 ?        00:01:41 oraclelabo (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
oracle   21793 1582  0 Aug24 ?        00:01:30 oraclelabo (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))</pre>
</blockquote>
<p>Next, I checked logfile /var/log/messages.1 and realized that the kernel out-of-memory killer (OOM) killed this PID because of low memory starvation.</p>
<blockquote><pre>/var/log/messages.1:
Aug  24 22:32:44 ora-vm1 kernel: Out of Memory: Killed process 1681 (oracle).</pre>
</blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2009/08/25/out-of-memory-killer-on-32bit-linux-with-big-ram/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Hugepages revisited II: Be aware of kernel bugs!</title>
		<link>http://www.ora-solutions.net/web/2009/01/07/hugepages-revisited-ii-be-aware-of-kernel-bugs/</link>
		<comments>http://www.ora-solutions.net/web/2009/01/07/hugepages-revisited-ii-be-aware-of-kernel-bugs/#comments</comments>
		<pubDate>Wed, 07 Jan 2009 11:31:08 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[10g]]></category>
		<category><![CDATA[11g]]></category>
		<category><![CDATA[9iR2]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Linux Itanium]]></category>
		<category><![CDATA[Oracle Database]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=547</guid>
		<description><![CDATA[It is well known that hugepages can reduce the overhead of managing memory pages of Oracle SGA by the operating system thus leading to lower system cpu utilization. I have written two blog entries regarding this topic already: Listener Coredumps on heavy load system  and Hugepages revisited.
However, there is a potential risk with it: [...]]]></description>
			<content:encoded><![CDATA[<p>It is well known that hugepages can reduce the overhead of managing memory pages of Oracle SGA by the operating system thus <a href="http://www.pythian.com/blogs/1326/performance-tuning-hugepages-in-linux/">leading to lower system cpu utilization.</a> I have written two blog entries regarding this topic already: <a href="http://www.ora-solutions.net/web/2008/11/10/listener-coredumps-on-heavy-load-system/">Listener Coredumps on heavy load system </a> and <a href="http://www.ora-solutions.net/web/2008/11/30/hugepages-revisited/">Hugepages revisited.</a></p>
<p>However, there is a potential risk with it: Certain kernels / platforms have bugs regarding hugepages which can lead to problems:</p>
<ul>
<li><a href="https://bugzilla.redhat.com/show_bug.cgi?id=131295">Bug 131295</a> &#8211; Hugepages configured on kernel boot line causes x86_64 kernel boot to fail with OOM: Fixed in RHEL3: kernel-2.4.21-40.EL</li>
</ul>
<ul>
<li><a href="http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=248954">Bug 248954</a> &#8211; Oracle ASM DBWR process goes into 100% CPU spin when using hugepages on ia64 (Fixed in kernel-2.6.9-78.EL.ia64.rpm available as update for RHEL4U7)</li>
</ul>
<ul>
<li><a href="http://rhn.redhat.com/errata/RHSA-2008-1017.html">RHSA-2008:1017-14</a>: on the Itanium® architecture, setting the &#8220;vm.nr_hugepages&#8221; sysctl parameter caused a kernel stack overflow resulting in a kernel panic, and possibly stack corruption. With this fix, setting vm.nr_hugepages works correctly. Fixed with RHEL5 kernel-2.6.18-92.1.22.el5.ia64.rpm</li>
</ul>
<ul>
<li><a href="http://rhn.redhat.com/errata/RHSA-2008-1017.html">RHSA-2008:1017-14</a>: hugepages allow the Linux kernel to utilize the multiple page size capabilities of modern hardware architectures. In certain configurations, systems with large amounts of memory could fail to allocate most of this memory for hugepages even if it was free. This could result, for example, in database restart failures. Fixed with RHEL5 kernel-2.6.18-92.1.22.el5.ia64.rpm</li>
</ul>
<p>Therefore, before enabling hugepages, I recommend to check with your OS Vendor Bug Database, test on a test system and apply recent OS upgrades first.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2009/01/07/hugepages-revisited-ii-be-aware-of-kernel-bugs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installation Prerequisites for Oracle Databases</title>
		<link>http://www.ora-solutions.net/web/2008/12/23/installation-prerequisites-for-oracle-databases/</link>
		<comments>http://www.ora-solutions.net/web/2008/12/23/installation-prerequisites-for-oracle-databases/#comments</comments>
		<pubDate>Tue, 23 Dec 2008 14:51:21 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[10g]]></category>
		<category><![CDATA[11g]]></category>
		<category><![CDATA[9iR2]]></category>
		<category><![CDATA[Oracle Database]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=527</guid>
		<description><![CDATA[More often than not, I see installations, where either shared memory parameters or ulimit settings are not set as required for an optimal Oracle database installation.
The tool RDA, commonly known as a support tool to gather diagnostic information for Oracle Support for service requests, can do these checks quite nicely.
Steps:

Download RDA from MetaLink Note 314422.1.
unzip [...]]]></description>
			<content:encoded><![CDATA[<p>More often than not, I see installations, where either shared memory parameters or ulimit settings are not set as required for an optimal Oracle database installation.</p>
<p>The tool RDA, commonly known as a support tool to gather diagnostic information for Oracle Support for service requests, can do these checks quite nicely.</p>
<p><strong>Steps:</strong></p>
<ul>
<li>Download RDA from MetaLink Note <span style="font-family: helvetica;"><strong>314422.1.</strong></span></li>
<li>unzip in working directory</li>
<li>run <strong>H</strong>ealth <strong>C</strong>heck <strong>V</strong>alidation <strong>E</strong>ngine of RDA
</li>
<blockquote><p><code>$ ./rda.pl -T hcve<br />
Processing HCVE tests ...<br />
Available Pre-Installation Rule Sets:<br />
   1. Oracle Database 10g (10.1.0) PreInstall(HP-UX)<br />
   2. Oracle Database 10g R1 (10.1.0) PreInstall (HP-UX Itanium)<br />
   3. Oracle Database 10g R2 (10.2.0) PreInstall (HPUX)<br />
   4. Oracle Database 11g R1 (11.1.0) PreInstall (HPUX)<br />
   5. Oracle Application Server 10g (9.0.4) PreInstall (HP-UX)<br />
   6. Oracle Application Server 10g R2 (10.1.2) PreInstall (HP-UX)<br />
   7. Oracle Portal PreInstall (Generic)<br />
Available Post-Installation Rule Sets:<br />
   8. Oracle Portal PostInstall (generic)<br />
   9. Data Guard PostInstall (Generic)<br />
Enter the HCVE rule set number<br />
Hit 'Return' to accept the default (1)<br />
> 3</p>
<p>Enter value for < Planned ORACLE_HOME location or if set ><br />
Hit 'Return' to accept the default ($ORACLE_HOME)<br />
></p>
<p>Test "Oracle Database 10g R2 (10.2.0) PreInstall (HPUX)" executed at Tue Dec 23 15:26:31 2008</p>
<p>Test Results<br />
~~~~~~~~~~~~</p>
<p>   ID NAME                 RESULT VALUE<br />
===== ==================== ====== ========================================<br />
   10 OS Certified?        PASSED Certified with 10g R2 RDBMS<br />
   20 User in /etc/passwd? PASSED userOK<br />
   25 Got EXTJOB User?     FAILED ExtjobNotFound<br />
   30 Group in /etc/group? PASSED GroupOK<br />
   40 Input ORACLE_HOME    RECORD $ORACLE_HOME<br />
   50 ORACLE_HOME Valid?   PASSED OHexists<br />
   60 O_H Permissions OK?  PASSED CorrectPerms<br />
   70 Umask Set to 022?    PASSED UmaskOK<br />
   80 LDLIBRARYPATH Unset? PASSED UnSet<br />
   90 SHLIB_PATH Unset?    PASSED UnSet<br />
  100 Other O_Hs in PATH?  PASSED NotFound<br />
  110 oraInventory Permiss FAILED oraInventoryNotOK<br />
  120 /tmp Adequate?       PASSED TempSpaceOK<br />
  130 Swap (in MB)         RECORD 15144<br />
  140 RAM (in MB)          PASSED 14334<br />
  150 SwapToRAM OK?        PASSED SwapToRAMOK<br />
  160 Disk Space OK?       FAILED OnlySpaceForOne<br />
  170 Kernel Parameters OK FAILED [EXECUTABLE_STACK=1] too large [MAXUP..><br />
  175 Links and Libs OK?   PASSED AllExist<br />
  180 Got ld,nm,ar,make?   PASSED ld_nm_ar_make_found<br />
  190 ulimits OK?          PASSED ulimitOK<br />
  200 Got OS Bundles?      PASSED GOLDAPPS11iandGOLDBASE11iAdequate<br />
  210 Got OS Patches?      FAILED [PHNE_31097 or its successor PHNE_324..><br />
  220 Other OUI Up?        PASSED NoOtherOUI<br />
</code></p></blockquote>
<p>The output file contains detailed information, about why a specific check failed.</p>
<blockquote><p><code>[PHNE_31097 or its successor PHNE_32477 or its successor PHNE_33498 or its successor PHNE_35418] not installed<br />
[PHSS_31221 or its successor PHSS_33263 or its successor PHSS_33944] not installed<br />
[PHSS_30970 or its successor PHSS_33033 or its successor PHSS_35379] not installed<br />
[PHSS_32508 or its successor PHSS_34411 or its successor PHSS_35099] not installed<br />
[PHSS_32509 or its successor PHSS_34412 or its successor PHSS_35098] not installed<br />
[PHSS_32510 or its successor PHSS_34413 or its successor PHSS_35100] not installed</p>
<p>FAILED<br />
[EXECUTABLE_STACK=1] too large<br />
[MAXUPRC=1024] too small<br />
[MSGMNI=50] too small<br />
[MSGTQL=40] too small<br />
[NCSIZE=9964] too small<br />
[NFILE=5000] too small<br />
[NINODE=4844] too small<br />
[SHMMAX=1024000000] too small<br />
[MAXSWAPCHUNKS=2048] too small<br />
[MSGMAP=42] too small == KernelOK<br />
</code> </p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2008/12/23/installation-prerequisites-for-oracle-databases/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing LTOM for RAC Hanganalyze</title>
		<link>http://www.ora-solutions.net/web/2008/12/17/installing-ltom-for-rac-hanganalyze/</link>
		<comments>http://www.ora-solutions.net/web/2008/12/17/installing-ltom-for-rac-hanganalyze/#comments</comments>
		<pubDate>Wed, 17 Dec 2008 12:40:35 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[10g]]></category>
		<category><![CDATA[11g]]></category>
		<category><![CDATA[9iR2]]></category>
		<category><![CDATA[MetaLink]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Real Application Clusters]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=496</guid>
		<description><![CDATA[I have recently written a short installation instruction for a customer to use LTOM for RAC hanganalyze.

Download von MetaLink Note 352363.1:
https://metalink2.oracle.com/cgi-bin/cr/getfile.cgi?p_attid=352363.1:ltom


unzip as User Oracle in directory with sufficient space. subdir ltom will be created

tar xfv ltom411.tar

Install statspack


Installation: db account ltom/ltom will be created

Java Binary in path
which java
if not, place java in path in ~/.bash_profile:
als User [...]]]></description>
			<content:encoded><![CDATA[<p>I have recently written a short installation instruction for a customer to use LTOM for RAC hanganalyze.</p>
<ul>
<li>Download von MetaLink Note 352363.1:<br />
https://metalink2.oracle.com/cgi-bin/cr/getfile.cgi?p_attid=352363.1:ltom</li>
</ul>
<ul>
<li>unzip as User Oracle in directory with sufficient space. subdir ltom will be created</li>
</ul>
<blockquote><p>tar xfv ltom411.tar</p></blockquote>
<ul>
<li>Install statspack</li>
</ul>
<ul>
<li>Installation: db account ltom/ltom will be created</li>
</ul>
<blockquote><p>Java Binary in path<br />
which java</p>
<p>if not, place java in path in ~/.bash_profile:<br />
als User oracle: add $ORACLE_HOME/jre/1.4.2/bin to PATH Variable</p>
<p>e.g.:<br />
export PATH=$PATH:$ORACLE_HOME/bin:$ORACLE_HOME/jre/1.4.2/bin</p>
<p>Put TOM_HOME in .~/.bash_profile:<br />
export TOM_HOME=/home/oracle/ltom/tom_base/install/../tom</p>
<p>Sourcen of TOM_HOME</p>
<p>cd /home/oracle/ltom/tom_base/install<br />
./autoinstall.sh</p>
<p>Sample Output:<br />
[oracle@ora-vm1 install]$ ./autoinstall.sh<br />
TOM_HOME=/home/oracle/ltom/tom_base/install/../tom<br />
rm: cannot remove `autoinstall.log&#8217;: No such file or directory</p>
<p>Preparing to install LTOM v4.0.0&#8230;</p>
<p>Checking your Oracle Environment&#8230;</p>
<p>ORACLE_HOME=/u01/app/oracle/product/10.2.0<br />
ORACLE_SID=ORA102<br />
TNS_ADMIN=<br />
TOM_HOME=/home/oracle/ltom/tom_base/install/../tom</p>
<p>Is this the correct Oracle environment you wish to use for installing LTOM?<br />
Hit Return to Accept Default:<br />
============================&gt; \c</p>
<p>Continuing the install with this environment</p>
<p>Checking for Java&#8230;</p>
<p>Java found.</p>
<p>Checking for top utility&#8230;<br />
Found top utility.</p>
<p>Checking for vmstat utility&#8230;<br />
Found vmstat utility.</p>
<p>Need to run some sql now to create TOM user<br />
it Return to allow setup to do this for you, enter other to do this manually:<br />
============================&gt; \c</p>
<p>Tom user created successfully.<br />
Warning&#8230;Please change tom password immediately!</p>
<p>Grant user Tom successful.<br />
Create package dbmssupp successful.<br />
Grant execute on dbmssupp successful.</p>
<p>Checking for statspack&#8230;</p>
<p>Cannot verify statspack is installed on your system.<br />
LTOM requires statspack to be installed to work properly.</p>
<p>Enter your email id to get notification of hangs via email&#8230;<br />
Hit Return to ignore hang notification via email:<br />
============================&gt; \c</p>
<p>Configuring tom_deploy.properties file&#8230;</p>
<p>TOM/LTOM successfully installed.</p>
<p>Please review any messages you received above.</p>
<p>REMEMBER: You must have TOM_HOME defined and java in your PATH<br />
before you can run TOM/LTOM.</p></blockquote>
<ul>
<li>Configuration</li>
</ul>
<blockquote><p>Change ltom/tom_base/tom/init/hangDetect.properties</p>
<p>from:<br />
#RAC_AWARE=TRUE<br />
HANGANALYZE=A<br />
SYSTEMSTATE=266<br />
DELAY=30<br />
HANGANALYZE=A<br />
SYSTEMSTATE=266</p>
<p>to:<br />
RAW_AWARE=TRUE<br />
HANGANALYZE=A<br />
SYSTEMSTATE=266<br />
DELAY=30<br />
HANGANALYZE=A<br />
SYSTEMSTATE=266</p>
<p>Change tom db passwort:</p>
<p>SQL&gt; alter user tom identified by secret;</p>
<p>Add credentials to config file:</p>
<p>vi tom_deploy.properties</p>
<p>DB_USERID=tom<br />
:q!</p>
<p>./startltom.sh -p<br />
Enter same password as in sqlplus. Password will be saved encrypted in tom_deploy.properties</p></blockquote>
<ul>
<li>edit tom_deploy.properties to decide which of the 3 modules should be running during background operations: hangdetect, profiler, session recorder</li>
</ul>
<ul>
<li>Start/Stop Scripts</li>
</ul>
<blockquote><p>vi start_ltom.sh<br />
#!/bin/bash<br />
. ~/.bash_profile<br />
nohup $TOM_HOME/startltom.sh -s &amp;</p>
<p>vi stop_ltom.sh<br />
#!/bin/bash<br />
touch $TOM_HOME/tmp/hang.stop<br />
touch $TOM_HOME/tmp/profile.stop<br />
touch $TOM_HOME/tmp/session.stop</p>
<p>chmod u+x start_ltom.sh<br />
chmod u+x stop_ltom.sh</p></blockquote>
<ul>
<li>If you want  to run ltom during a specific timeframe, use cron (as user oracle)</li>
</ul>
<blockquote><p>crontab -e<br />
45 01 * * *     /home/oracle/ltom/start_ltom.sh &gt;/dev/null 2&gt;/dev/null &lt;/dev/null<br />
00 05 * * *     /home/oracle/ltom/start_ltom.sh &gt;/dev/null 2&gt;/dev/null &lt;/dev/null</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2008/12/17/installing-ltom-for-rac-hanganalyze/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Troublshooting Trace Files of DIAG Background Process</title>
		<link>http://www.ora-solutions.net/web/2008/12/10/troublshooting-trace-files-of-diag-background-process/</link>
		<comments>http://www.ora-solutions.net/web/2008/12/10/troublshooting-trace-files-of-diag-background-process/#comments</comments>
		<pubDate>Wed, 10 Dec 2008 16:25:18 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[10g]]></category>
		<category><![CDATA[11g]]></category>
		<category><![CDATA[9iR2]]></category>
		<category><![CDATA[MetaLink]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Real Application Clusters]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=481</guid>
		<description><![CDATA[In trace files of the background process DIAG, I saw an interesting section that I would like to share.

*** 2008-12-09 03:46:33.280
Dump requested by process [orapid=6]
REQUEST:custom dump [2] with parameters [6][27][4][2]
Dumping process info of pid[27.31384] requested by pid[6.31160]
ORA-00494: Message 494 not found; No message file for product=RDBMS, facility=ORA; arguments: [ [CF]] [ (more than 900 seconds)] [...]]]></description>
			<content:encoded><![CDATA[<p>In trace files of the background process DIAG, I saw an interesting section that I would like to share.</p>
<blockquote><p><code><br />
*** 2008-12-09 03:46:33.280<br />
Dump requested by process [orapid=6]<br />
REQUEST:custom dump [2] with parameters [6][27][4][2]<br />
Dumping process info of pid[27.31384] requested by pid[6.31160]<br />
ORA-00494: Message 494 not found; No message file for product=RDBMS, facility=ORA; arguments: [ [CF]] [ (more than 900 seconds)] [inst<br />
2, osid 31384]<br />
-------------------------------------------------------------------------------<br />
ENQUEUE [CF] HELD FOR TOO LONG<br />
enqueue holder: 'inst 2, osid 31384'<br />
Process 'inst 2, osid 31384' is holding an enqueue for maximum allowed time.<br />
The process will be terminated.<br />
Oracle Support Services triaging information: to find the root-cause, look<br />
at the call stack of process 'inst 2, osid 31384' located below. Ask the<br />
developer that owns the first NON-service layer in the stack to investigate.<br />
Common service layers are enqueues (ksq), latches (ksl), library cache<br />
pins and locks (kgl), and row cache locks (kqr).<br />
</code></p></blockquote>
<p>It is very nice of diag to tell me what to do with the output. <img src='http://www.ora-solutions.net/web/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' />   Especially:</p>
<blockquote><p>Ask the developer that owns the first NON-service layer in the stack to investigate.</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2008/12/10/troublshooting-trace-files-of-diag-background-process/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>System State Dump Evaluation with ass.awk</title>
		<link>http://www.ora-solutions.net/web/2008/12/10/system-state-dump-evaluation-with-assawk/</link>
		<comments>http://www.ora-solutions.net/web/2008/12/10/system-state-dump-evaluation-with-assawk/#comments</comments>
		<pubDate>Wed, 10 Dec 2008 16:21:31 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[10g]]></category>
		<category><![CDATA[11g]]></category>
		<category><![CDATA[9iR2]]></category>
		<category><![CDATA[MetaLink]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Real Application Clusters]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=473</guid>
		<description><![CDATA[I have found out that there is an Oracle Support utility called ass.awk, which can be used to analyze and format a System State dump. It is contained in LTOM, which can be downloaded from MetaLink.
The AWK script is called ass109.awk and can be used in this manner:
[oracle@ora-vm1 ~]$ awk -f ass109.awk mddb1_diag_12345.trc
System State ASS:
Starting [...]]]></description>
			<content:encoded><![CDATA[<p>I have found out that there is an Oracle Support utility called ass.awk, which can be used to analyze and format a System State dump. It is contained in LTOM, which can be downloaded from MetaLink.</p>
<p>The AWK script is called ass109.awk and can be used in this manner:</p>
<blockquote><p><code>[oracle@ora-vm1 ~]$ awk -f ass109.awk mddb1_diag_12345.trc</p>
<p>System State ASS:<br />
Starting Systemstate 1<br />
..............................................................................<br />
.....<br />
Ass.Awk Version 1.0.9 - Processing mddb1_diag_12345.trc<br />
System State 1<br />
~~~~~~~~~~~~~~~~<br />
1:<br />
2: waiting for 'pmon timer' wait<br />
3: last wait for 'ksdxexeotherwait'<br />
4: waiting for 'rdbms ipc message' wait<br />
5: waiting for 'rdbms ipc message' wait<br />
6: waiting for 'ges remote message' wait<br />
7: waiting for 'gcs log flush sync' wait<br />
8: waiting for 'gcs log flush sync' wait<br />
9: waiting for 'rdbms ipc message' wait<br />
10: waiting for 'rdbms ipc message' wait<br />
11: waiting for 'enq: CF - contention' [Enqueue CF-00000000-00000000] wait<br />
12: waiting for 'rdbms ipc message' wait<br />
13: waiting for 'buffer busy waits' (2,a9,3b) wait<br />
14: waiting for 'rdbms ipc message' wait<br />
15: waiting for 'rdbms ipc message' wait<br />
16: waiting for 'buffer busy waits' (2,a9,3b) wait<br />
17: waiting for 'rdbms ipc message' wait<br />
18:<br />
19:<br />
20: waiting for 'rdbms ipc message' wait<br />
21: waiting for 'log file sync' wait<br />
22: waiting for 'ASM background timer' wait<br />
23: waiting for 'rdbms ipc message' wait<br />
24: waiting for 'log file sync' wait<br />
25: waiting for 'class slave wait' wait<br />
26: waiting for 'SQL*Net message from client' wait<br />
27: waiting for 'SQL*Net message from client' wait<br />
28: waiting for 'enq: CF - contention' [Enqueue CF-00000000-00000000] wait<br />
29: waiting for 'enq: CF - contention' [Enqueue CF-00000000-00000000] wait<br />
30: waiting for 'Streams AQ: qmn coordinator idle wait' wait<br />
31: waiting for 'SQL*Net message from client' wait<br />
32: waiting for 'SQL*Net message from client' wait<br />
Cmd: Select<br />
33: waiting for 'log file sync' wait<br />
34: waiting for 'Streams AQ: qmn slave idle wait' wait<br />
35: for 'Streams AQ: waiting for time management or cleanup tasks' wait<br />
36: waiting for 'log file sync' wait<br />
37: waiting for 'SQL*Net message from client' wait<br />
Cmd: Select<br />
38: waiting for 'SQL*Net message from client' wait<br />
39: waiting for 'SQL*Net message from client' wait<br />
40: waiting for 'PX Deq: Execution Msg' wait<br />
41: waiting for 'log file sync' wait<br />
42: waiting for 'log file sync' wait<br />
43: waiting for 'enq: CF - contention' [Enqueue CF-00000000-00000000] wait<br />
Cmd: Select<br />
44: waiting for 'SQL*Net message from client' wait<br />
45: waiting for 'SQL*Net message from client' wait<br />
46: waiting for 'SQL*Net message from client' wait<br />
47: waiting for 'SQL*Net message from client' wait<br />
48: waiting for 'SQL*Net message from client' wait<br />
49: waiting for 'log file sync' wait<br />
50: waiting for 'SQL*Net message from client' wait<br />
51: waiting for 'SQL*Net message from client' wait<br />
Cmd: Select<br />
52: waiting for 'row cache lock' [Rcache object=0xa5414098,] wait<br />
Cmd: Select<br />
53: waiting for 'SQL*Net message from client' wait<br />
54: waiting for 'SQL*Net message from client' wait<br />
55: for 'Streams AQ: waiting for messages in the queue' wait<br />
56: waiting for 'SQL*Net message from client' wait<br />
57: waiting for 'SQL*Net message from client' wait<br />
58: waiting for 'log file sync' wait<br />
Cmd: Insert<br />
59: waiting for 'jobq slave wait' wait<br />
60: waiting for 'jobq slave wait' wait<br />
61: waiting for 'SQL*Net message from client' wait<br />
62: waiting for 'SQL*Net message from client' wait<br />
63: waiting for 'SQL*Net message from client' wait<br />
65: waiting for 'SQL*Net message from client' wait<br />
Cmd: Select<br />
66: waiting for 'SQL*Net message from client' wait<br />
67: last wait for 'SQL*Net message from client'<br />
68: waiting for 'SQL*Net message from client' wait<br />
69: waiting for 'SQL*Net message from client' wait<br />
70: waiting for 'SQL*Net message from client' wait<br />
71: waiting for 'SQL*Net message from client' wait<br />
72: waiting for 'SQL*Net message from client' wait<br />
73: waiting for 'SQL*Net message from client' wait<br />
74: waiting for 'SQL*Net message from client' wait<br />
Cmd: Select<br />
75: waiting for 'SQL*Net message from client' wait<br />
Cmd: Select<br />
76: waiting for 'SQL*Net message from client' wait<br />
77: waiting for 'log file sync' wait<br />
78: waiting for 'SQL*Net message from client' wait<br />
80: waiting for 'SQL*Net message from client' wait<br />
Cmd: Select<br />
82: waiting for 'SQL*Net message from client' wait<br />
84: waiting for 'log file sync' wait<br />
86: waiting for 'SQL*Net message from client' wait<br />
93: waiting for 'SQL*Net message from client' wait<br />
94: waiting for 'SQL*Net message from client' wait<br />
Blockers<br />
~~~~~~~~<br />
Above is a list of all the processes. If they are waiting for a resource<br />
then it will be given in square brackets. Below is a summary of the<br />
waited upon resources, together with the holder of that resource.<br />
Notes:<br />
~~~~~<br />
o A process id of '???' implies that the holder was not found in the<br />
systemstate.<br />
Resource Holder State<br />
Enqueue CF-00000000-00000000 12: waiting for 'rdbms ipc message'<br />
Rcache object=0xa5414098, ??? Blocker<br />
Object Names<br />
~~~~~~~~~~~~<br />
Enqueue CF-00000000-00000000<br />
Rcache object=0xa5414098,</code></p></blockquote>
<p>With this information, you can investigate further into the System state dump by looking at rcache object 0xa5414098. The &#8220;State Objects&#8221; are a hierarchical structure. Every state object has an adress &#8220;SO: 0xa6a5955c&#8221; and an owner, which is the parent entry. In this case, you can construct a hierarchical tree of state objects and find dependencies. </p>
<blockquote><p><code> SO: 0xa6a5995c, type: 2, owner: (nil), flag: INIT/-/-/0x00<br />
 (process) Oracle pid=52, calls cur/top: 0x9d62eb1c/0x9d5ccfcc, flag: (0) -<br />
		   int error: 0, call error: 0, sess error: 0, txn error 0<br />
 (post info) last post received: 0 0 163<br />
			 last post received-location: kqrbtm<br />
			 last process to post me: a6a4e1dc 1 6<br />
			 last post sent: 0 0 24<br />
			 last post sent-location: ksasnd<br />
			 last process posted by me: a6a4e1dc 1 6<br />
   (latch info) wait_event=0 bits=0<br />
	Process Group: DEFAULT, pseudo proc: 0xa6baf79c<br />
	O/S info: user: oracle, term: UNKNOWN, ospid: 29032<br />
    OSD pid info: Unix process pid: 29032, image: oracle@ora-vm1<br />
    Short stack dump: ksdxfstk()+19<-ksdxcb()+1321<-sspuser()+102<-__kernel_vsyscall()+16</p>
<p>    SO: 0xa4123d20, type: 4, owner: 0xa6a5995c, flag: INIT/-/-/0x00<br />
    (session) sid: 955 trans: (nil), creator: 0xa6a5995c, flag: (41) USR/- BSY/-/-/-/-/-<br />
              DID: 0001-0034-00002227, short-term DID: 0001-0034-00002228<br />
              txn branch: (nil)<br />
              oct: 3, prv: 0, sql: 0x8fee9d44, psql: 0x8fee9f00, user: 23/DBSNMP<br />
     service name: SYS$USERS<br />
     O/S info: user: oracle, term: , ospid: 28849, machine: ora-vm1<br />
               program: emagent@ora-vm1(TNS V1-V3)<br />
     application name: emagent@ora-vm1(TNS V1-V3), hash value=2420928497<br />
     waiting for 'row cache lock' blocking sess=0x(nil) seq=127 wait_time=0 seconds since wait started=0<br />
                 cache id=d, mode=0, request=5<br />
     Dumping Session Wait History<br />
      for 'row cache lock' count=1 wait_time=1337230<br />
		         cache id=d, mode=0, request=5<br />
      for 'row cache lock' count=1 wait_time=2930561<br />
                 cache id=d, mode=0, request=5<br />
      for 'row cache lock' count=1 wait_time=2929106<br />
                 cache id=d, mode=0, request=5<br />
      for 'row cache lock' count=1 wait_time=2933326</p>
<p>      SO: 0x9d5ccfcc, type: 3, owner: 0xa6a5995c, flag: INIT/-/-/0x00<br />
     (call) sess: cur a4123d20, rec a4123d20, usr a4123d20; depth: 0<br />
       ----------------------------------------<br />
       SO: 0x9d51b1a0, type: 3, owner: 0x9d5ccfcc, flag: INIT/-/-/0x00<br />
       (call) sess: cur a4123d20, rec a417f990, usr a4123d20; depth: 1<br />
         ----------------------------------------<br />
         SO: 0x9d69d7f0, type: 3, owner: 0x9d51b1a0, flag: INIT/-/-/0x00<br />
         (call) sess: cur a417f990, rec a417f990, usr a4123d20; depth: 2<br />
         ----------------------------------------<br />
           SO: 0x9d5e547c, type: 3, owner: 0x9d69d7f0, flag: INIT/-/-/0x00<br />
           (call) sess: cur a417f990, rec a417f990, usr a4123d20; depth: 3<br />
           ----------------------------------------<br />
             SO: 0x9d62eb1c, type: 3, owner: 0x9d5e547c, flag: INIT/-/-/0x00<br />
             (call) sess: cur a417f990, rec a417f990, usr a4123d20; depth: 4<br />
             ----------------------------------------<br />
               SO: 0x9fedf748, type: 40, owner: 0x9d62eb1c, flag: INIT/-/-/0x00<br />
               (trans) flg = 0x21, flg2 = 0x80000, prx = 0x0, ros = 2147483647 bsn = 0x395 bndsn = 0x395 spn = 0x395<br />
               efd = 34<br />
               parent xid: 0x0000.000.00000000<br />
               env: (scn: 0x0000.00000000 xid: 0x0000.000.00000000 uba: 0x00000000.0000.00 statement num=0 parent xid: xid:<br />
               0x0000.000.00000000 scn: 0x0000.00000000 0sch: scn: 0x0000.00000000)<br />
               cev: (spc = 0 arsp = 0 ubk tsn: 0 rdba: 0x00000000 useg tsn: 0 rdba: 0x00000000<br />
                     hwm uba: 0x00000000.0000.00 col uba: 0x00000000.0000.00<br />
                     num bl: 0 bk list: 0x0)<br />
                     cr opc: 0x0 spc: 0 uba: 0x00000000.0000.00<br />
               (enqueue) TX-00010011-00D3B4CF DID: 0001-0051-00001323<br />
               lv: 7c ac ad 4d 03 00 00 00 00 00 00 00 00 00 00 00 res_flag: 0x45<br />
               res: 0xa447bb2c, lock_flag: 0x0<br />
               own: 0xa4157e90, sess: 0xa4157e90, prv: 0x9fedf774<br />
               slk: (nil)<br />
                xga: 0x0, heap: UGA<br />
               Trans IMU st: 0 Pool index 65535, Redo pool 0x9fedfb74, Undo pool 0x9fedfbf0<br />
               Redo pool range [0x40ed57e8 0x40ed57e8 0x40ed7fe8]<br />
               Undo pool range [0x40ed2fe8 0x40ed2fe8 0x40ed57e8]<br />
               ----------------------------------------<br />
                  SO: 0x9d42237c, type: 50, owner: 0x9fedf748, flag: INIT/-/-/0x00<br />
                  row cache enqueue: count=1 session=0xa4123d20 object=0xa5414098, request=X<br />
                  savepoint=0x395<br />
                  row cache parent object: address=0xa5414098 cid=13(dc_sequences)<br />
                  hash=9649e7e typ=9 transaction=(nil) flags=00000000<br />
                  own=0xa5414104[0xa5414104,0xa5414104] wat=0xa541410c[0x9d422398,0x9d422398] mode=N<br />
                  status=-/-/-/-/-/-/-/-/-<br />
                  request=X release=FALSE flags=2<br />
                  instance lock id=QN 010cdbb3 b3b24847</code></p></blockquote>
<p>Tanel Poder showed in his seminar to use "grep -A 3 SO:" to find all lines containing the State Object Adresses and the following 3 lines to get the tree.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2008/12/10/system-state-dump-evaluation-with-assawk/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SQL Profiler TVD$XTAT update available</title>
		<link>http://www.ora-solutions.net/web/2008/11/27/sql-profiler-tvdxtat-available/</link>
		<comments>http://www.ora-solutions.net/web/2008/11/27/sql-profiler-tvdxtat-available/#comments</comments>
		<pubDate>Thu, 27 Nov 2008 19:21:22 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[10g]]></category>
		<category><![CDATA[11g]]></category>
		<category><![CDATA[9iR2]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Performance Tuning]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=389</guid>
		<description><![CDATA[I just saw that Christian Antognini has released an update of TVD$XTAT.  I am looking forward to experimenting with it. If you used tkprof in the past, you should definitely take a look at this tool.
]]></description>
			<content:encoded><![CDATA[<p>I just saw that Christian Antognini has released an update of <a href="http://antognini.ch/2008/11/tvdxtat-40-beta-8/">TVD$XTAT</a>.  I am looking forward to experimenting with it. If you used tkprof in the past, you should definitely take a look at this tool.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2008/11/27/sql-profiler-tvdxtat-available/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Formatted SQL Plan Display in Oracle 9i</title>
		<link>http://www.ora-solutions.net/web/2008/10/19/formatted-sql-plan-display-in-oracle-9i/</link>
		<comments>http://www.ora-solutions.net/web/2008/10/19/formatted-sql-plan-display-in-oracle-9i/#comments</comments>
		<pubDate>Sun, 19 Oct 2008 14:34:24 +0000</pubDate>
		<dc:creator>Martin</dc:creator>
				<category><![CDATA[9iR2]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://www.ora-solutions.net/web/?p=366</guid>
		<description><![CDATA[Tom Kyte has posted a way to display the SQL Explain Plan from v$sql_plan in a formatted way in Oracle 9i on AskTom. Whereas this is easily possible in 10g with DBMS_XPLAN, in 9i this poses a bit of a challenge:

Step 1: Create a view dynamic_plan_table

create or replace view dynamic_plan_table
as
select
rawtohex(address) &#124;&#124; &#8216;_&#8217; &#124;&#124; child_number statement_id,
sysdate [...]]]></description>
			<content:encoded><![CDATA[<p>Tom Kyte has posted a way to display the SQL Explain Plan from v$sql_plan in a formatted way in Oracle 9i on <a href="http://asktom.oracle.com/pls/ask/f?p=4950:8:4653056091156531243::NO::F4950_P8_DISPLAYID,F4950_P8_CRITERIA:10353453905351">AskTom</a>. Whereas this is easily possible in 10g with DBMS_XPLAN, in 9i this poses a bit of a challenge:</p>
<ul>
<li>Step 1: Create a view dynamic_plan_table</li>
</ul>
<blockquote><p>create or replace view dynamic_plan_table<br />
as<br />
select<br />
rawtohex(address) || &#8216;_&#8217; || child_number statement_id,<br />
sysdate timestamp, operation, options, object_node,<br />
object_owner, object_name, 0 object_instance,<br />
optimizer,   search_columns, id, parent_id, position,<br />
cost, cardinality, bytes, other_tag, partition_start,<br />
partition_stop, partition_id, other, distribution,<br />
cpu_cost, io_cost, temp_space, access_predicates,<br />
filter_predicates<br />
from v$sql_plan;</p></blockquote>
<ul>
<li>Step 2: Extract SQL child_number, rawtohex(address) from v$sql for a known SQL hash value:</li>
</ul>
<blockquote><p>SQL&gt; select rawtohex(address) , child_number from v$sql where hash_value = &#8216;4163478529&#8242;;</p></blockquote>
<ul>
<li>Step 3: Query DBMS_XPLAN with created view</li>
</ul>
<blockquote><p>SQL&gt; r    select plan_table_output    from TABLE(        dbms_xplan.display                   ( &#8216;dynamic_plan_table&#8217;,                     (select rawtohex(address)||&#8217;_'||child_number x                             from v$sql                             where hash_value = &#8216;3471874038&#8242; AND                            rawtohex(ADDRESS) = &#8216;00000003A924BBD0&#8242; AND                             child_number = 1 ), &#8216;ALL&#8217; ) )</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.ora-solutions.net/web/2008/10/19/formatted-sql-plan-display-in-oracle-9i/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
