<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4238388508729730478</id><updated>2026-01-17T23:36:33.937+01:00</updated><category term="oracle"/><category term="grid control"/><category term="management"/><category term="installation"/><category term="standby"/><category term="data pump"/><category term="rman"/><category term="zabbix"/><category term="archivelog"/><category term="diagnostics"/><category term="duplicate database"/><category term="partitioning"/><category term="pl/sql"/><category term="XA"/><category term="distributed transaction"/><category term="format"/><category term="impdp"/><category term="interval partitioning"/><category term="job scheduler"/><category term="mview"/><category term="opatch"/><category term="oracle database"/><category term="real time apply"/><category term="recovery"/><category term="sqlplus"/><category term="AQ"/><category term="OMF"/><category term="ORA-00001"/><category term="ORA-16053"/><category term="ORA-31603"/><category term="ORA-39034"/><category term="ORA-4030"/><category term="ORA-600"/><category term="ORA-600 [2730]"/><category term="ZBX-7373"/><category term="adrci"/><category term="agent"/><category term="backup"/><category term="bind variable"/><category term="catalog"/><category term="change management"/><category term="client connection"/><category term="cman"/><category term="connection pool"/><category term="db link"/><category term="dbnewid"/><category term="diagnostics_dest"/><category term="drcp"/><category term="editor command"/><category term="example"/><category term="fast refresh"/><category term="getLast"/><category term="global_names"/><category term="hash"/><category term="listener"/><category term="lock"/><category term="log rotation"/><category term="nfs"/><category term="ora files"/><category term="parfile"/><category term="proxy"/><category term="queue"/><category term="raw trace"/><category term="recyclebin"/><category term="resumable"/><category term="sql*plus"/><category term="su"/><category term="supplemental logging"/><category term="tape"/><category term="tnsnames"/><category term="tspitr"/><category term="utl_file"/><category term="vim"/><title type='text'>Remigium</title><subtitle type='html'>... about my professional issues</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>169</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-5233381845282334933</id><published>2018-12-14T09:32:00.001+01:00</published><updated>2018-12-14T09:32:09.886+01:00</updated><title type='text'>ORA-07286: sksagdi: cannot obtain device information</title><content type='html'>Lately we had an issue regarding a Dataguard configuration - quite myesterious.&lt;br&gt;
In dgmgrl there were reported standard errors about broken transport and inability to solve the gap and ORA-16810, which is actually the error, which just tell You, something is wrong (and not what is wrong).&lt;br&gt;
The behaviour was as follows - the apply processes worked ok, so if I restored the archivelogs on the standby, they were applied even up to the current log. But then nothing - so it was clear there was a problem with the transport. But resetting connections was in vain, we also changed some parameters in the dataguard configuration, still nothing.&lt;br&gt;
Finally the right solution was to restart the standby, which was a bit counterintuitive as the transport is mainly the feature of the primary. This was also fortunate, as there was no problem to perform that at once without service disruption.</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/5233381845282334933/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/5233381845282334933' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5233381845282334933'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5233381845282334933'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/12/ora-07286-sksagdi-cannot-obtain-device.html' title='ORA-07286: sksagdi: cannot obtain device information'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-500772120512582019</id><published>2018-11-22T15:05:00.000+01:00</published><updated>2018-11-22T15:05:44.324+01:00</updated><title type='text'>Logon storms</title><content type='html'>&lt;a href=&quot;https://www.slideshare.net/tanelp/tanel-poder-troubleshooting-complex-oracle-performance-issues-part-1&quot;&gt;https://www.slideshare.net/tanelp/tanel-poder-troubleshooting-complex-oracle-performance-issues-part-1&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
RATE_LIMIT parameter in listener.ora&lt;br&gt;
_logout_storm_rate - instance parameter&lt;br&gt;

</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/500772120512582019/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/500772120512582019' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/500772120512582019'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/500772120512582019'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/11/logon-storms.html' title='Logon storms'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-2675598923452835035</id><published>2018-10-02T13:38:00.002+02:00</published><updated>2018-10-02T13:40:04.729+02:00</updated><title type='text'>Work with EMCLI </title><content type='html'>&lt;h2&gt;Starting the work&lt;/h2&gt;
Initially one have to login - without that the commands are not recognized as valid and even help is reduced
&lt;pre&gt;
[oracle@host ~]$ emcli help
Summary of commands:


  Basic Administration Verbs
    argfile    -- Execute emcli verbs from a file
    help       -- Get help for emcli verbs (Usage: emcli help [verb_name])
    invoke_ws     -- Invoke EM web service.
    login      -- Login to the EM Management Server (OMS)
    logout     -- Logout from the EM Management Server
    setup      -- Setup emcli to work with an EM Management Server
    status     -- List emcli configuration details
    sync       -- Synchronize with the EM Management Server
    version    -- List emcli verb versions or the emcli client version

  To get the help for a single verb, execute - emcli help &lt;verb&gt; 
&lt;/pre&gt;
So we start
&lt;pre&gt;
[oracle@host ~]$ emcli login -username=sysman
Enter password 

Login successful
&lt;/pre&gt;

Now help looks way more elaborate:
&lt;pre&gt;
[oracle@host ~]$ emcli help
Summary of commands:


  Basic Administration Verbs
    argfile    -- Execute emcli verbs from a file
    help       -- Get help for emcli verbs (Usage: emcli help [verb_name])
    invoke_ws     -- Invoke EM web service.
    login      -- Login to the EM Management Server (OMS)
    logout     -- Logout from the EM Management Server
    setup      -- Setup emcli to work with an EM Management Server
    status     -- List emcli configuration details
    sync       -- Synchronize with the EM Management Server
    version    -- List emcli verb versions or the emcli client version

  ADM Verbs
    associate_target_to_adm     -- Associate a target to an application data model.
    export_adm     -- Export Application Data Model to a specified .xml file.
    import_adm     -- Import Application Data Model from a specified .xml file.
[..]

  WebSphere Target Management Verbs
    discover_was    -- Discover a IBM WebSphere Cell or a IBM Websphere Standalone Server
    refresh_was    -- Refresh IBM WebSphere Cells
argus
  To get the help for a single verb, execute - emcli help &lt;verb&gt; 
&lt;/pre&gt;

&lt;h2&gt;Adding a new blackout reason&lt;/h2&gt;
&lt;pre&gt;
## to add:
[oracle@host ~]$ emcli add_blackout_reason -name=&quot;Target disabled intentionally&quot;
Added Blackout Reason &quot;Target disabled intentionally&quot; successfully

## to list
[oracle@host ~]$ emcli get_blackout_reasons
AS: Application Server Bounce
AS: Application Server Configuration Change
AS: Application Server Emergency
[..]
&lt;/pre&gt;

</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/2675598923452835035/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/2675598923452835035' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/2675598923452835035'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/2675598923452835035'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/10/work-with-emcli.html' title='Work with EMCLI '/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-3043821872181730368</id><published>2018-09-11T10:48:00.000+02:00</published><updated>2018-09-11T10:48:01.539+02:00</updated><title type='text'>ASM: moving disk between groups</title><content type='html'>&lt;pre&gt;
SQL&gt; select name||&#39;:&#39;||path from v$asm_disk;

[..]
DATA_0008:/dev/oracleasm/disks/ASMDISK9

-- the operation
SQL&gt; alter diskgroup DATA drop disk {chosen name from previous query} [rebalance power {speed between 0 and 11}];

-- the operation progress
SQL&gt; select operation, state, est_minutes from v$asm_operation;

OPERA STAT EST_MINUTES
----- ---- -----------
REBAL RUN      7
REBAL WAIT      0

SQL&gt; select GROUP_NUMBER,name,STATE from v$asm_disk where name=&#39;DATA_0008&#39;;

GROUP_NUMBER NAME       STATE
------------ ------------------------------ --------
    1 DATA_0008       DROPPING

