{"id":299,"date":"2008-01-24T01:26:30","date_gmt":"2008-01-24T05:26:30","guid":{"rendered":"http:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/"},"modified":"2008-01-24T01:26:30","modified_gmt":"2008-01-24T05:26:30","slug":"oradebug-oracle-utility","status":"publish","type":"post","link":"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/","title":{"rendered":"ORADEBUG &#8211; Oracle Utility"},"content":{"rendered":"<p>\u00a0oradebug iutility s especially useful when\u00a0 things go very bad for example Database hangs,Due to ORA-00600 error your database is crashing frequently, Database just not responding (stop). With oradebug you can\u00a0see very close view database engine. Oracle Customer support use the utility mainly to debug these issues. You should have sysdba privilege to run this utility.<\/p>\n<p>\u00a0Main usage of this utility&#8217;s are :<\/p>\n<p>&#8211; Suspension of intensive processes<\/p>\n<p>&#8211; To find out information of shared memory and semaphores<\/p>\n<p>&#8211; Wake up\u00a0processeses<\/p>\n<p>&#8211; enable or disable the SQL traces for another user&#8217;s session<\/p>\n<p>&#8211;\u00a0 closing of trace file to allow new one can be genrated<\/p>\n<p>&#8211; Interanal structure manipulation and dumping<\/p>\n<p>\u00a0oradebug commands:<\/p>\n<p>\u00a01) oradebug help<\/p>\n<p>oradebug help &lt;command name&gt;<\/p>\n<p>without command name argument all commands will be displayed<\/p>\n<p>2)\u00a0 Debug current process<\/p>\n<p>oradebug setmypid<\/p>\n<p>\u00a03) Set OS process id of process\u00a0 to debug<\/p>\n<p>oradebug setospid &lt;ospid&gt;<\/p>\n<p>4)\u00a0 Set Oracle pid of process to debug:<\/p>\n<p>\u00a0oradebug setorapid &lt;orapid&gt; [&#8216;force&#8217;]<\/p>\n<p>Force :Force process<\/p>\n<p>5) For Various Dumps<\/p>\n<p>\u00a0oradebug dump<\/p>\n<p>\u00a06) Set trace event in process<\/p>\n<p>oradebug event &lt;text&gt;<\/p>\n<p>text =&gt; event name<\/p>\n<p>7) Set trace\u00a0event in session<\/p>\n<p>\u00a0oradebug session_event &lt;text&gt;<\/p>\n<p>text =&gt; event_name<\/p>\n<p>8)\u00a0Print\/Dump a fixed PGA\/SGA\/UGA variable<\/p>\n<p>oradebug dumpvar &lt;pls|uga&gt; &lt;name&gt;\u00a0[level]<\/p>\n<p>plsuga =&gt; PGA\/SGA\/UGA<\/p>\n<p>name=&gt;\u00a0variable name<\/p>\n<p>level=&gt; Level<\/p>\n<p>9) Modify a fixed PGA\/SGA\/UGA\u00a0variable<\/p>\n<p>\u00a0oradebug setvar\u00a0&lt;pls|uga&gt; &lt;name&gt; &lt;value&gt;<\/p>\n<p>\u00a0pls|uga\u00a0=&gt; PGA\/SGA\/UGA<\/p>\n<p>name=&gt; variable name<\/p>\n<p>value =&gt; Variable&#8217;s new value<\/p>\n<p>\u00a010) Memory address to a trace file\u00a0 will be dump by this command which can be found in user dump destination.<\/p>\n<p>oradebug peek &lt;addr&gt; &lt;len&gt; [level]<\/p>\n<p>addr=&gt;memory address<\/p>\n<p>len=&gt; length<\/p>\n<p>level=&gt;level<\/p>\n<p>11) Modify memory<\/p>\n<p>oradebug poke &lt;addr&gt; &lt;len&gt; &lt;value&gt;<\/p>\n<p>addr=&gt; memory address<\/p>\n<p>len=&gt; length<\/p>\n<p>value=&gt; value<\/p>\n<p>12) Wake up Process<\/p>\n<p>oradebug wakeup &lt;orapid&gt;<\/p>\n<p>orapid=&gt;oracle PID<\/p>\n<p>13) oradebug command allows you to suspend a process. first you need to identify\u00a0 the shadow process that you want to suspend. Then set your debugs session to point\u00a0 to that process.<\/p>\n<p>oradebug suspend<\/p>\n<p>14) Resume Suspended process..<\/p>\n<p>oradebug resume<\/p>\n<p>15) Flush pending writes to trace file.<\/p>\n<p>oradebug flush<\/p>\n<p>16) Close the Trace file<\/p>\n<p>oradebug close_trace<\/p>\n<p>17) Get name of the Trace file<\/p>\n<p>oradebug tracefile-name<\/p>\n<p>18) The lkdebug and nsdbx are utilities within the oradebug utlity. They are intented for OPS\/RAC.<\/p>\n<p>SQL&gt;oradebug lkdebug help<\/p>\n<p>SQL&gt;oradebug nsdbx help<\/p>\n<p>19) Parallel oradebug command prefix<\/p>\n<p>a)\u00a0oradebug -G &lt;inst-List|def |all&gt;<\/p>\n<p>Inst-List=&gt; Instance List<\/p>\n<p>def=&gt; Default<\/p>\n<p>all=&gt; All instances<\/p>\n<p>b) oradebug -R &lt;inst-List | def|all&gt;<\/p>\n<p>Parameters discussed above are same in this command too.<\/p>\n<p>20) Set Instance\/instances<\/p>\n<p>oradebug setinst<\/p>\n<p>21) Dump SGA to file<\/p>\n<p>oradebug\u00a0 sgatofile &lt;SGA dump dir&gt;<\/p>\n<p>SGA dump dir=&gt;SGA Directory name in double quotes<\/p>\n<p>22) Dump and map SGA as COW (Copy On Write)<\/p>\n<p>oradebug dmpcowsga &lt;SGA dump dir&gt;<\/p>\n<p>SGA dump dir=&gt;SGA Directory name in double quotes<\/p>\n<p>23) Dump and map SGA as COW (Copy On Write). Shared (cow) where cow stand for &#8216;Copy On Write&#8217; is memory that will<\/p>\n<p>write through\u00a0 the cache into real memory.<\/p>\n<p>oradebug mappcowsga &lt;SGA dump dir&gt;<\/p>\n<p>SGA dump dir=&gt;SGA Directory name in double quotes<\/p>\n<p>24) Analyze System hang<\/p>\n<p>oradebug hanganalyze &lt;level&gt;<\/p>\n<p>25) Flash Freeze\u00a0 the Instance<\/p>\n<p>oradebug ffbegin<\/p>\n<p>26) Flash Freeze deregister instance from cluster<\/p>\n<p>oradebug ffderegister<\/p>\n<p>27) Call exit and terminate instance<\/p>\n<p>oradebug ffterminst<\/p>\n<p>28) Resume the flash frozen instance<\/p>\n<p>oradebug ffresumeinst<\/p>\n<p>\u00a029)\u00a0 Flash Freeze\u00a0 status of instance<\/p>\n<p>oradebug ffstatus<\/p>\n<p>30) Help translate PCs to names<\/p>\n<p>oradebug skdsttpcs &lt;ifname&gt;\u00a0 &lt;ofname&gt;<\/p>\n<p>ifname=&gt; File name<\/p>\n<p>31) Watch a region of memory<\/p>\n<p>oradebug watch &lt;address&gt; &lt;len&gt; &lt;self|exist|all|target&gt;<\/p>\n<p>32) Delete a watchpoint<\/p>\n<p>oradebug delete &lt;local|global|target&gt; watchpoint &lt;id&gt;<\/p>\n<p>33) Show watchpoints<\/p>\n<p>oradebug show &lt;local| global|target&gt; watchpoints<\/p>\n<p>34) Dump core without crashing process<\/p>\n<p>oradebug core<\/p>\n<p>35)\u00a0 List semaphores and shared memory segments in use. Set process id\u00a0 before using it. Also this option shows which network is oracle using for RAC traffic.<\/p>\n<p>oradebug ipc<\/p>\n<p>36)Remove the file size limit. Useful when need\u00a0 trace file larger\u00a0 then size specified by max_dump_size parameter.<\/p>\n<p>oradebug unlimit<\/p>\n<p>37) Dump process statistics<\/p>\n<p>oradebug procstat<\/p>\n<p>38) Invoke function with arguments<\/p>\n<p>\u00a0ordebug call &lt;func&gt; [arg1]&#8230;[argn]<\/p>\n<p>func=&gt; function name<\/p>\n<p>[arg1]&#8230;[argn]=&gt; Function Arugment[s]<\/p>\n<p>39) Invoke named dump<\/p>\n<p>oradebug dump &lt;dump_name&gt; &lt;level&gt; &lt;addr&gt;<\/p>\n<p>40) Dump of all state objects\u00a0 for all processes\u00a0 on the system<\/p>\n<p>oradebug dump systemstate<\/p>\n<p>41) Dump of all state objects for process<\/p>\n<p>\u00a0oradebug\u00a0 dump processstate<\/p>\n<p>42) Dump of the process call stack and other information<\/p>\n<p>oradebug dump errorstack\u00a0 &lt;level&gt;<\/p>\n<p>43) The contents\u00a0 of the current controlfile\u00a0 can be dumped\u00a0 in text\u00a0 form to a process trace file\u00a0 in the usre_dump_dest directory using the CONTROLF dump<\/p>\n<p>oradebug dump controlf &lt;level&gt;<\/p>\n<p>44) Dump datafile headers<\/p>\n<p>oradebug dump file_hdrs\u00a0 &lt;level&gt;<\/p>\n<p>\u00a045)\u00a0 To dump one block<\/p>\n<p>alter system dump datafile\u00a0 &lt;file_number&gt; block &lt;block_id&gt;;<\/p>\n<p>To dump one or more data blocks<\/p>\n<p>alter system dump datafile&lt;file_number&gt;\u00a0 block min&lt;first block&gt; block max &lt;last block&gt;;<\/p>\n<p>46) Dump redo headers<\/p>\n<p>oradebug dump redohdr &lt;level&gt;<\/p>\n<p>47) Dump of buffer cache<\/p>\n<p>oradebug dump buffers &lt;level&gt;<\/p>\n<p>48) Dump library cache statistics<\/p>\n<p>\u00a0oradebug dump\u00a0 library_cache &lt;level&gt;<\/p>\n<p>49)\u00a0 Dump strucutre of memory heap<\/p>\n<p>oradebug dump headdump_addr&lt;level&gt; &lt;address&gt;<\/p>\n<p>address=&gt; Descriptor address<\/p>\n<p>50) Dump the strucutre of index tree. The dump file contains one line for each block in the tree, indented\u00a0 to show its level,<\/p>\n<p>together with a count of the number of index entries in the block.<\/p>\n<p>oradebug dump treedump &lt;object_id&gt;<\/p>\n<p>or<\/p>\n<p>alter sesion set events &#8216;immediate\u00a0 trace name treedump level n&#8217;;<\/p>\n<p>This utlitiy is mainly use for resolving the database issues and give more information to a DBA.<\/p>\n<p>Note: Please do not use these command without knowledge or consultationation with oracle support.<\/p>\n<p>51)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u00a0oradebug iutility s especially useful when\u00a0 things go very bad for example Database hangs,Due to ORA-00600 error your database is [&hellip;]<\/p>\n","protected":false},"author":115,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[1],"tags":[],"class_list":["post-299","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.8 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>ORADEBUG - Oracle Utility -<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"ORADEBUG - Oracle Utility -\" \/>\n<meta property=\"og:description\" content=\"\u00a0oradebug iutility s especially useful when\u00a0 things go very bad for example Database hangs,Due to ORA-00600 error your database is [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/\" \/>\n<meta property=\"article:published_time\" content=\"2008-01-24T05:26:30+00:00\" \/>\n<meta name=\"author\" content=\"Masroof Ahmad\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Masroof Ahmad\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/\",\"url\":\"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/\",\"name\":\"ORADEBUG - Oracle Utility -\",\"isPartOf\":{\"@id\":\"https:\/\/onlineappsdba.com\/#website\"},\"datePublished\":\"2008-01-24T05:26:30+00:00\",\"author\":{\"@id\":\"https:\/\/onlineappsdba.com\/#\/schema\/person\/909a876ed58d400faf82caf81d61bfdb\"},\"breadcrumb\":{\"@id\":\"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/onlineappsdba.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"ORADEBUG &#8211; Oracle Utility\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/onlineappsdba.com\/#website\",\"url\":\"https:\/\/onlineappsdba.com\/\",\"name\":\"\",\"description\":\"Oracle Implementation &amp; Training Experts\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/onlineappsdba.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/onlineappsdba.com\/#\/schema\/person\/909a876ed58d400faf82caf81d61bfdb\",\"name\":\"Masroof Ahmad\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/onlineappsdba.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/10f9db7bdbbd7f9ccfbe9b2d208e5978fc28315e9c704383e639a926ea0fce5f?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/10f9db7bdbbd7f9ccfbe9b2d208e5978fc28315e9c704383e639a926ea0fce5f?s=96&d=mm&r=g\",\"caption\":\"Masroof Ahmad\"},\"url\":\"https:\/\/onlineappsdba.com\/index.php\/author\/masroof\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"ORADEBUG - Oracle Utility -","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/","og_locale":"en_US","og_type":"article","og_title":"ORADEBUG - Oracle Utility -","og_description":"\u00a0oradebug iutility s especially useful when\u00a0 things go very bad for example Database hangs,Due to ORA-00600 error your database is [&hellip;]","og_url":"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/","article_published_time":"2008-01-24T05:26:30+00:00","author":"Masroof Ahmad","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Masroof Ahmad","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/","url":"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/","name":"ORADEBUG - Oracle Utility -","isPartOf":{"@id":"https:\/\/onlineappsdba.com\/#website"},"datePublished":"2008-01-24T05:26:30+00:00","author":{"@id":"https:\/\/onlineappsdba.com\/#\/schema\/person\/909a876ed58d400faf82caf81d61bfdb"},"breadcrumb":{"@id":"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/onlineappsdba.com\/index.php\/2008\/01\/24\/oradebug-oracle-utility\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/onlineappsdba.com\/"},{"@type":"ListItem","position":2,"name":"ORADEBUG &#8211; Oracle Utility"}]},{"@type":"WebSite","@id":"https:\/\/onlineappsdba.com\/#website","url":"https:\/\/onlineappsdba.com\/","name":"","description":"Oracle Implementation &amp; Training Experts","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/onlineappsdba.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/onlineappsdba.com\/#\/schema\/person\/909a876ed58d400faf82caf81d61bfdb","name":"Masroof Ahmad","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/onlineappsdba.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/10f9db7bdbbd7f9ccfbe9b2d208e5978fc28315e9c704383e639a926ea0fce5f?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/10f9db7bdbbd7f9ccfbe9b2d208e5978fc28315e9c704383e639a926ea0fce5f?s=96&d=mm&r=g","caption":"Masroof Ahmad"},"url":"https:\/\/onlineappsdba.com\/index.php\/author\/masroof\/"}]}},"_links":{"self":[{"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/posts\/299","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/users\/115"}],"replies":[{"embeddable":true,"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/comments?post=299"}],"version-history":[{"count":0,"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/posts\/299\/revisions"}],"wp:attachment":[{"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/media?parent=299"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/categories?post=299"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/onlineappsdba.com\/index.php\/wp-json\/wp\/v2\/tags?post=299"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}