<?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>Striving for Optimal PerformanceStriving for Optimal Performance &#187; APM Tools</title>
	<atom:link href="http://www.antognini.ch/category/apmtools/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.antognini.ch</link>
	<description></description>
	<lastBuildDate>Thu, 17 May 2012 15:17:12 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>Synthetic Commits and Rollbacks</title>
		<link>http://www.antognini.ch/2009/08/synthetic-commits-and-rollbacks/</link>
		<comments>http://www.antognini.ch/2009/08/synthetic-commits-and-rollbacks/#comments</comments>
		<pubDate>Wed, 19 Aug 2009 21:50:51 +0000</pubDate>
		<dc:creator>Christian Antognini</dc:creator>
				<category><![CDATA[SQL Trace]]></category>
		<category><![CDATA[TVD$XTAT]]></category>

		<guid isPermaLink="false">http://antognini.ch/?p=593</guid>
		<description><![CDATA[Yesterday, I received the following question from a TVD$XTAT user: XCTEND lines are reported as &#8220;COMMIT/ROLLBACK (synthetic)&#8221;. Using Goolge and Metalink I can&#8217;t find any other resources describing &#8220;COMMIT/ROLLBACK (synthetic)&#8221;. This term seems not be widely used, although Hotsos uses the same term. Could you please elaborate what exactly that is and why it possibly [...]]]></description>
			<content:encoded><![CDATA[<p>Yesterday, I received the following question from a <a href="/category/apmtools/tvdxtat/">TVD$XTAT</a> user:</p>
<blockquote><p><em>XCTEND lines are reported as &#8220;COMMIT/ROLLBACK (synthetic)&#8221;. Using Goolge and Metalink I can&#8217;t find any other resources describing &#8220;COMMIT/ROLLBACK (synthetic)&#8221;. This term seems not be widely used, although Hotsos uses the same term. Could you please elaborate what exactly that is and why it possibly happens?</em></p></blockquote>
<p>To understand what &#8220;synthetic&#8221; means, let&#8217;s have a look to two small trace files.The first one is generated by tracing the execution of the following SQL statements in SQL*Plus:</p>
<pre>UPDATE scott.emp SET sal = sal*1.15;
COMMIT;</pre>
<p>The relevant part of the trace file is the following. Notice that:</p>
<ul>
<li>There are two cursors: the first one is the update, the second one is the commit.</li>
<li>In the second one, because it is a commit, between the PARSE and the EXEC lines there is a XCTEND line. Note that the database engine emmits a XCTEND line for every commit or rollback. To differentiate the two, the attribute &#8220;rlbk&#8221; is used: 0=commit, 1=rollback.</li>
<li>The &#8220;log file sync&#8221; wait is associated to the second cursor, the commit.</li>
</ul>
<pre>=====================
PARSING IN CURSOR #3 len=35 dep=0 uid=84 oct=6 lid=84 tim=1250674381587415 hv=950048100 ad='38e58340' sqlid='crk1wdnwa15b4'
UPDATE scott.emp SET sal = sal*1.15
END OF STMT
PARSE #3:c=0,e=338,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=1,plh=1494045816,tim=1250674381587404
EXEC #3:c=2999,e=2831,p=0,cr=7,cu=4,mis=0,r=14,dep=0,og=1,plh=1494045816,tim=1250674381590917
STAT #3 id=1 cnt=0 pid=0 pos=1 obj=0 op='UPDATE  EMP (cr=7 pr=0 pw=0 time=0 us)'
STAT #3 id=2 cnt=14 pid=1 pos=1 obj=73268 op='TABLE ACCESS FULL EMP (cr=7 pr=0 pw=0 time=14 us cost=3 size=70 card=14)'
WAIT #3: nam='SQL*Net message to client' ela= 11 driver id=1413697536 #bytes=1 p3=0 obj#=-1 tim=1250674381592362
WAIT #3: nam='SQL*Net message from client' ela= 1812 driver id=1413697536 #bytes=1 p3=0 obj#=-1 tim=1250674381594288
CLOSE #3:c=0,e=28,dep=0,type=0,tim=1250674381594476
=====================
PARSING IN CURSOR #2 len=6 dep=0 uid=84 oct=44 lid=84 tim=1250674381594857 hv=255718823 ad='0' sqlid='8ggw94h7mvxd7'
COMMIT
END OF STMT
PARSE #2:c=0,e=146,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=0,plh=0,tim=1250674381594814
XCTEND rlbk=0, rd_only=0, tim=1250674381595557
EXEC #2:c=1000,e=740,p=0,cr=0,cu=1,mis=0,r=0,dep=0,og=0,plh=0,tim=1250674381596086
WAIT #2: nam='log file sync' ela= 1974 buffer#=1980 p2=0 p3=0 obj#=-1 tim=1250674381598390
WAIT #2: nam='SQL*Net message to client' ela= 0 driver id=1413697536 #bytes=1 p3=0 obj#=-1 tim=1250674381598664
WAIT #2: nam='SQL*Net message from client' ela= 2770 driver id=1413697536 #bytes=1 p3=0 obj#=-1 tim=1250674381601434
CLOSE #2:c=0,e=17,dep=0,type=3,tim=1250674381601595
=====================</pre>
<p>The second trace file is generated by tracing the execution of the same operations from a Java program. The following is the method that contains the update and the commit:</p>
<pre>private static void test(Connection connection) throws Exception
{
  Statement statement = connection.createStatement();
  statement.execute("UPDATE scott.emp SET sal = sal * 1.15");
  statement.close();
  connection.commit();
}</pre>
<p>The relevant part of the trace file is the following. Notice that:</p>
<ul>
<li>There is only one cursor: the update. No cursor related to the commit is available.</li>
<li>Just after the CLOSE line there is a XCTEND line with the attribute &#8220;rlbk&#8221; set to 0. Obviously a commit was performed.</li>
<li>The &#8220;log file sync&#8221; wait is associated to cursor number 0. Note that the database engine associate to cursor number 0 all lines that cannot be associated to other cursors. In this case a cursor with the commit statement is missing, hence it is not possible to associate the wait to it.</li>
</ul>
<pre>=====================
PARSING IN CURSOR #2 len=37 dep=0 uid=84 oct=6 lid=84 tim=1250673660406187 hv=517367075 ad='38d919e4' sqlid='cc8438wgdct93'
UPDATE scott.emp SET sal = sal * 1.15
END OF STMT
PARSE #2:c=39994,e=40693,p=0,cr=0,cu=0,mis=1,r=0,dep=0,og=1,plh=1494045816,tim=1250673660406167
EXEC #2:c=17997,e=18116,p=0,cr=7,cu=4,mis=0,r=14,dep=0,og=1,plh=1494045816,tim=1250673660427450
STAT #2 id=1 cnt=0 pid=0 pos=1 obj=0 op='UPDATE  EMP (cr=7 pr=0 pw=0 time=0 us)'
STAT #2 id=2 cnt=14 pid=1 pos=1 obj=73268 op='TABLE ACCESS FULL EMP (cr=7 pr=0 pw=0 time=5 us cost=3 size=70 card=14)'
WAIT #2: nam='SQL*Net message to client' ela= 5 driver id=1413697536 #bytes=1 p3=0 obj#=-1 tim=1250673660432401
WAIT #2: nam='SQL*Net message from client' ela= 12925 driver id=1413697536 #bytes=1 p3=0 obj#=-1 tim=1250673660446291
CLOSE #2:c=0,e=45,dep=0,type=0,tim=1250673660447335
XCTEND rlbk=0, rd_only=0, tim=1250673660449381
WAIT #0: nam='log file sync' ela= 1325 buffer#=1217 p2=0 p3=0 obj#=-1 tim=1250673660454674
WAIT #0: nam='SQL*Net message to client' ela= 4 driver id=1413697536 #bytes=1 p3=0 obj#=-1 tim=1250673660454885
=====================</pre>
<p>The interesting thing to note about the second case is that a commit was performed without executing a COMMIT statement. This is possible because at the OCI level a commit can be performed by calling the function <a href="http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28395/oci17msc006.htm#LNOCI13112">OCITransCommit</a>. In other words, without having to execute a statement.</p>
<p>Now, back to the question. When TVD$XTAT processes a trace file like the second one, it automatically generates a cursor related to the commit operation. The text of the cursor will be &#8220;COMMIT (synthetic)&#8221;. So, the term &#8220;synthetic&#8221; is only added to point out that it is a generated cursor. In addition, TVD$XTAT also associate the waits associated to the cursor 0 to the generated cursor. This is very important because in some situations, for example when commits are executed very often or when long rollbacks are executed, the time needed for the commit/rollback is not negligible. As a result, if they were not accounted, the unaccounted-for time could be relevant.</p>
<p>BTW, it is not a coincidence that the <a href="http://method-r.com/software/profiler">Method R Profiler</a> (a.k.a. <a href="http://www.hotsos.com/profiler.html">Hotsos Profiler</a>) and TVD$XTAT uses the same term. I fact, while comparing the two profilers, I noticed that in Method R Profiler the generated statements were called “synthetic”. I found the idea good and since I was looking for a method to mark such statements as well, I borrowed their term.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.antognini.ch/2009/08/synthetic-commits-and-rollbacks/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>TVD$XTAT 4.0 Beta 9</title>
		<link>http://www.antognini.ch/2009/04/tvdxtat-40-beta-9/</link>
		<comments>http://www.antognini.ch/2009/04/tvdxtat-40-beta-9/#comments</comments>
		<pubDate>Thu, 09 Apr 2009 07:08:00 +0000</pubDate>
		<dc:creator>Christian Antognini</dc:creator>
				<category><![CDATA[SQL Trace]]></category>
		<category><![CDATA[TOP]]></category>
		<category><![CDATA[TVD$XTAT]]></category>

		<guid isPermaLink="false">http://antognini.ch/?p=189</guid>
		<description><![CDATA[This is just a short note to point out that I just uploaded under the section Downloadable Files of TOP a new version of TVD$XTAT. Not only I introduced some new features, but I also fixed a couple of major bugs related to memory consumption and poor performance&#8230; The detailed change log since Beta 8 [...]]]></description>
			<content:encoded><![CDATA[<p>This is just a short note to point out that I just uploaded under the section <a href="/top/downloadable-files/">Downloadable Files</a> of <a href="/top">TOP</a> a new version of <a href="/category/apmtools/tvdxtat/">TVD$XTAT</a>. Not only I introduced some new features, but I also fixed a couple of major bugs related to memory consumption and poor performance&#8230;</p>
<p>The detailed change log since <a href="/2008/11/tvdxtat-40-beta-8/">Beta 8</a> is the following:</p>
<ul>
<li>Added formatting for bind variable values of type DATE</li>
<li>Added support for several execution plans for a single cursor</li>
<li>Added number of executions and hash value to execution plans</li>
<li>Added detection of incomplete execution plans</li>
<li>Added support for RPC bind variables</li>
<li>Added command-line option to control logging level</li>
<li>Added warning for 11.1.0.7 trace files (because of bug# 7522002 timing information might be wrong)</li>
<li>Improved data type detection to distinguish VARCHAR2 from NVARCHAR2 and CHAR from NCHAR</li>
<li>Improved handling of incorrectly formatted input lines</li>
<li>Changed logging formatter (time is displayed with the following pattern HH:mm:ss)</li>
<li>Reduced memory utilization for the processing of large trace files</li>
<li>Fix to prevent poor performance for the processing of large trace files</li>
<li>Fix to replace special characters not supported by XML (the unicode character FFFD is used istead of the special ones)</li>
<li>Fix in template to correctly handle space character in SQL text and bind variable values</li>
<li>Fix to ignore timestamp lines not generated by SQL trace </li>
</ul>
<p>As always, your feedback is welcome!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.antognini.ch/2009/04/tvdxtat-40-beta-9/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Oracle AD4J Installation on Linux</title>
		<link>http://www.antognini.ch/2009/02/oracle-ad4j-installation-on-linux/</link>
		<comments>http://www.antognini.ch/2009/02/oracle-ad4j-installation-on-linux/#comments</comments>
		<pubDate>Fri, 13 Feb 2009 10:37:49 +0000</pubDate>
		<dc:creator>Christian Antognini</dc:creator>
				<category><![CDATA[Bug]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oracle AD4J]]></category>

		<guid isPermaLink="false">http://antognini.ch/?p=70</guid>
		<description><![CDATA[Today I tried to install Oracle AD4J on a Linux server that I have at home. The installation procedure is really simple and fully described here. Unfortunately, when I tried to access the console for the first time (that access is one of the installation steps), the HTTP server returned an internal server error (500). [...]]]></description>
			<content:encoded><![CDATA[<p>Today I tried to install <a href="http://www.oracle.com/technology/products/oem/mgmt_solutions/apm.html">Oracle AD4J</a> on a Linux server that I have at home. The installation procedure is really simple and fully described <a href="http://download.oracle.com/docs/cd/B16240_01/doc/install.102/e11085/toc.htm">here</a>. Unfortunately, when I tried to access the console for the first time (that access is one of the installation steps), the HTTP server returned an internal server error (500). In the mod_jserv.log logfile I found the following error messages:</p>
<pre>[13/02/2009 10:06:38:079] (EMERGENCY) ajp12: can not connect to host 127.0.0.1:3501
[13/02/2009 10:06:38:181] (EMERGENCY) ajp12: connection fail
[13/02/2009 10:06:38:181] (ERROR) an error returned handling request via protocol "ajpv12"</pre>
<p>Mhmm&#8230; a listener should be available on port 3501. But, no such listener was available on my system (note that port 3500 is used for the HTTP listener):</p>
<pre>oracle@helicon:/u00/app/oracle/product/ad4j/ [rdbms11107] netstat -l --numeric-ports | grep 350[01]
tcp        0      0 *:3500                      *:*                         LISTEN</pre>
<p>A quick search in <a href="http://metalink.oracle.com">Metalink</a> revealed that at least another person has hit the same issue few days ago (see bug# 8235076). Since OSS is still working on it, I&#8217;ll wait to see what the findings are. In the mean time, I was able to successfully install it on my Windows laptop.</p>
<p>Anyway, if somebody of you managed to successfully install AD4J on Linux, please, let me know!</p>
<p><strong>ADDENDA</strong> (February 16th, 2009): Because of the comments of Charles and Michael I spent a bit more time looking at the problem. In fact, the first time I stopped immediately after seeing the bug in Metalink… I was lazy <img src='http://www.antognini.ch/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> . Hey, I try to optimize my worktime as well. Anyway, both suggested to manually start jserv. When I tried to do so, I received an error (at last). Based on it the problem was self explanatory! The java environment was causing the problem… In fact, with the default installation of CentOS 4.4 only the package java-1.4.2-gcj-compat was installed. After downloading and installing the most recent version of HotSpot (build 1.6.0_12-b04) the problem was solved.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.antognini.ch/2009/02/oracle-ad4j-installation-on-linux/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Execution Plan Hash Value in SQL Trace Files</title>
		<link>http://www.antognini.ch/2009/01/execution-plan-hash-value-in-sql-trace-files/</link>
		<comments>http://www.antognini.ch/2009/01/execution-plan-hash-value-in-sql-trace-files/#comments</comments>
		<pubDate>Mon, 12 Jan 2009 10:10:17 +0000</pubDate>
		<dc:creator>Christian Antognini</dc:creator>
				<category><![CDATA[11gR1]]></category>
		<category><![CDATA[SQL Trace]]></category>
		<category><![CDATA[TVD$XTAT]]></category>

		<guid isPermaLink="false">http://antognini.ch/?p=65</guid>
		<description><![CDATA[In a previous post I already pointed out that as of 11.1.0.7 new information is provided in the SQL trace files. One of them is the value &#8220;plh&#8221; in the PARSE, EXEC and FETCH lines. This new value provides the execution plan hash value. While adding this information to the output generated by TVD$XTAT I [...]]]></description>
			<content:encoded><![CDATA[<p>In a previous <a href="/2008/09/new-information-in-sql-trace-files/">post</a> I already pointed out that as of 11.1.0.7 new information is provided in the SQL trace files. One of them is the value &#8220;plh&#8221; in the PARSE, EXEC and FETCH lines. This new value provides the execution plan hash value. While adding this information to the output generated by <a href="/category/apmtools/tvdxtat/">TVD$XTAT</a> I had to decide how to handle this new value. Hence, I executed the following test case in SQL*Plus&#8230;</p>
<ul>
<li>I prepared the test environment by executing the following SQL statements:</li>
</ul>
<pre>ALTER SYSTEM FLUSH SHARED_POOL;

CREATE TABLE t
AS
SELECT rownum AS id, rpad('*',100,'*') AS pad
FROM dual
CONNECT BY level <= 1000;

ALTER TABLE t ADD CONSTRAINT t_pk PRIMARY KEY (id);

EXECUTE dbms_stats.gather_table_stats(ownname=>user,tabname=>'t')

VARIABLE id NUMBER</pre>
<ul>
<li>I enabled SQL trace:</li>
</ul>
<pre>EXECUTE dbms_monitor.session_trace_enable(waits=>false,binds=>false)</pre>
<ul>
<li>I execute three time the same query that, by the way, takes advantage of <em>extended cursor sharing</em> (a.k.a. <a href="http://optimizermagic.blogspot.com/2007/12/why-are-there-more-cursors-in-11g-for.html">adaptive cursor sharing</a> and <a href="http://download.oracle.com/docs/cd/B28359_01/server.111/b28279/chapter1.htm#FEATURENO07493">intelligent cursor sharing</a>):</li>
</ul>
<pre>EXECUTE :id := 10;

SELECT count(pad) FROM t WHERE id < :id;

EXECUTE :id := 990;

SELECT count(pad) FROM t WHERE id < :id;

SELECT count(pad) FROM t WHERE id < :id;</pre>
<ul>
<li>I disabled SQL trace and displayed the name of the trace file:</li>
</ul>
<pre>EXECUTE dbms_monitor.session_trace_disable

SELECT value
FROM v$diag_info
WHERE name = 'Default Trace File';</pre>
<p>Now, let's check the content of the trace file...</p>
<ul>
<li>For the first query, the following information is provided. Notice that in the line PARSE the value of "plh" is "0"; in the line EXEC the value of "plh" is "4270555908"; in the lines PARSE and EXEC the value of "mis" is "1" (the cursor was hard parsed); according to the execution plan (the line beginning with STAT; notice that I manually removed the runtime statistics and query optimizer estimations to keep the output more readable) the table was read through an index range scan.</li>
</ul>
<pre>PARSING IN CURSOR #2 len=39 dep=0 uid=83 oct=3 lid=83 tim=1231427339018492 hv=1107655156 ad='2e70b9cc' sqlid='asth1mx10aygn'
SELECT count(pad) FROM t WHERE id < :id
END OF STMT
PARSE #2:c=0,e=0,p=0,cr=0,cu=0,mis=1,r=0,dep=0,og=1,plh=0,tim=1231427339018492
EXEC #2:c=2000,e=0,p=0,cr=0,cu=0,mis=1,r=0,dep=0,og=1,plh=4270555908,tim=1231427339018492
FETCH #2:c=0,e=0,p=0,cr=3,cu=0,mis=0,r=1,dep=0,og=1,plh=4270555908,tim=1231427339018492
STAT #2 id=1 cnt=1 pid=0 pos=1 obj=0 op='SORT AGGREGATE'
STAT #2 id=2 cnt=9 pid=1 pos=1 obj=72373 op='TABLE ACCESS BY INDEX ROWID T'
STAT #2 id=3 cnt=9 pid=2 pos=1 obj=72374 op='INDEX RANGE SCAN T_PK'
FETCH #2:c=0,e=0,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=0,plh=4270555908,tim=1231427339018492
CLOSE #2:c=0,e=0,dep=0,type=0,tim=1231427339018492</pre>
<ul>
<li>For the second query, the following information is provided. Notice that in the lines PARSE and EXEC the value of "plh" is "4270555908" (the same as the previous query) and the value of "mis" is "0" (the cursor was <em>not</em> hard parsed), i.e. a cursor already present in the library cache was reused.</li>
</ul>
<pre>PARSING IN CURSOR #4 len=39 dep=0 uid=83 oct=3 lid=83 tim=1231427339018492 hv=1107655156 ad='2e70b9cc' sqlid='asth1mx10aygn'
SELECT count(pad) FROM t WHERE id < :id
END OF STMT
PARSE #4:c=0,e=0,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=1,plh=4270555908,tim=1231427339018492
EXEC #4:c=0,e=0,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=1,plh=4270555908,tim=1231427339018492
FETCH #4:c=0,e=0,p=0,cr=19,cu=0,mis=0,r=1,dep=0,og=1,plh=4270555908,tim=1231427339018492
STAT #4 id=1 cnt=1 pid=0 pos=1 obj=0 op='SORT AGGREGATE'
STAT #4 id=2 cnt=989 pid=1 pos=1 obj=72373 op='TABLE ACCESS BY INDEX ROWID T'
STAT #4 id=3 cnt=989 pid=2 pos=1 obj=72374 op='INDEX RANGE SCAN T_PK'
FETCH #4:c=0,e=0,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=0,plh=4270555908,tim=1231427339018492
CLOSE #4:c=0,e=0,dep=0,type=0,tim=1231427339018492</pre>
<ul>
<li>For the third query, the one taking advantage of extended cursor sharing, the following information is provided. Notice that in the line PARSE the value of "plh" is "4270555908" (the same as the previous query) and the value of "mis" is "0" (cursor was <em>not</em> hard parsed); in the line EXEC the value of "plh" is "2966233522" and the value of "mis" is "1" (cursor was hard parsed); according to the execution plan the table was read through a full table scan, i.e. not the same execution plan as the previous queries.</li>
</ul>
<pre>PARSING IN CURSOR #13 len=39 dep=0 uid=83 oct=3 lid=83 tim=1231427339018492 hv=1107655156 ad='2e70b9cc' sqlid='asth1mx10aygn'
SELECT count(pad) FROM t WHERE id < :id
END OF STMT
PARSE #13:c=0,e=0,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=1,plh=4270555908,tim=1231427339018492
EXEC #13:c=0,e=0,p=0,cr=0,cu=0,mis=1,r=0,dep=0,og=1,plh=2966233522,tim=1231427339018492
FETCH #13:c=0,e=0,p=0,cr=19,cu=0,mis=0,r=1,dep=0,og=1,plh=2966233522,tim=1231427339018492
STAT #13 id=1 cnt=1 pid=0 pos=1 obj=0 op='SORT AGGREGATE'
STAT #13 id=2 cnt=989 pid=1 pos=1 obj=72373 op='TABLE ACCESS FULL T'
FETCH #13:c=0,e=0,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=0,plh=2966233522,tim=1231427339018492
CLOSE #13:c=0,e=0,dep=0,type=0,tim=1231427339018492</pre>
<p>In summary, according to this test:</p>
<ul>
<li>The value of "plh" in the line EXEC provides the hash value of the execution plan used to execute a SQL statement.</li>
<li>The value of "plh" in the line PARSE cannot be trusted.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.antognini.ch/2009/01/execution-plan-hash-value-in-sql-trace-files/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>PerformaSure X-Agent Configuration</title>
		<link>http://www.antognini.ch/2009/01/performasure-x-agent-configuration/</link>
		<comments>http://www.antognini.ch/2009/01/performasure-x-agent-configuration/#comments</comments>
		<pubDate>Mon, 05 Jan 2009 17:47:42 +0000</pubDate>
		<dc:creator>Christian Antognini</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Quest PerformaSure]]></category>

		<guid isPermaLink="false">http://antognini.ch/?p=64</guid>
		<description><![CDATA[PerformaSure of Quest Software is a J2EE performance diagnosis tool that provides an end-to-end transaction-centric view of performance as experienced by end users. To gather profile information PerformaSure uses one or several agents deployed on the monitored systems. Since gathering profile information depends on the monitored component, three different agents are available: System agent gather [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.quest.com/performasure/">PerformaSure</a> of <a href="http://www.quest.com/">Quest Software</a> is a J2EE performance diagnosis tool that provides an end-to-end transaction-centric view of performance as experienced by end users. To gather profile information PerformaSure uses one or several agents deployed on the monitored systems. Since gathering profile information depends on the monitored component, three different agents are available:</p>
<ul>
<li><em>System agent</em> gather performance figures about the operating system.</li>
<li><em>Web server agents</em> gather performance figures about a web server.</li>
<li><em>Application server agents</em> gather detailed performance figures about an application server.</li>
</ul>
<p>Since the agents are specific to each component, Quest Software clearly states which components are officially supported. For example, the current release (4.4) supports the following application servers: BEA WebLogic Server, IBM WebSphere Application Server, Oracle Application Server, JBoss Application Server and Apache Tomcat Server. Even if those are among the most commonly used, other application servers exist&#8230; For this reason PerformaSure also supports a generic agent called <em>X-Agent</em>. Although the X-Agent does not provide as much information as the other agents do, it might be very useful in some situations. The problem is that the documentation does not provide instructions on how to configure the it. Instead, it provides the following information:</p>
<p><em>&#8220;The X-Agent needs to be configured by Quest Consulting. For more information about customizing the X-Agent and modifying the startup sequence of the application server or standalone Java application that you want to instrument, contact your Quest sales representative.&#8221;</em></p>
<p>Ups! Not very useful&#8230;</p>
<p>To show you how such a configuration is performed, let me describe what I did few days ago on my Windows XP laptop to configure the X-Agent for <em>Sun Java System Application Server 9.1 Update 2</em>.</p>
<ul>
<li>First of all, I opened a command prompt and I defined two environment variables pointing to the installation directories of Java and PerformaSure</li>
</ul>
<pre>c:tmp>set JAVA_HOME=C:Javajdk1.5.0
c:tmp>set PERFORMASURE_HOME=C:JavaquestPerformaSure4.4.0</pre>
<ul>
<li>Then, in the same command prompt, I called the script preinstrumentor.cmd to create a JAR file that will be used during the startup of the application server</li>
</ul>
<pre>
c:tmp>call "%PERFORMASURE_HOME%scriptspreinstrumentor.cmd" "%JAVA_HOME%"
2008-12-26 23:09:00.703 INFO  Loading Agent startup configuration from C:Java
  questPerformaSure4.4.0configagent.config
2008-12-26 23:09:02.031 INFO  PerformaSure 4.4 (Build PAS_440-20061024-1025) on
  Windows XP x86 5.1 using Sun Microsystems Inc. Java HotSpot(TM) Client VM
  version 1.5.0_10-b03 (extra info: mixed mode, sharing); Agent Type:
  Preinstrumentor
2008-12-26 23:09:02.062 INFO  Configured to connect to Nexus at localhost:41705
2008-12-26 23:09:02.187 INFO  Connected to Nexus at localhost:41705
2008-12-26 23:09:03.203 INFO  Agent started
2008-12-26 23:09:03.203 INFO  Creating bootstrap classes in C:JavaquestPerfo
  rmaSure4.4.0scripts..bootstrapC--Java-jdk-1.5.0.jar
2008-12-26 23:09:05.796 INFO  Preinstrumentation complete
2008-12-26 23:09:05.812 INFO  Preinstrumentor Agent shutdown completed</pre>
<ul>
<li>The last operation I performed through the command prompt was the &#8220;generation&#8221; of two Java options (-Xbootclasspath and -javaagent) to be used in the configuration of the application server (it is not necessary to do it in this way, but with that method it&#8217;s possible to avoid annoying typos&#8230;)</li>
</ul>
<pre>
C:Tmp>call "%PERFORMASURE_HOME%scriptsmakebootstrappath.cmd" "%JAVA_HOME%"
C:Tmp>echo -Xbootclasspath/p:"%PS_BOOTSTRAP_PATH%"
-Xbootclasspath/p:"C:JavaquestPerformaSure4.4.0bootstrapC--Java-jdk-1.5.0.jar"
C:Tmp>echo -javaagent:"%PERFORMASURE_HOME%libperformasure-agent.jar"
-javaagent:"C:JavaquestPerformaSure4.4.0libperformasure-agent.jar"</pre>
<ul>
<li>To finish the configuration I added, through the administration console of the application server, the following JVM options (click <a href="/images/performasure-x-agent-configuration1.jpg" rel="thumbnail" alt="Administration console">here</a> to see an image of the relevant part of the console)</li>
</ul>
<pre>-Dperformasure.agent.appserverinfo=kalgan:Generic:SunAS9
-Dperformasure.debug=0
-Xbootclasspath/p:"C:JavaquestPerformaSure4.4.0bootstrapC--Java-jdk-1.5.0.jar"
-javaagent:"C:JavaquestPerformaSure4.4.0libperformasure-agent.jar"</pre>
<p>Notice that the value of the variable performasure.agent.appserverinfo has the following format: &lt;server&gt;:Generic:&lt;version&gt;.</p>
<p>After these operations I restarted the application server and, as a result, I was able to use PerformaSure to profile the applications running into the JVM of the application server.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.antognini.ch/2009/01/performasure-x-agent-configuration/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>TVD$XTAT 4.0 Beta 8</title>
		<link>http://www.antognini.ch/2008/11/tvdxtat-40-beta-8/</link>
		<comments>http://www.antognini.ch/2008/11/tvdxtat-40-beta-8/#comments</comments>
		<pubDate>Mon, 17 Nov 2008 20:08:13 +0000</pubDate>
		<dc:creator>Christian Antognini</dc:creator>
				<category><![CDATA[SQL Trace]]></category>
		<category><![CDATA[TOP]]></category>
		<category><![CDATA[TVD$XTAT]]></category>

		<guid isPermaLink="false">http://antognini.ch/?p=58</guid>
		<description><![CDATA[This is just a short note to point out that I just uploaded under the section Downloadable Files of TOP a new version of TVD$XTAT. The change log since Beta 7 is the following: Improved generation of synthetic cursors (particularly for RPC and XCTEND) Added support for 11.1.0.7 formatting of XCTEND Added check for questionable [...]]]></description>
			<content:encoded><![CDATA[<p>This is just a short note to point out that I just uploaded under the section <a href="/top/downloadable-files/">Downloadable Files</a> of <a href="/top">TOP</a> a new version of <a href="/category/apmtools/tvdxtat/">TVD$XTAT</a>.</p>
<p>The change log since Beta 7 is the following:</p>
<ul>
<li>Improved generation of synthetic cursors (particularly for RPC and XCTEND)</li>
<li>Added support for 11.1.0.7 formatting of XCTEND</li>
<li>Added check for questionable values for cpu and elapsed time</li>
<li>Extended the list of recognized data types</li>
<li>Fix to avoid Java 1.6.0 bug 6506304  </li>
<li>Fix to correctly handle attribution of bind variables</li>
<li>Fix to correctly handle bind variables containing invalid numbers</li>
<li>Fix to correctly handle bind variables containing the value NULL</li>
<li>Fix to avoid parse errors for bind variables containing kkscoacd lines</li>
<li>Fix to avoid warnings about freed cursors</li>
<li>Fix to avoid warnings for lines beginning with &#8220;*** TRACE CONTINUED FROM FILE&#8221;</li>
</ul>
<p>Please, do not hesitate to contact me if you have any kind of problem while using it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.antognini.ch/2008/11/tvdxtat-40-beta-8/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Introduce TVD$XTAT</title>
		<link>http://www.antognini.ch/2008/10/introduce-tvdxtat/</link>
		<comments>http://www.antognini.ch/2008/10/introduce-tvdxtat/#comments</comments>
		<pubDate>Fri, 24 Oct 2008 13:56:51 +0000</pubDate>
		<dc:creator>Christian Antognini</dc:creator>
				<category><![CDATA[SQL Trace]]></category>
		<category><![CDATA[TKPROF]]></category>
		<category><![CDATA[TOP]]></category>
		<category><![CDATA[TVD$XTAT]]></category>

		<guid isPermaLink="false">http://antognini.ch/?p=55</guid>
		<description><![CDATA[Trivadis Extended Tracefile Analysis Tool (TVD$XTAT) is a command-line tool. Like TKPROF, its main purpose is to take a raw SQL trace file as input and generate a formatted file as output. Why Is TKPROF Not Enough? In late 1999, I had my first encounter with extended SQL trace, through MetaLink note Interpreting Raw SQL_TRACE [...]]]></description>
			<content:encoded><![CDATA[<p>Trivadis Extended Tracefile Analysis Tool (TVD$XTAT) is a command-line tool. Like TKPROF, its main purpose is to take a raw SQL trace file as input and generate a formatted file as output.</p>
<p>Why Is TKPROF Not Enough?</p>
<p>In late 1999, I had my first encounter with extended SQL trace, through MetaLink note <em>Interpreting Raw SQL_TRACE and DBMS_SUPPORT.START_TRACE output</em> (39817.1). From the beginning, it was clear that the information it provided was essential for understanding what an application is doing when it is connected to an Oracle database engine. At the same time, I was very disappointed that no tool was available for analyzing extended SQL trace files for the purpose of leveraging their content. I should note that TKPROF at that time did not provide information about wait events. After spending too much time manually extracting information from the raw trace files, I decided to write my own analysis tool: TVD$XTAT.</p>
<p>Currently, TKPROF provides information about wait events, but it still has three major problems that are addressed in TVD$XTAT:</p>
<ul>
<li>As soon as the argument sort is specified, the relationship between SQL statements is lost.</li>
<li>Data is provided only in aggregated form. Consequently, useful information is lost.</li>
<li>No information about bind variables is provided.</li>
</ul>
<p>TVD$XTAT is freeware. You can download it (presently, version 4.0 beta 7) from <a href="/top/downloadable-files/">this page</a>. <a href="/top/">TOP</a> fully describes how to use it to identify performance problems. The installation is documented in the README file.</p>
<p>It goes without saying that all feedbacks about TVD$XTAT are highly welcome.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.antognini.ch/2008/10/introduce-tvdxtat/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
	</channel>
</rss>