-- ASM alert
Tue Sep 11 10:40:51 2018
NOTE: requesting all-instance membership refresh for group=1
Tue Sep 11 10:40:51 2018
GMON updating for reconfiguration, group 1 at 14 for pid 30, osid 19142
Tue Sep 11 10:40:51 2018
NOTE: group 1 PST updated.
SUCCESS: grp 1 disk DATA_0008 emptied
NOTE: erasing header (replicated) on grp 1 disk DATA_0008
NOTE: erasing header on grp 1 disk DATA_0008
NOTE: process _x000_+asm (19142) initiating offline of disk 8.3915952393 (DATA_0008) with mask 0x7e in group 1 (DATA) without client assisting
NOTE: initiating PST update: grp 1 (DATA), dsk = 8/0xe968b109, mask = 0x6a, op = clear
Tue Sep 11 10:40:51 2018
GMON updating disk modes for group 1 at 15 for pid 30, osid 19142
Tue Sep 11 10:40:51 2018
NOTE: PST update grp = 1 completed successfully 
NOTE: initiating PST update: grp 1 (DATA), dsk = 8/0xe968b109, mask = 0x7e, op = clear
Tue Sep 11 10:40:51 2018
GMON updating disk modes for group 1 at 16 for pid 30, osid 19142
Tue Sep 11 10:40:51 2018
NOTE: cache closing disk 8 of grp 1: DATA_0008
Tue Sep 11 10:40:51 2018
NOTE: cache closing disk 8 of grp 1: (not open) DATA_0008
Tue Sep 11 10:40:51 2018
NOTE: PST update grp = 1 completed successfully 
Tue Sep 11 10:40:51 2018
GMON updating for reconfiguration, group 1 at 17 for pid 30, osid 19142
Tue Sep 11 10:40:51 2018
NOTE: cache closing disk 8 of grp 1: (not open) DATA_0008
Tue Sep 11 10:40:51 2018
NOTE: group 1 PST updated.
Tue Sep 11 10:40:51 2018
NOTE: membership refresh pending for group 1/0xb68400e (DATA)
Tue Sep 11 10:40:51 2018
GMON querying group 1 at 18 for pid 16, osid 10242
GMON querying group 1 at 19 for pid 16, osid 10242
Tue Sep 11 10:40:51 2018
NOTE: Disk DATA_0008 in mode 0x0 marked for de-assignment
SUCCESS: refreshed membership for 1/0xb68400e (DATA)
NOTE: stopping process ARB0
NOTE: Attempting voting file refresh on diskgroup DATA
Tue Sep 11 10:40:54 2018
SUCCESS: rebalance completed for group 1/0xb68400e (DATA)

SQL&gt; select operation, state, est_minutes from v$asm_operation;

no rows selected

SQL&gt; select GROUP_NUMBER,name,STATE from v$asm_disk where name=&#39;DATA_0008&#39;;

no rows selected

SQL&gt; alter diskgroup reco  add disk &#39;/dev/oracleasm/disks/ASMDISK9&#39;;

Diskgroup altered

-- ASM alert entry
Tue Sep 11 10:45:43 2018
NOTE: Assigning number (2,1) to disk (/dev/oracleasm/disks/ASMDISK9)
NOTE: requesting all-instance membership refresh for group=2
NOTE: Disk 1 in group 2 is assigned fgnum=2
NOTE: discarding redo for group 2 disk 1
NOTE: initializing header (replicated) on grp 2 disk RECO_0001
NOTE: initializing header on grp 2 disk RECO_0001
NOTE: requesting all-instance disk validation for group=2
Tue Sep 11 10:45:44 2018
NOTE: skipping rediscovery for group 2/0xb78400f (RECO) on local instance.
Tue Sep 11 10:45:44 2018
NOTE: requesting all-instance disk validation for group=2
Tue Sep 11 10:45:44 2018
NOTE: skipping rediscovery for group 2/0xb78400f (RECO) on local instance.
Tue Sep 11 10:45:44 2018
GMON updating for reconfiguration, group 2 at 20 for pid 28, osid 20206
Tue Sep 11 10:45:44 2018
NOTE: group 2 PST updated.
Tue Sep 11 10:45:44 2018
NOTE: membership refresh pending for group 2/0xb78400f (RECO)
Tue Sep 11 10:45:44 2018
GMON querying group 2 at 21 for pid 16, osid 10242
NOTE: cache opening disk 1 of grp 2: RECO_0001 path:/dev/oracleasm/disks/ASMDISK9
GMON querying group 2 at 22 for pid 16, osid 10242
Tue Sep 11 10:45:44 2018
SUCCESS: refreshed membership for 2/0xb78400f (RECO)
Tue Sep 11 10:45:44 2018
SUCCESS: alter diskgroup reco  add disk &#39;/dev/oracleasm/disks/ASMDISK9&#39;
NOTE: Attempting voting file refresh on diskgroup RECO
Tue Sep 11 10:45:45 2018
NOTE: starting rebalance of group 2/0xb78400f (RECO) at power 1
Starting background process ARB0
Tue Sep 11 10:45:45 2018
ARB0 started with pid=31, OS id=20232 
NOTE: assigning ARB0 to group 2/0xb78400f (RECO) with 1 parallel I/O



&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/3043821872181730368/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/3043821872181730368' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3043821872181730368'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3043821872181730368'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/09/asm-moving-disk-between-groups.html' title='ASM: moving disk between groups'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-5327385663441230165</id><published>2018-07-11T15:17:00.000+02:00</published><updated>2018-07-11T15:17:03.450+02:00</updated><title type='text'>Broken DG configuration</title><content type='html'>Few days ago I &#39;ve run into the following situation on a DG configuration:
&lt;ul&gt;
&lt;li&gt;the primary shipped logs to the standby properly, but reported errors if asked for status in dgmgrl
&lt;pre&gt;
DGMGRL&gt; show configuration

Configuration - dbd

  Protection Mode: MaxPerformance
  Databases:
    db1d - Primary database
    db2d - Physical standby database

Fast-Start Failover: DISABLED

Configuration Status:
ORA-16610: command &quot;Broker operation&quot; in progress
DGM-17017: unable to determine configuration status
&lt;/pre&gt;
&lt;/li&gt;

