Monday, May 25, 2009
Errors while installing Oracle9i in Redhat 5.3 (libstdc++-libc6.1-1.so.2)
$ Initializing Java Virtual Machine from /tmp/OraInstall2009-05-09_06-44-18AM/jre/bin/java. Please wait...
/tmp/OraInstall2009-05-09_06-44-18AM/jre/bin/i386/native_threads/java: error while loading shared libraries: libstdc++-libc6.1-1.so.2: cannot open shared object file: No such file or directory
When check for libstdc++- library, I found the following to be installed by default on RH 5.3:
[root@alps tmp]# rpm -qa |grep libstdc++-
libstdc++-4.1.2-44.el5
libstdc++-devel-4.1.2-44.el5
compat-libstdc++-296-2.96-138
compat-libstdc++-33-3.2.3-61
[root@alps tmp]#
Looks like it is looking for libstdc++-lib6.1-1.
When I did the following the initial error message disappeared:
# cd /usr/lib
# ln -s libstdc++-3-libc6.2-2-2.10.0.so libstdc++-libc6.1-1.so.2
Then I got the following error:
$ ./runInstaller
$ Initializing Java Virtual Machine from /tmp/OraInstall2009-05-09_06-50-11AM/jre/bin/java. Please wait...
Error occurred during initialization of VM
Unable to load native library: /tmp/OraInstall2009-05-09_06-50-11AM/jre/lib/i386/libjava.so: symbol __libc_wait, version GLIBC_2.0 not defined in file libc.so.6 with link time reference
When applied the oracle patch: 3006854 - it fixed it:
[root@alps 3006854]# sh rhel3_pre_install.sh
Applying patch...
Ensuring permissions are correctly set...
Done.
Patch successfully applied
[root@alps 3006854]#
Tuesday, May 19, 2009
Adaptive/Intelligent Cursor Sharing in 11g - turning-off
- Optimizer peeks value for the bind on initial parse
- Initial value of the bind determines the plan
- Same plan is used/shared regardless of future bind values
- One plan not always appropriate and optimal for all bind values and results in following problems or side-effects:
- Instability issues
- Unhappy end users
Adaptive Cursor Sharing address this problem. it shares execution plans ONLY when bind values are "equivalent" - means if it doesn't result in performance degradation. This is the default behavior in Oracle11g.
More information on adaptive cursor sharing can be found at: http://optimizermagic.blogspot.com/2009/04/update-on-adaptive-cursor-sharing.html - The intention of this post is not to talk about this feature - but how to turn-off this default behavior. I can't really think of a reason why anyone would like to turn this feature off, but it is possible, if at all we need it for some reason. This can be achieved by using NO_BIND_AWARE hint.
I believe this hint is meant to be an alternative for using the hidden parameter - _optim_peek_user_binds=false which is used to turn-off bind peeking.
Here is the example:
The default behavior:
SQL> variable lv_id number;
SQL> exec :lv_id :=100;
PL/SQL procedure successfully completed.
SQL> Select count(*) from sh.sales where prod_id = :lv_id;
COUNT(*)
----------
0
----if the bind values are peeked, we would see records in V$SQL_CS_STATISTICS:
SQL> Select address, child_number, peeked, executions from v$sql_cs_statistics;
ADDRESS CHILD_NUMBER P EXECUTIONS
-------- ------------ - ----------
34C54884 0 Y 1
Now, let's turn off bind peeking.
======================
SQL> alter system flush shared_pool;
System altered.
SQL> exec :lv_id :=1000;
PL/SQL procedure successfully completed.
SQL> Select /*+ NO_BIND_AWARE */ count(*) from sh.sales where prod_id = :lv_id;
COUNT(*)
----------
0
----With the above hint, the sql is not bind aware, therefore we don't see any records in v$SQL_CS_STATISTICS view.
SQL> Select address, child_number, peeked, executions from v$sql_cs_statistics;
no rows selected
SQL>
I guess, this is a better and elegant way to turn-off bind-peeking at the SQL level instead of turning-off bind-peeking at the instance level using the hidden parameter - _optim_peek_user_binds. Again, this parameter is typically used to prevent the side/ill-effects of bind-peeking and the same is now (with 11g) obviated with the introduction of Adaptive Cursor Sharing feature in 11g.
BTW, this hint is available in 11.1.0.7.
Monday, May 18, 2009
Oracle11g CRS new command
[root@racnode01 bin]# ./crsctl check cluster
racnode01 ONLINE
racnode02 ONLINE
[root@racnode01 bin]#
Of course, we could very well use "crsstat" command to determine the status of CRS on non-local nodes - but not straight-forward and simple.
Wednesday, April 22, 2009
Oracle Support Bug Status Codes...
10 - Description Phase: Development is requesting more information.
16 - Support bug screening: Bug is being reviewed by our Bug Diagnostics group.
11 - Code Bug (Response/Resolution): Bug is being worked by Development.
30 - Additional Information Requested: Bug is being worked by Support and/or more information was requested by Development.
37 - To Filer for Review/Merge Required: Bug has been fixed but the patch will be merged into the next patchset.
80 - Development to Q/A: Bug is being regression tested for future release.
81 - Q/A to Dev/Patch or Workaround Avble: Patch released via Metalink.
90 - Closed, Verified by Filer: Bug has been fixed and is closed.
91 - Closed, Could Not Reproduce: Bug is closed as not reproducible.
92 - Closed, Not a Bug: Bug is closed as not a bug (not reproducible or setup issue).
93 - Closed, Not Verified by Filer: Bug has been fixed and is closed.
95 - Closed, Vendor OS Problem: Bug is closed as an OS problem.
96 - Closed, Duplicate Bug: Bug is closed as a duplicate bug.
Friday, April 17, 2009
ORA-38856 - while opening a cloned RAC database
SYS@NETFRD1> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-38856: cannot mark instance UNNAMED_INSTANCE_2 (redo thread 2) as enabled
The fix was to use the undocumented parameter - _no_recovery_through_resetlogs=TRUE to open the database. I guess this is one of those scenarios where Oracle suggests using this undocumented/unsupported parameter. Here is what I did to get pass the problem:
1. Shutdown;
2. Startup mount (with the parameter _no_recovery_through_resetlogs=TRUE set in init.ora)
3. Open the database with RESETLOGS;
SYS@NETFRD1> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-38856: cannot mark instance UNNAMED_INSTANCE_2 (redo thread 2) as enabled
SYS@NETFRD1> shutdown immediate;
ORA-01109: database not open
Database dismounted.
ORACLE instance shut down.
SYS@NETFRD1> !vi /tmp/init$ORACLE_SID.ora
SYS@NETFRD1> startup mount pfile=/tmp/init$ORACLE_SID.ora
ORACLE instance started.
Total System Global Area 1577058304 bytes
Fixed Size 2084232 bytes
Variable Size 385876600 bytes
Database Buffers 1174405120 bytes
Redo Buffers 14692352 bytes
Database mounted.
SYS@NETFRD1> alter database open resetlogs;
Database altered.
Monday, February 16, 2009
ORA-39006, ORA-39065,ORA-25306,ORA-39079 while exporting using EXPDP
ORA-39006: internal error
ORA-39065: unexpected master process exception in DISPATCH
ORA-39079: unable to enqueue message DG,KUPC$S_3_20090213124234,MCP, ,1,Y
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 86
ORA-06512: at "SYS.KUPC$QUE_INT", line 924
ORA-25306: Cannot connect to buffered queue's owner instance
ORA-39097: Data Pump job encountered unexpected error -39079
ORA-39065: unexpected master process exception in KUPC$QUEUE_INT.PUT_STATUS
ORA-39079: unable to enqueue message DG,KUPC$S_3_20090213124234,MCP, ,1,Y
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 86
ORA-06512: at "SYS.KUPC$QUE_INT", line 924
ORA-25306: Cannot connect to buffered queue's
This seems to be a bug but couldn't find any published information in metalink. Setting the value for the parameters aq_tm_processes to 4 from a value of 0 worked. There are several other databases with the default setting of 0, but they don't seem to have problems with expdp. Hopefully, this will have a fix in 10.2.0.5.
Hope this helps others who encounter similar errors.
Sunday, February 8, 2009
Bypassing/ignoring or skipping ORA-1555 errors
Example:
In Session 1:
chandra@AEDB01:11g> Select Distinct phone from acs_emp;
PHONE
--------------------
972-500-8999
1 row selected.
In Session 2:
chandra@AEDB01:11g> Select /*+ scn_ascending */ * from acs_emp;
While this session is in progress, I have updated the phone column:
Back in Session 1:
chandra@AEDB01:11g> update acs_emp set phone='888-888-8888';
100000 rows updated.
chandra@AEDB01:11g> commit;
Commit complete.
Back to Session 2 where our select was in progress: You will notice that we got data which was NOT consistent with the data which existed at the point in time when the query was initiated. The SCN got changed in the middle - meaning inconsistent / questionable data!. Without the above mentioned HINT, it wouldn't have been possible to see such inconsistent result set. Hopefully, this hint is a well-intentioned one.
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
650831 972-500-8999
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888
652088 888-888-8888