&lt;li&gt;the standby initially did not process archivelogs, but after configuration reset (disable and enable operations) it started to process them, but also reported errors in dgmgrl
&lt;li&gt;it was possible to log in from the primary to the standby 
&lt;li&gt;it was possible to log in from the standby to the primary
&lt;li&gt;I copied password file from the primary to the standby to ensure this is the same file
&lt;li&gt;when calling show database on the primary the errors were reported for the standby
&lt;li&gt;when calling show database on the standby the errors were reported for the primary
&lt;/ul&gt;
What was the cause?&lt;br&gt;
It showed that the problem was generated by the TNS entries on the primary - apparently the TNS alias definitions for the primary and the standby there included some blank characters, which caused the alias to be read improperly in case of dgmgrl - at the same time simple call to those aliases through sqlplus went ok.&lt;br&gt;
Once I removed all the formatting in the tnsnames.ora, whole thing started to work properly. What is a bit interesting is that the errors in the TNS were present only on the primary, while the dgmgrl calls malfunctioned on both ends. 
</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/5327385663441230165/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/5327385663441230165' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5327385663441230165'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5327385663441230165'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/07/broken-dg-configuration.html' title='Broken DG configuration'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-7801244660613528162</id><published>2018-07-11T14:56:00.003+02:00</published><updated>2018-07-11T14:56:52.250+02:00</updated><title type='text'>Role order</title><content type='html'>Lately a colleague of mine run into the problem with too many roles - some account have them 150, while maximally allowed are 148. He wanted to establish the order in which the roles are assigned to the user as obviously only the excess over 148 was thrown away.&lt;br&gt;
He has found that the roles are loaded with the following query:
&lt;pre&gt;
select /*+ connect_by_filtering */ privilege#,level from sysauth$ connect by grantee#=prior privilege# and privilege#&gt;0 start with grantee#=:1 and privilege#&gt;0; 
&lt;/pre&gt;
Thus it seems as the the order may be random, though it is possible that usually the data is returned in the order of insertion.</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/7801244660613528162/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/7801244660613528162' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/7801244660613528162'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/7801244660613528162'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/07/role-order.html' title='Role order'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-5911439485554128872</id><published>2018-06-29T14:48:00.002+02:00</published><updated>2018-06-29T14:48:55.622+02:00</updated><title type='text'>ORA-01554: transaction concurrency limit reached reason:no undo segment found with available slot params:0, 0 :</title><content type='html'>Some time ago I found such error on one of our databases. It is a bit mysterious as there are not much about it on Metalink (few bugs) or on the internet (at least when searching by Google). But indeed the database hit a limit of concurrent transactions in some very short period of time. On the performance chart in OEM there is a high peak with an INSERT to some custom table, with waits on TX - index contention, buffer busy, enq: SQ contention and undo segment tx slot.&lt;br&gt;
The database is working with UNDO_MANAGEMENT=AUTO, which is a default setting and since 10g used very widely, so the administrator may simply forget about rollback segments management. According to the docs with this setting some work parameters relevant to the rollback management are simply ignored (TRANSACTIONS, TRANSACTIONS_PER_ROLLBACK_SEGMENT), while the number of transactions is limited by the undo tablespace size.&lt;br&gt;
So it seems we should not experience this error, but rather session suspension and the error about lack of space in the undo tablespace.&lt;br&gt;
Yet here are are. It is clear from the numbers below, that still there is a space in the undo (up to 4598 undo blocks used&lt;br&gt;
What I could check is this:
&lt;pre&gt;
select BEGIN_TIME, UNDOTSN, UNDOBLKS, TXNCOUNT, MAXQUERYLEN, MAXQUERYID, MAXCONCURRENCY, 
ACTIVEBLKS, UNEXPIREDBLKS, EXPIREDBLKS, TUNED_UNDORETENTION 
from v$undostat 
where begin_time between to_date(&#39;2018-06-25 14&#39;, &#39;yyyy-mm-dd hh24&#39;) and to_date(&#39;2018-06-25 16&#39;, &#39;yyyy-mm-dd hh24&#39;) 
order by begin_time;

&lt;/pre&gt;
&lt;table&gt;
&lt;tr&gt;&lt;td&gt;BEGIN_TIME&lt;/td&gt;&lt;td&gt;UNDOBLKS&lt;/td&gt;&lt;td&gt;TXNCOUNT&lt;/td&gt;&lt;td&gt;MAXQUERYLEN&lt;/td&gt;&lt;td&gt;MAXCONCURRENCY&lt;/td&gt;&lt;td&gt;ACTIVEBLKS&lt;/td&gt;&lt;td&gt;UNEXPIREDBLKS&lt;/td&gt;&lt;td&gt;EXPIREDBLKS&lt;/td&gt;&lt;td&gt;TUNED_UNDORETENTION&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2018-06-25 14:39&lt;/td&gt;&lt;td&gt;0&lt;/td&gt;&lt;td&gt;78&lt;/td&gt;&lt;td&gt;1652&lt;/td&gt;&lt;td&gt;0&lt;/td&gt;&lt;td&gt;160&lt;/td&gt;&lt;td&gt;0&lt;/td&gt;&lt;td&gt;7168&lt;/td&gt;&lt;td&gt;2372&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2018-06-25 14:49&lt;/td&gt;&lt;td&gt;1411&lt;/td&gt;&lt;td&gt;91&lt;/td&gt;&lt;td&gt;1653&lt;/td&gt;&lt;td&gt;2&lt;/td&gt;&lt;td&gt;160&lt;/td&gt;&lt;td&gt;0&lt;/td&gt;&lt;td&gt;7168&lt;/td&gt;&lt;td&gt;2373&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2018-06-25 14:59&lt;/td&gt;&lt;td&gt;4598&lt;/td&gt;&lt;td&gt;104225&lt;/td&gt;&lt;td&gt;1653&lt;/td&gt;&lt;td&gt;131&lt;/td&gt;&lt;td&gt;160&lt;/td&gt;&lt;td&gt;4736&lt;/td&gt;&lt;td&gt;5888&lt;/td&gt;&lt;td&gt;2373&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2018-06-25 15:09&lt;/td&gt;&lt;td&gt;2169&lt;/td&gt;&lt;td&gt;103321&lt;/td&gt;&lt;td&gt;933&lt;/td&gt;&lt;td&gt;311&lt;/td&gt;&lt;td&gt;160&lt;/td&gt;&lt;td&gt;6656&lt;/td&gt;&lt;td&gt;4352&lt;/td&gt;&lt;td&gt;1653&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;2018-06-25 15:19&lt;/td&gt;&lt;td&gt;2&lt;/td&gt;&lt;td&gt;282&lt;/td&gt;&lt;td&gt;1734&lt;/td&gt;&lt;td&gt;1&lt;/td&gt;&lt;td&gt;160&lt;/td&gt;&lt;td&gt;8064&lt;/td&gt;&lt;td&gt;2816&lt;/td&gt;&lt;td&gt;2454&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;
Since the midnight the number of undo blocks consumed was 63475 with 524416 available blocks (so ~12%) and maximum query length was below 1h. Thus definitely we were far below the undo space limit. From this figures it is clear that still it is possible to hit an error typical for MANUAL undo management scenario, while on AUTO - as here we are.&lt;br&gt;
&lt;br&gt;
And here few words of wisdom from Jonathan Lewis:
&lt;blockquote&gt;
Taking a quick guess:&lt;br&gt;
&lt;br&gt;
An (automatic) undo segment has 34 slots in the transaction table (the thing in the undo segment header).&lt;br&gt;
If you and up with a small number N of undo segments then you can&#39;t have more than 34 * N concurrent transactions active because each one needs a transaction table slot and the next attempt to start a transaction would see ORA-01554&lt;br&gt;
&lt;br&gt;
It seems a little unlikely that this would happan in typical system since Oracle would usually end up stealing an extent from an existing undo segment to use it as the first extent of a new undo segment. But it wouldn&#39;t be hard to set up a mechanism that started with a small number of undo segments in a relatively small undo tablespace - started some transactions (then leave them idle forever after the first change - e.g. they might have come in from a remote database) that made it impossible to free any extents, then did a lot of work to allocate all the extents (but still left a little space in allocated extents for continuting transactions), then started lots of transactions until you hit the error.&lt;br&gt;
&lt;/blockquote&gt;
&lt;br&gt;
And Julian Dyke&#39;s presentation:
&lt;blockquote&gt;
Undo segments are allocated at instance startup.&lt;br&gt;
Undo segments can be added dynamically.&lt;br&gt;
&lt;br&gt;
Each undo segment header contains
&lt;ul&gt;
&lt;li&gt;Pool of free undo extents
&lt;li&gt;Set of undo slots
&lt;/ul&gt;
&lt;br&gt;
One undo slot is allocated to each transaction.&lt;br&gt;
Undo slot contains list of undo extents.&lt;br&gt;
Extents can migrate from one undo segment to another.&lt;br&gt;
Undo slots are used cyclically:
&lt;ul&gt;
&lt;li&gt;remain in header as long as possible
&lt;li&gt;reduces probability of ORA-01555: Snapshot too old
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;br&gt;
With all this in mind I would say that 1000 times higher transaction rate is in this particular case the main reason for the error. Apparently the db is not able to extend its concurrent transactions rate capability fast enough to respond to extended demand. Possible action here could be initial setting of &lt;b&gt;_rollback_segment_count&lt;/b&gt; to a higher value than 12, which are set here.

</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/5911439485554128872/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/5911439485554128872' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5911439485554128872'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5911439485554128872'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/06/ora-01554-transaction-concurrency-limit.html' title='ORA-01554: transaction concurrency limit reached reason:no undo segment found with available slot params:0, 0 :'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-6448204092999134962</id><published>2018-06-18T14:55:00.001+02:00</published><updated>2018-06-19T13:45:19.214+02:00</updated><title type='text'>High latch free on Exadata</title><content type='html'>Today I have investigated an issue with poor performance on some processing. On the production environment the thing have been usually accomplished in some 5 minutes, while on one of test databases it took once 5h to complete.&lt;br&gt;
As this was a RAC on Exadata machine, AWR report was not that much helpful, though immediately was clear the main problem was a &lt;b&gt;latch free&lt;/b&gt; event. The problem was, which latch was responsible here.&lt;br&gt;
The performance chart in OEM did not provide SQL text (as apparently those calls were one-time SQL calls - candidates for dealing with them by setting cursor_sharing to FORCE).&lt;br&gt;
A good step was to call the following query:
&lt;pre&gt;
select name, (misses/decode(gets,0,1,gets) )*100 ratio, 
       (immediate_misses/decode(immediate_gets,0,1,immediate_gets))*100 immediate_ratio,
        spin_gets, wait_time
 from v$latch
where wait_time &gt; 0
order by 2
;
&lt;/pre&gt;
While one can not be 100% sure the query indicates the right latch, it at least gives some clues. This time the only distinctive ratio (around 40%) was &lt;b&gt;Result Cache: RC Latch&lt;/b&gt;. The other one with around 10% was resource manager latch but there the number of gets and misses in total was fairly small, so it was not that interesting.&lt;br&gt;
I&#39;ve looked for this latch name and found few articles on the subject:
&lt;ul&gt;
&lt;li&gt;High &quot;Latch Free&quot; Waits with Contention on &#39;Result Cache: RC Latch&#39; when RESULT_CACHE_MODE = MANUAL on Oracle 12c (Doc ID 2002089.1) on Metalink&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://dban00b.wordpress.com/2015/04/21/311/&quot;&gt;https://dban00b.wordpress.com/2015/04/21/311/&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/6448204092999134962/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/6448204092999134962' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/6448204092999134962'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/6448204092999134962'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/06/high-latch-free-on-exadata.html' title='High latch free on Exadata'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-6130934405608537314</id><published>2018-06-08T13:25:00.000+02:00</published><updated>2018-11-27T10:09:25.507+01:00</updated><title type='text'>RMAN-3008/RMAN-3009 and RMAN-20095</title><content type='html'>Today I had the following problem:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;initially the backup failed with
&lt;pre&gt;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03008: error while performing automatic resync of recovery catalog
RMAN-20095: invalid backup/copy control file checkpoint SCN
&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;every next backup failed with 
&lt;pre&gt;
RMAN-03014: implicit resync of recovery catalog failed
RMAN-03009: failure of partial resync command on default channel at 06/07/2018 04:18:50
RMAN-20095: invalid backup/copy control file checkpoint SCN
&lt;/pre&gt;
&lt;/li&gt;
&lt;/ul&gt;

This is reported on Metalink as &amp;quot;Bug 19209117  RMAN-3008 RMAN-20095 while performing Automatic Resync&amp;quot;&lt;br&gt;
&lt;br&gt;
How to move forward?&lt;br&gt;
I found the 1st backup, which failed, then in this backup log found the place the 1st time the error occurred, then started to uncatalog since that place upward.
Please note the uncataloging has to take place when connected only to the database (i.e. when working only with backaup entries stored within a control file) - otherwise rman will try as a 1st step implicitly resync the catalog which will lead to the error over and over again.
&lt;pre&gt;
change backuppiece &#39;/path_to_backup/cf_YYYYY_c-283029066-20180607-02&#39; uncatalog;
&lt;/pre&gt;
The first call to uncatalog controlfile backup was enough.&lt;br&gt;
In the debug of call to resync catalog during problems there is the following section:
&lt;pre&gt;
DBGRESYNC:     channel default:   file# 0 [11:30:20.805] (resync)
DBGRPC:        krmxrpc - channel default kpurpc2 err=0 db=rcvcat proc=BSPEP.DBMS_RCVCAT.CHECKBACKUPDATAFILE excl: 0
   DBGRCVCAT: addBackupControlfile - Inside dup_val_on_index exception
DBGRESYNC:     channel default: Calling checkBackupDataFile for set_stamp 978149312 set_count 8542 recid 6038 [11:30:20.807] (resync)
DBGRESYNC:     channel default:   file# 0 [11:30:20.807] (resync)
DBGRPC:        krmxrpc - channel default kpurpc2 err=20095 db=rcvcat proc=BSPEP.DBMS_RCVCAT.CHECKBACKUPDATAFILE excl: 129
   DBGRCVCAT: addBackupControlfile - Inside dup_val_on_index exception
   DBGRCVCAT: addBackupControlfile - ckp_scn 3201066972364 ckp_time 07-JUN-18
   DBGRCVCAT: addBackupControlfile - lckp_scn 3201066972565 lckp_time 07-JUN-18
DBGRPC:        krmxrpc - channel default kpurpc2 err=0 db=rcvcat proc=BSPEP.DBMS_RCVCAT.CANCELCKPT excl: 0
   DBGRCVCAT: cancelCkpt - rollback, released all locks

&lt;b&gt;-- here the moment the error 20095 is catched&lt;/b&gt;
DBGPLSQL:     EXITED resync with status ORA--20095 [11:30:20.992]
DBGRPC:       krmxr - channel default returned from peicnt
DBGMISC:      ENTERED krmstrim [11:30:20.992]
DBGMISC:       Trimming message: ORA-06512: at line 3401 [11:30:20.992] (krmstrim)
DBGMISC:        (24) (krmstrim)
DBGMISC:      EXITED krmstrim with status 24 [11:30:20.992] elapsed time [00:00:00:00.000]
DBGRPC:       krmxr - channel default got execution errors (step_60)
DBGRPC:       krmxr - exiting with 1
DBGMISC:      krmqexe: unhandled exception on channel default [11:30:20.992]
DBGMISC:     EXITED krmiexe with status 1 [11:30:20.992] elapsed time [00:00:01:21.889]
[..]
DBGMISC:     error recovery releasing channel resources [11:30:20.992]
DBGRPC:      krmxcr - channel default resetted
DBGMISC:     ENTERED krmice [11:30:20.993]
DBGMISC:      command to be compiled and executed is: cleanup  [11:30:20.993] (krmice)
DBGMISC:      command after this command is: NONE  [11:30:20.993] (krmice)
[..]
DBGMISC:     EXITED krmice [11:30:21.017] elapsed time [00:00:00:00.024]
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03009: failure of resync command on default channel at 06/08/2018 11:30:20
RMAN-20095: invalid backup/copy control file checkpoint SCN
&lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/6130934405608537314/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/6130934405608537314' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/6130934405608537314'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/6130934405608537314'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/06/rman-3008rman-3009-and-rman-20095.html' title='RMAN-3008/RMAN-3009 and RMAN-20095'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-977114894629914262</id><published>2018-05-22T12:49:00.000+02:00</published><updated>2018-05-22T13:58:57.379+02:00</updated><title type='text'>ORA-04030 on a process with large memory requirements</title><content type='html'>Lately I&#39;ve met with the following problem. The database in version 11.2.0.4, the application with an evening batch job. At some point the batch job started to fail constantly, reaching around 4500M of allocated PGA. All the efforts to increase PGA_AGGREGATE_TARGET were void, we increased 1st to 5G (from 3), then to 8, but still failed at pretty much the same allocation.&lt;br&gt;
Top allocations look as follows:
&lt;pre&gt;
TOP 10 MEMORY USES FOR THIS PROCESS
---------------------------------------
70% 3204 MB, 205630 chunks: &quot;pmuccst: adt/record       &quot;  PL/SQL
         koh-kghu call   ds=0x7f2e2ea3c938  dsprt=0xb8c04a0
30% 1356 MB, 87052 chunks: &quot;pl/sql vc2                &quot;  PL/SQL
         koh-kghu call   ds=0x7f2e2ea3c938  dsprt=0xb8c04a0
&lt;/pre&gt;
I&#39;ve found an article on Metalink (ORA-04030 Error For Memory Allocation Type &quot;pmuccst: adt/record&quot; (Doc ID 1513623.1)), but there was stated that this allocation is common for PL/SQL collections and it is not possible to limit it with PGA_AGGREGATE_TARGET (or _pga_max_size) as this is a different allocation bound with the heap of the process and governed with other settings. Similarly pl/sql vc2 allocation is common for local variables like varrays (ORA-04030 Error For Memory Allocation Type &quot;pl/sql vc2&quot; (Doc ID 1315884.1)).&lt;br&gt;
&lt;br&gt;
There are few solutions to the problem above - one is to rewrite the PL/SQL code to replace those large collections with GTT or another is limit collections to fetch only limited number of entries and process cursors in loops.&lt;br&gt;
There is also (as it finally shows up) a possibility to deal with this threshold.&lt;br&gt;
There are the following parameters, which govern this allocation:
&lt;ul&gt;
&lt;li&gt;&lt;b&gt;vm.max_map_count&lt;/b&gt;, which is set to 65530 by default - on OS level&lt;/li&gt;
&lt;li&gt;&lt;b&gt;_use_realfree_heap&lt;/b&gt; - hidden db parameter (in 11.2.0.4 defaults to TRUE) - this one enables the whole feature apparently&lt;/li&gt;
&lt;li&gt;&lt;b&gt;_realfree_heap_pagesize_hint&lt;/b&gt; - hidden db parameter (in 11.2.0.4 defaults to 65536) - this one sets page size, so e.g. with increase to 262144 we can increase the memory allocation to around 16G&lt;/li&gt;
&lt;li&gt;&lt;b&gt;_realfree_heap_pagesize&lt;/b&gt; (since 12c)&lt;/li&gt;
&lt;li&gt;&lt;b&gt;_realfree_heap_max_size&lt;/b&gt; - hidden db parameter (in 11.2.0.4 defaults to 32768) - it is described as  &amp;quot;minimum max total heap size&amp;quot;, in Kbytes - not sure exactly what does that mean and what is controlled by that&lt;/li&gt;
&lt;/ul&gt;
The indication, that this is a problem with realfree heap, is present in the process map dump - in this case the dump displayed exactly maximal allowed number of entries.&lt;br&gt;
&lt;br&gt;
In general it seems the memory available to the process is calculated as vm.max_map_count * _realfree_heap_pagesize_hint, thus one may affect one of multipliers or both of them, where max_map_count controls the number of allocations while realfree_heap_pagesize the amount of memory within one allocation.&lt;br&gt;


</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/977114894629914262/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/977114894629914262' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/977114894629914262'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/977114894629914262'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/05/ora-04030-on-process-with-large-memory.html' title='ORA-04030 on a process with large memory requirements'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-6283536858393362119</id><published>2018-04-13T14:22:00.000+02:00</published><updated>2018-04-13T14:29:39.774+02:00</updated><title type='text'>ORA-12154 while duplicating from active database on RAC</title><content type='html'>A colleague of mine tried to rebuild a standby from some primary database. He prepared, added proper entries to tnsnames.ora on both clusters (primary and standby), then fired duplicate command. When it came to 
&lt;pre&gt;
restore clone from service  &#39;ORCLPRIM&#39; standby controlfile;
&lt;/pre&gt;
the command failed with:
&lt;pre&gt;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of Duplicate Db command at 04/13/2018 12:54:04
RMAN-05501: aborting duplication of target database
RMAN-03015: error occurred in stored script Memory Script
RMAN-06136: ORACLE error from auxiliary database: ORA-17629: Cannot connect to the remote database server
ORA-17627: ORA-12154: TNS:could not resolve the connect identifier specified
ORA-17629: Cannot connect to the remote database server
&lt;/pre&gt;
We checked tnsnames.ora files, connections &#39;standby to primary&#39; and &#39;primary to standby&#39; - all seemed ok.&lt;br&gt;
&lt;br&gt;
Sometimes it is some &#39;invisible&#39; character in tnsnames.ora, which gets in the way, sometimes simple lack of definition. But not this time, so this case is a bit more interesting...&lt;br&gt;
The grid binaries and database binaries have different homes
here and keep different tnsnames.ora files (as there is no shared TNS_ADMIN location).&lt;br&gt;
And the solution was to add the required TNS entries also to the grid home.&lt;br&gt;
My supposition is as follows:
&lt;ul&gt;
&lt;li&gt;the point where the command is issued is the standby instance, to which the script connects through statically registered interface. 
&lt;li&gt;the listener is fired from the grid home (and not db), so its environment is derived from grid, even though in static registration definition the db home is pointed as ORACLE_HOME
&lt;li&gt;thus addition of TNS definitions to the grid home tnsnames.ora helped
&lt;li&gt;I &#39;ve found also that for some static registration entries there was added additional clause ENVS (disclaimer: this parameter in not supported on Windows, any process started by the listener will simply inherit the listener&#39;s environment) in the form
&lt;pre&gt;
(SID_DESC =
      (SID_NAME = orclstb1)
      (ORACLE_HOME = [db home])
      (GLOBAL_DBNAME = orclstb_dgmgrl)
      (ENVS = &quot;TNS_ADMIN=[db home]/network/admin&quot;) 
)
&lt;/pre&gt;
so seems my supposition is correct and this way is another way to get around this issue

&lt;/ul&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/6283536858393362119/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/6283536858393362119' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/6283536858393362119'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/6283536858393362119'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/04/ora-12154-while-duplicating-from-active.html' title='ORA-12154 while duplicating from active database on RAC'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-8362686510532301638</id><published>2018-04-09T14:12:00.001+02:00</published><updated>2018-04-09T14:13:47.560+02:00</updated><title type='text'>Some issue with external table over preprocessor</title><content type='html'>I built an external table based on the output from a preprocessor. Got the following explanation, why it does not work:
&lt;pre&gt;
      Trim whitespace same as SQL Loader
KUP-04027: file name check failed: /u01/app/oracle/nx/datamasking/nx_masking.dat
KUP-04017: OS message: Error 0
KUP-04118: operation &quot;lstat64&quot;, location &quot;skudmicdl&quot;
&lt;/pre&gt;

All seemed to be ok. The script returned the output when called manually. Returned value was 0.&lt;br&gt;
So what was wrong?  The file I called was a link to the real script in fact. Once I dropped the link and copied the script source to the file with name referred within database, the problem vanished.

</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/8362686510532301638/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/8362686510532301638' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/8362686510532301638'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/8362686510532301638'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/04/some-issue-with-external-table-over.html' title='Some issue with external table over preprocessor'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-3094479207988710885</id><published>2018-03-26T10:52:00.001+02:00</published><updated>2018-03-26T10:54:04.754+02:00</updated><title type='text'>kkzifr3g: Encountered error ORA-12057.</title><content type='html'>The solution is as follows:
&lt;pre&gt;
-- as we initially do not know what is happening exactly
alter system set events &#39;12057 trace name errorstack level 3&#39;;
-- and wait until hit the issue again (note the command above dumps only 1st occurrence in a session)

[.. this is from alert.log - this time much more info ..]
Mon Mar 26 10:16:01 2018
kkzifr3g: Encountered error ORA-12057.
Mon Mar 26 10:16:01 2018
Dumping diagnostic data in directory=[cdmp_20180326101601], requested by (instance=1, osid=60555319 (J002)), summary=[abnormal process termination].
Mon Mar 26 10:16:02 2018
Errors in file /u01/app/oracle/diag/rdbms/db1/db1/trace/db1_j005_24117326.trc:
ORA-12057: materialized view or zonemap &quot;TEST&quot;.&quot;MV_DATA1&quot; is invalid and must use complete refresh
[..]

-- and even more data in trace, but we care here mostly about the mv name
-- then ORA-12057 During Fast Refresh of Aggregate Materialized View (Doc ID 1399651.1)

-- to clean up
alter system set events &#39;12057 trace name context off&#39;;
&lt;/pre&gt;

</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/3094479207988710885/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/3094479207988710885' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3094479207988710885'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3094479207988710885'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/03/kkzifr3g-encountered-error-ora-12057.html' title='kkzifr3g: Encountered error ORA-12057.'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-3087602478941183748</id><published>2018-03-22T10:10:00.001+01:00</published><updated>2018-03-22T10:10:20.130+01:00</updated><title type='text'>Fractured block found during backing up datafile</title><content type='html'>&lt;pre&gt;
{hostname}, Hex dump of (file 75, block 87980) in trace file /oracle/diag/rdbms/db1/db1/trace/db1_ora_23614.trc
Corrupt block relative dba: 0x12c157ac (file 75, block 87980)
Fractured block found during backing up datafile
Data in bad block:
 type: 6 format: 2 rdba: 0x12c157ac
 last change scn: 0x02d7.7dc0c4bc seq: 0x2 flg: 0x04
 spare1: 0x0 spare2: 0x0 spare3: 0x0
 consistency value in tail: 0xb1a20602
 check value in block header: 0xc892
 computed block checksum: 0x67fa
Reread of blocknum=87980, file=+DATA/db1/datafile/file1.343.956407117. found valid data : 

dbv file=+DATA/db1/datafile/file1.343.956407117 blocksize=8192 start=87980 end=87981 userid=sys/blbla

DBVERIFY: Release 11.2.0.4.0 - Production on Thu Mar 22 10:04:33 2018

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

DBVERIFY - Verification starting : FILE = +DATA/db1/datafile/file1.343.956407117


DBVERIFY - Verification complete

Total Pages Examined         : 2
Total Pages Processed (Data) : 0
Total Pages Failing   (Data) : 0
Total Pages Processed (Index): 2
Total Pages Failing   (Index): 0
Total Pages Processed (Other): 0
Total Pages Processed (Seg)  : 0
Total Pages Failing   (Seg)  : 0
Total Pages Empty            : 0
Total Pages Marked Corrupt   : 0
Total Pages Influx           : 0
Total Pages Encrypted        : 0
Highest block SCN            : 0 (0.0)
&lt;/pre&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/3087602478941183748/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/3087602478941183748' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3087602478941183748'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3087602478941183748'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/03/fractured-block-found-during-backing-up.html' title='Fractured block found during backing up datafile'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-8653057575258618760</id><published>2018-03-05T13:51:00.001+01:00</published><updated>2018-03-05T13:52:56.040+01:00</updated><title type='text'>Restricted session</title><content type='html'>&lt;pre&gt;
-- at startup
startup restrict;

-- on running instance
alter system enable restricted session;

System altered.

-- to disable
alter system disable restricted session;

-- to check
select logins from v$instance; 

LOGINS
----------
RESTRICTED

&lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/8653057575258618760/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/8653057575258618760' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/8653057575258618760'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/8653057575258618760'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/03/restricted-session.html' title='Restricted session'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-7775867951510492663</id><published>2018-02-23T09:42:00.002+01:00</published><updated>2018-02-23T09:42:16.571+01:00</updated><title type='text'>ROLL_INVALID_MISMATCH (external link)</title><content type='html'>Great article on one of reasons to not share cursor &lt;a href=&quot;https://magnusjohanssontuning.wordpress.com/2016/04/22/cursors-not-shared-due-to-roll_invalid_mismatch/&quot;&gt;https://magnusjohanssontuning.wordpress.com/2016/04/22/cursors-not-shared-due-to-roll_invalid_mismatch/&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/7775867951510492663/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/7775867951510492663' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/7775867951510492663'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/7775867951510492663'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/02/rollinvalidmismatch-external-link.html' title='ROLL_INVALID_MISMATCH (external link)'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-5944550482485963859</id><published>2018-02-23T09:39:00.004+01:00</published><updated>2018-02-23T09:39:47.481+01:00</updated><title type='text'>Password hash explained (external link)</title><content type='html'>An excellent article on password hashing in Oracle &lt;a href=&quot;https://www.trustwave.com/Resources/SpiderLabs-Blog/Changes-in-Oracle-Database-12c-password-hashes/?page=1&amp;year=0&amp;month=0&quot;&gt;https://www.trustwave.com/Resources/SpiderLabs-Blog/Changes-in-Oracle-Database-12c-password-hashes/?page=1&amp;year=0&amp;month=0&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/5944550482485963859/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/5944550482485963859' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5944550482485963859'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5944550482485963859'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/02/password-hash-explained-external-link.html' title='Password hash explained (external link)'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-1133048716546365735</id><published>2018-02-22T09:58:00.001+01:00</published><updated>2018-02-22T09:58:12.577+01:00</updated><title type='text'>Insightful article on connections db terminated by firewalls (external link)</title><content type='html'>Very insightful article on why/when firewalls throw connections &lt;a href=&quot;https://li555li.blogspot.se/2014/09/&quot;&gt;https://li555li.blogspot.se/2014/09/&lt;/a&gt;.&lt;br&gt;
In short - to prevent this one have to set SQLNET.EXPIRE_TIME to {timeout on firewall}/2-1 in minutes.</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/1133048716546365735/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/1133048716546365735' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/1133048716546365735'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/1133048716546365735'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/02/insightful-article-on-connections-db.html' title='Insightful article on connections db terminated by firewalls (external link)'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-3934647903431770538</id><published>2018-01-31T12:33:00.000+01:00</published><updated>2018-01-31T12:33:23.266+01:00</updated><title type='text'>How to find a time for the latest DML on a table</title><content type='html'>Lately I&#39;ve got such question from a co-worker. I looked around a bit and here are the findings:
&lt;ul&gt;
&lt;li&gt;ORA_ROWSCN pseudocolumn - seems to be the most versatile solution here - the maximal value of ORA_ROWSCN would definitely point the time of the last modification for any table.&lt;/li&gt;
&lt;li&gt;VERSIONS_ENDSCN &lt;a href=&quot;https://docs.oracle.com/cd/E11882_01/appdev.112/e41502/adfns_flashback.htm#ADFNS01009&quot;&gt;https://docs.oracle.com/cd/E11882_01/appdev.112/e41502/adfns_flashback.htm#ADFNS01009&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;dba_tab_modifications - this is the table, which keeps number of DML operations since the last statistics collection. Thus it may be used to find the approx. time of a last modification assuming it is done after the latest stats collection, but it has of course a number of limitations &lt;/li&gt;
&lt;/ul&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/3934647903431770538/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/3934647903431770538' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3934647903431770538'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3934647903431770538'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/01/how-to-find-time-for-latest-dml-on-table.html' title='How to find a time for the latest DML on a table'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-8210236860749046549</id><published>2018-01-11T15:35:00.003+01:00</published><updated>2018-01-12T17:48:00.630+01:00</updated><title type='text'>Change of DB_UNIQUE_NAME in a database</title><content type='html'>Today I created a new database. I created with usage of Oracle Universal Installer graphic interface. I did not find the switch for advanced configuration, where I could change some parameters along the installation phase, so I was left over with this what gives the basic configuration for Server-class database option. May be I missed some tab or checkbox, does not matter.&lt;br&gt;
Now the starting point is to have a 12c standalone database registered in clusterware.&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;the simple change in the spfile ends with &lt;pre&gt;
SQL&gt; alter system set db_unique_name=&#39;pizmak_node3&#39; scope=spfile;
alter system set db_unique_name=&#39;pizmak_node3&#39; scope=spfile
*
ERROR at line 1:
ORA-32017: failure in updating SPFILE
ORA-65500: could not modify DB_UNIQUE_NAME, resource exists
&lt;/pre&gt;&lt;/li&gt;
&lt;li&gt;so I found &quot;How to change the DB_UNIQUE_NAME in a RAC database (Doc ID 1604421.1)&quot;, and remove the database from clusterware, but then &lt;pre&gt;
SQL&gt; startup mount
ORA-01078: failure in processing system parameters
ORA-01565: error in identifying file &#39;+DATA/pizmak/spfilepizmak.ora&#39;
ORA-17503: ksfdopn:2 Failed to open file +DATA/pizmak/spfilepizmak.ora
ORA-15056: additional error message
ORA-17503: ksfdopn:2 Failed to open file +DATA/pizmak/spfilepizmak.ora
ORA-15173: entry &#39;spfilepizmak.ora&#39; does not exist in directory &#39;pizmak&#39;
ORA-06512: at line 4

&lt;/pre&gt;
Apparently the oratab entry was removed with the srvctl remove database command&lt;/li&gt;
&lt;li&gt;so I found &quot;Alert Log Error ORA-17503 ORA-15173 After Deleting Database. (Doc ID 1900471.1)&quot;&lt;/li&gt;
&lt;li&gt;so I looked at $ORACLE_HOME/dbs and found pfile with SPFILE pointing to ASM location and put it aside&lt;/li&gt;
&lt;li&gt;after some time I discovered true reason - initially spfile was located in +DATA/PIZMAK/ (possibly on some stage of db installation), but eventually the location was +DATA/PIZMAK/PARAMETERFILE&lt;/li&gt;
&lt;li&gt;so I used the pfile in $ORACLE_BASE/admin/pizmak/pfile/, which is put there during installation&lt;/li&gt;
&lt;li&gt;so I started with startup nomount pfile=my_pfile_copy - this pfile had already db_unique_name changed to the one I wanted to, no changes to db_create_file_dest (as it would point to &lt;/li&gt;
&lt;li&gt;I&#39;ve got info 12c is able to move files online to another location, so &lt;pre&gt;
SQL&gt; select file_id||&#39;:&#39;||file_name from dba_data_files;

FILE_ID||&#39;:&#39;||FILE_NAME
--------------------------------------------------------------------------------
6:+DATA/PIZMAK/DATAFILE/users.302.965122931
4:+DATA/PIZMAK/DATAFILE/undotbs1.303.965122931
3:+DATA/PIZMAK/DATAFILE/sysaux.300.965122739
1:+DATA/PIZMAK/DATAFILE/system.314.965139835

alter database move datafile 1;
alter database move datafile 3;
alter database move datafile 4;
alter database move datafile 6;

SQL&gt; select file_id||&#39;:&#39;||file_name from dba_data_files;

FILE_ID||&#39;:&#39;||FILE_NAME
--------------------------------------------------------------------------------
6:+DATA/PIZMAK_NODE3/DATAFILE/users.303.965140667
3:+DATA/PIZMAK_NODE3/DATAFILE/sysaux.301.965140607
4:+DATA/PIZMAK_NODE3/DATAFILE/undotbs1.300.965140655
1:+DATA/PIZMAK_NODE3/DATAFILE/system.314.965139835
&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;now logs &lt;pre&gt;
SQL&gt; select member from v$logfile;

MEMBER
--------------------------------------------------------------------------------
+DATA/PIZMAK/ONLINELOG/group_3.310.965122991
+DATA/PIZMAK/ONLINELOG/group_3.311.965122991
+DATA/PIZMAK/ONLINELOG/group_2.308.965122991
+DATA/PIZMAK/ONLINELOG/group_2.309.965122991
+DATA/PIZMAK/ONLINELOG/group_1.306.965122991
+DATA/PIZMAK/ONLINELOG/group_1.307.965122991

SQL&gt; select GROUP#, SEQUENCE#, MEMBERS, STATUS from v$log;

    GROUP#  SEQUENCE#    MEMBERS STATUS
---------- ---------- ---------- ------------------------------------------------
         1          7          1 INACTIVE
         2          8          2 INACTIVE
         3          9          2 CURRENT


alter database drop logfile group 1;
alter database add logfile group 1 size 512m;
-- here in alert log (as this was 1st log file on REDO) an error
-- Thu Jan 11 14:41:29 2018
-- ERROR: failed to establish dependency between database pizmak_node3 and diskgroup resource ora.REDO.dg


alter database drop logfile group 2;
alter database add logfile group 2 size 512m;
-- no more errors as the structure already exists

alter system switch logfile;
alter system switch logfile;

alter database drop logfile group 3;
alter database add logfile group 3 size 512m;

SQL&gt; select member from v$logfile;

MEMBER
------------------------------------------------------------------------------------------------------------------------
+REDO/PIZMAK_NODE3/ONLINELOG/group_3.275.965141729
+REDO/PIZMAK_NODE3/ONLINELOG/group_2.274.965141165
+REDO/PIZMAK_NODE3/ONLINELOG/group_1.256.965140887


&lt;/pre&gt;
I have to double members yet
&lt;/li&gt;
&lt;li&gt;now spfile
&lt;pre&gt;
create spfile=&#39;+DATA&#39; from pfile=&#39;/oracle/m010162/init.ora.011201894952&#39;;
-- and change in initpizmak.ora
-- SPFILE=&#39;+DATA/pizmak_node3/parameterfile/spfile.311.965142657&#39;
!cp initpizmak.ora $ORACLE_HOME/dbs/
&lt;/pre&gt;
&lt;/li&gt;

&lt;li&gt;to move temporary tablespace I just created a new one and switched default temporary tablespace to it 
&lt;pre&gt;
create temporary tablespace temp2 tempfile size 128m autoextend on next 128m maxsize 16g;
alter database default temporary tablespace temp2;

-- then as I wanted temporary tablespace named TEMP I did that once again
create temporary tablespace temp tempfile size 128m autoextend on next 128m maxsize 16g;
alter database default temporary tablespace temp;

SQL&gt; select file_name from dba_temp_files;

FILE_NAME
------------------------------------------------------------------------------------------------------------------------
+DATA/PIZMAK_NODE3/TEMPFILE/temp.312.965143967

&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;to move control files I used asmcmd
&lt;ol&gt;
&lt;li&gt;change control_files parameter to new location with scope spfile&lt;/li&gt;
&lt;li&gt;shutdown immediate&lt;/li&gt;
&lt;li&gt;copy or move control files to the new location in asmcmd (with cp one have to specify the name of the target file, but without instance/revision? number) &lt;/li&gt;
&lt;li&gt;start the db&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;


&lt;/ul&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/8210236860749046549/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/8210236860749046549' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/8210236860749046549'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/8210236860749046549'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/01/change-of-dbuniquename-in-database.html' title='Change of DB_UNIQUE_NAME in a database'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-5789953355875467403</id><published>2018-01-02T09:06:00.001+01:00</published><updated>2018-01-03T20:28:05.529+01:00</updated><title type='text'>ORA-27303: additional information: startup egid = 5003 (asmadmin), current egid = 5000 (oinstall)</title><content type='html'>I&#39;ve got the following info on several occasions:
&lt;pre&gt;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
ORA-27140: attach to post/wait facility failed
ORA-27300: OS system dependent operation:invalid_egid failed with status: 1
ORA-27301: OS failure message: Operation not permitted
ORA-27302: failure occurred at: skgpwinit6
ORA-27303: additional information: startup egid = 5003 (asmadmin), current egid = 5000 (oinstall)
&lt;/pre&gt;

It seems the problem arises from wrong permissions on oracle binary files. More explanations here - &lt;a href=&quot;https://asanga-pradeep.blogspot.dk/2012/06/ora-27303-additional-information.html&quot;&gt;https://asanga-pradeep.blogspot.dk/2012/06/ora-27303-additional-information.html&lt;/a&gt;.</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/5789953355875467403/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/5789953355875467403' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5789953355875467403'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/5789953355875467403'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2018/01/ora-27303-additional-information.html' title='ORA-27303: additional information: startup egid = 5003 (asmadmin), current egid = 5000 (oinstall)'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-7444703988023566173</id><published>2017-11-24T14:49:00.003+01:00</published><updated>2017-11-24T14:49:46.724+01:00</updated><title type='text'>Hinty (external links)</title><content type='html'>&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;http://dbaora.com/with-clause-and-hints-materialize-and-inline/&quot;&gt;MATERIALIZE and INLINE&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/7444703988023566173/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/7444703988023566173' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/7444703988023566173'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/7444703988023566173'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2017/11/hinty-external-links.html' title='Hinty (external links)'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-3931739653049741149</id><published>2017-10-24T14:20:00.003+02:00</published><updated>2017-10-24T14:20:57.874+02:00</updated><title type='text'>Calibrating I/O</title><content type='html'>Today a colleague of mine started the short calibration code:
&lt;pre class=&quot;brush:sql&quot;&gt;
set serveroutput on
declare 
 l_latency number;
 l_iops    number;
 l_mbps    number;
begin
 dbms_resource_manager.calibrate_io(num_physical_disks=&gt;6, max_latency=&gt;12, max_iops=&gt;l_iops, max_mbps=&gt;l_mbps, actual_latency=&gt;l_latency);
 dbms_output.put_line(&#39;max_iops=&#39;||l_iops||&#39;   max_mbps=&#39;||l_mbps||&#39;  actual_latency=&#39;||l_latency);
end;
/
&lt;/pre&gt;
... and after some 10 minutes got 
&lt;pre&gt;
Tue Oct 24 13:26:50 2017
Errors in file /opt/oracle/diag/rdbms/xxx/xxx/trace/xxx_cs01_10660.trc  (incident=60493):
ORA-04031: unable to allocate 1049112 bytes of shared memory (&quot;shared pool&quot;,&quot;unknown object&quot;,&quot;sga heap(1,1)&quot;,&quot;ksfdcamem shared I/O read buffer&quot;)
Incident details in: /opt/oracle/diag/rdbms/xxx/xxx/incident/incdir_60493/xxx_cs01_10660_i60493.trc
Use ADRCI or Support Workbench to package the incident.
See Note 411.1 at My Oracle Support for error and packaging details.
Errors in file /opt/oracle/diag/rdbms/xxx/xxx/trace/xxx_cs01_10660.trc:
ORA-04031: unable to allocate 1049112 bytes of shared memory (&quot;shared pool&quot;,&quot;unknown object&quot;,&quot;sga heap(1,1)&quot;,&quot;ksfdcamem shared I/O read buffer&quot;)
Errors in file /opt/oracle/diag/rdbms/xxx/xxx/trace/xxx_cs01_10660.trc:
ORA-04031: unable to allocate 1049112 bytes of shared memory (&quot;shared pool&quot;,&quot;unknown object&quot;,&quot;sga heap(1,1)&quot;,&quot;ksfdcamem shared I/O read buffer&quot;)
Tue Oct 24 13:26:51 2017
Dumping diagnostic data in directory=[cdmp_20171024132651], requested by (instance=1, osid=10660 (CS01)), summary=[incident=60493].
Tue Oct 24 13:26:51 2017
Sweep [inc][60493]: completed
Sweep [inc2][60493]: completed
&lt;/pre&gt;
&lt;br&gt;
While there is not much in the subject on Metalink, there exists an &lt;a href=&quot;https://ronr.blogspot.dk/2012/12/resource-manager-io-calibration-and-ora.html&quot;&gt;excellent blog article&lt;/a&gt;.
I may add to it the following:
&lt;ul&gt;
&lt;li&gt;1st idea just to flush shared pool did not help - apparently as the system was in use initially and the load taken off just prior to calibration and many allocations already took place&lt;/li&gt;
&lt;li&gt;2nd idea was to restart and that was enough - when run immediately after start, the process went smoothly.&lt;/li&gt;
&lt;li&gt;after success we &#39;ve got
&lt;pre&gt;
Tue Oct 24 13:42:51 2017
Shared IO Pool defaulting to 512MB. Trying to get it from Buffer Cache for process 12832.
&lt;/pre&gt;
Now it seems quite obvious that even with shared pool allocating 2G after a while there is no such amount of free memory in 1M chunks - even in reserved shared pool part (shared_pool_reserved_size defaults to 5% of the shared pool total) &lt;/li&gt;
&lt;/ul&gt;

</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/3931739653049741149/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/3931739653049741149' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3931739653049741149'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/3931739653049741149'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2017/10/calibrating-io.html' title='Calibrating I/O'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-2207137103331718317</id><published>2017-10-06T08:24:00.004+02:00</published><updated>2017-10-06T08:24:40.054+02:00</updated><title type='text'>Problem on a SELECT through a db link</title><content type='html'>Not my adventure entirely, yet interesting.&lt;br&gt;
There exists a query in the shape INSERT ... SEELECT. SELECT is done on the view. The view returns huge set of data (if called without conditions). But there is a condition, thus the whole query in normal circumstances should be executed in a fraction of a second.&lt;br&gt;
But yesterday out of nothing the plan changed. It changed several times in the past, but then it was enough to inject through a sql profile the hint optimizer_features_enable(&#39;10.2.0.4&#39;) to smooth things out. So developers injected it in a hard way - to the code itself. But yesterday the plan changed again despite the hint, and the change was based on the full view generation and remote site trying to push whole that mass of data back to the local site to filter through the condition - the local database waited on TCP Socket wait event, waiting for any data, while the remote database burnt CPU trying to produce full view set (which was so huge effort that it completely choked). And any action on the &#39;local&#39; side did not fix the problem.&lt;br&gt;
After some time spend on struggling with the issue the final solution was as follows:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;on the local site - optimizer_features_enable(&#39;10.2.0.4&#39;) and rule injected by sql profile
&lt;li&gt;on remote site - optimizer_features_enable(&#39;10.2.0.4&#39;) and rule injected by sql profile to the view
&lt;/ul&gt;
It is clear that rule and optimizer_features_enable are exclusive - on the Metalink though somewhere was a note that OPAQUE_TRANSFORM may be disabled by an event or optimizer_features_enable or rule hints. My guess is the rule hint now disabled OPAQUE_TRANSFORM (which is passed by default), which allowed for the plan control on the remote site and there optimizer_features_enable(&#39;10.2.0.4&#39;) was used.</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/2207137103331718317/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/2207137103331718317' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/2207137103331718317'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/2207137103331718317'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2017/10/problem-on-select-through-db-link.html' title='Problem on a SELECT through a db link'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4238388508729730478.post-4647246146710128352</id><published>2017-08-09T12:21:00.004+02:00</published><updated>2017-08-09T12:21:54.981+02:00</updated><title type='text'>RMAN-20033: control file SEQUENCE# too low</title><content type='html'>Most probably the true reason for that error to occur is a race condition between 2 concurrent backup processes - for example one full backup and one archivelog backup with autobackup enabled.
Thus both would synchronize with RMAN catalog and one of them may try to register controlfile being older than the last one already registered by the 2nd process.&lt;br&gt;
&lt;br&gt;
On Metalink they suggests a weird solution for this (Rman-20033 Control File Sequence# Too Low (Doc ID 342696.1)) to recreate the controlfile or RMAN catalog - it is possible it may be needed in some scenario, but I guess the best way first is simply rerun the backup ensuring there is only one backup process running.</content><link rel='replies' type='application/atom+xml' href='http://remigium.blogspot.com/feeds/4647246146710128352/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/4238388508729730478/4647246146710128352' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/4647246146710128352'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4238388508729730478/posts/default/4647246146710128352'/><link rel='alternate' type='text/html' href='http://remigium.blogspot.com/2017/08/rman-20033-control-file-sequence-too-low.html' title='RMAN-20033: control file SEQUENCE# too low'/><author><name>rems</name><uri>http://www.blogger.com/profile/11711851337018472556</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>