Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
A potential bug (infinite loop) in Oracle: querying v$access
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  Messages 1 - 25 of 33 - Collapse all  -  Translate all to Translated (View all originals)   Newer >
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Peter Teoh  
View profile  
 More options Jan 23 2008, 12:23 am
Newsgroups: comp.databases.oracle.server
From: Peter Teoh <htmldevelo...@gmail.com>
Date: Tue, 22 Jan 2008 21:23:46 -0800 (PST)
Local: Wed, Jan 23 2008 12:23 am
Subject: A potential bug (infinite loop) in Oracle: querying v$access
Making a long query:

select distinct name from all_source;
.......
SYS_YOID0000052452$
......
3196 rows selected.

Ok no problem.

select distinct owner from v$access
SQL> /
select distinct owner from v$access
                           *
ERROR at line 1:
ORA-01013: user requested cancel of current operation

I had to terminate it as it become non-terminating.

"select owner from v$access" returns a mere 193 rows, and it cannot
sort it?

I suspect there is exists an infinite loop somewhere.

This was attempted on 10gR2, 11gR1 and both had the same problem.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Vladimir M. Zakharychev  
View profile  
 More options Jan 23 2008, 1:55 am
Newsgroups: comp.databases.oracle.server
From: "Vladimir M. Zakharychev" <vladimir.zakharyc...@gmail.com>
Date: Tue, 22 Jan 2008 22:55:05 -0800 (PST)
Local: Wed, Jan 23 2008 1:55 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 9:23 am, Peter Teoh <htmldevelo...@gmail.com> wrote:

9.2.0.8/Win32 doesn't have this issue: select distinct owner from v
$access returns 3 rows instantaneously as expected. I don't have a
10gR2 or 11gR1 instance handy to test, but if this issue is definitely
reproducible on these releases (maybe on certain platforms only,) I
suggest that you open a SR with Oracle Support for it as it looks like
a regression or platform-dependent bug.

Regards,
   Vladimir M. Zakharychev
   N-Networks, makers of Dynamic PSP(tm)
   http://www.dynamicpsp.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
shakespeare  
View profile  
 More options Jan 23 2008, 3:40 am
Newsgroups: comp.databases.oracle.server
From: "shakespeare" <what...@xs4all.nl>
Date: Wed, 23 Jan 2008 09:40:06 +0100
Local: Wed, Jan 23 2008 3:40 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

"Vladimir M. Zakharychev" <vladimir.zakharyc...@gmail.com> schreef in
bericht
news:38ae4253-4519-44ed-bbbb-618154c440e8@d70g2000hsb.googlegroups.com...

Select distinct name from all_source: 6194 rows returned
Select distinct owner from v$access: 13 rows returned.
10.1.0.5.0 on Windows: no errors.

Shakespeare


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Peter Teoh  
View profile  
 More options Jan 23 2008, 7:32 am
Newsgroups: comp.databases.oracle.server
From: Peter Teoh <htmldevelo...@gmail.com>
Date: Wed, 23 Jan 2008 04:32:32 -0800 (PST)
Local: Wed, Jan 23 2008 7:32 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
I tried on Oracle9iR2 (Fedora Core Linux 5) no problem, it returned
immediately - no hanging.

But for the earlier post - I forgotten to mentioned they are on Fedora
Core 7.

Thanks.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steve Howard  
View profile  
 More options Jan 23 2008, 7:50 am
Newsgroups: comp.databases.oracle.server
From: Steve Howard <stevedhow...@gmail.com>
Date: Wed, 23 Jan 2008 04:50:09 -0800 (PST)
Local: Wed, Jan 23 2008 7:50 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 7:32 am, Peter Teoh <htmldevelo...@gmail.com> wrote:

> I tried on Oracle9iR2 (Fedora Core Linux 5) no problem, it returned
> immediately - no hanging.

> But for the earlier post - I forgotten to mentioned they are on Fedora
> Core 7.

> Thanks.

10.2.0.3 32 bit on RHAT returned immediately, as did 10.2.0.3 64 bit
on AIX 5.2 64 bit.

Regards,

Steve


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Charles Hooper  
View profile  
 More options Jan 23 2008, 7:58 am
Newsgroups: comp.databases.oracle.server
From: Charles Hooper <hooperc2...@yahoo.com>
Date: Wed, 23 Jan 2008 04:58:09 -0800 (PST)
Local: Wed, Jan 23 2008 7:58 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 12:23 am, Peter Teoh <htmldevelo...@gmail.com> wrote:

I was able to reproduce this problem on Oracle 10.2.0.2 with the
Oracle October 2006 CPU on 64 bit Windows 2003.

From the udump trace file:
ksedmp: internal or fatal error
ORA-07445: exception encountered: core dump [ACCESS_VIOLATION]
[__intel_new_memcpy+610] [PC:0x3236532] [ADDR:0x0] [UNABLE_TO_READ] []
Current SQL statement for this session:
select distinct owner from v$access
----- Call Stack Trace -----
calling              call     entry                argument values in
hex
location             type     point                (? means dubious
value)
-------------------- -------- --------------------
----------------------------
__intel_new_memcpy+           0000000000000000     000000000 000000000
0118AF5A0
610                                                7FF970C7598
000007FF95D155F0     CALL???  __intel_new_memcpy+  0000007FF 013DF42E8
001749686
                              610                  000000000
...

From a 10046 trace at level 8:
*** 2008-01-23 06:51:57.901
WAIT #3: nam='latch: library cache' ela= 8566 address=1398554576
number=214 tries=1 obj#=-1 tim=5204643696
WAIT #3: nam='latch: library cache' ela= 859 address=1398554576
number=214 tries=1 obj#=-1 tim=5205047765
WAIT #3: nam='latch: library cache' ela= 2958 address=1398554576
number=214 tries=1 obj#=-1 tim=5205183748
WAIT #3: nam='latch: library cache' ela= 551 address=1398554576
number=214 tries=1 obj#=-1 tim=5205267198
*** 2008-01-23 06:54:39.117
WAIT #3: nam='latch: library cache' ela= 813 address=1398554576
number=214 tries=1 obj#=-1 tim=5365848854
*** 2008-01-23 06:55:06.288
WAIT #3: nam='latch: library cache' ela= 30 address=1398554576
number=214 tries=1 obj#=-1 tim=5393019180
*** 2008-01-23 06:55:30.006
WAIT #3: nam='latch: library cache' ela= 68 address=1398554576
number=214 tries=1 obj#=-1 tim=5416746379
*** 2008-01-23 06:55:50.584
WAIT #3: nam='latch: library cache' ela= 33 address=1398554576
number=214 tries=1 obj#=-1 tim=5437323921
*** 2008-01-23 06:57:09.536
WAIT #3: nam='latch: library cache' ela= 111 address=1398554576
number=214 tries=1 obj#=-1 tim=5516279642
*** 2008-01-23 06:57:20.895
WAIT #3: nam='latch: library cache' ela= 77 address=1398554576
number=214 tries=1 obj#=-1 tim=5527627340
*** 2008-01-23 06:57:36.082
WAIT #3: nam='latch: library cache' ela= 246 address=1398554576
number=214 tries=1 obj#=-1 tim=5542815685
*** 2008-01-23 06:57:57.957
WAIT #3: nam='latch: library cache' ela= 123 address=1398554576
number=214 tries=1 obj#=-1 tim=5564704225
*** 2008-01-23 06:58:14.644
WAIT #3: nam='latch: library cache' ela= 63 address=1398554576
number=214 tries=1 obj#=-1 tim=5581385020
*** 2008-01-23 06:58:26.269
WAIT #3: nam='latch: library cache' ela= 62 address=1398554576
number=214 tries=1 obj#=-1 tim=5593004724
*** 2008-01-23 06:58:48.346
WAIT #3: nam='latch: library cache' ela= 42 address=1398554576
number=214 tries=1 obj#=-1 tim=5615094241
WAIT #3: nam='latch: library cache' ela= 8 address=1398554576
number=214 tries=1 obj#=-1 tim=5615168161
...

For an average 60 second interval interval, the session had the
following latch statistics:
Latch         Child# Level   Gets  Misses  Sleeps  Sleeps1
LIBRARY CACHE  1       5   529418     25      0       25
LIBRARY CACHE  2       5   539720     36      0       36
LIBRARY CACHE  3       5   519189     15      0       15
LIBRARY CACHE  4       5   516501     55      0       55
LIBRARY CACHE  5       5   524907   1744      4     1740

On the waits, P1 is 13985, P2 is 214, P3 is 0, Buf is 99, SQL Hash is
3250939240.

SELECT
  SQL_TEXT
FROM
  V$SQL
WHERE
  HASH_VALUE=3250939240

SQL_TEXT
-----------------------------------
select distinct owner from v$access

SELECT
  ID,
  SUBSTR(OPERATION,1,12) OPERATION,
  SUBSTR(OPTIONS,1,12) OPTIONS,
  SUBSTR(OBJECT_OWNER||'.'||OBJECT_NAME,1,20) OBJECT,
  SUBSTR(OBJECT_TYPE,1,13) OBJECT_TYPE,
  PARENT_ID,
  DEPTH,
  POSITION,
  CPU_COST
FROM
  V$SQL_PLAN_STATISTICS_ALL
WHERE
  HASH_VALUE=3250939240
  AND CHILD_NUMBER=1
ORDER BY
  ID;

ID OPERATION    OPTIONS      OBJECT               OBJECT_TYPE
PARENT_ID      DEPTH   POSITION   CPU_COST
-- ------------ ------------ -------------------- -------------
---------- ---------- ---------- ----------
 1 HASH
UNIQUE       .                                          0
1          1    2142850
 2 NESTED
LOOPS              .
1          2          1    1115000
 3 NESTED
LOOPS              .
2          3          1    1080000
 4 MERGE JOIN
CARTESIAN    .                                          3
4          1     730000
 5 FIXED TABLE  FULL         SYS.X$KSUSE          TABLE
(FIXED)         4          5          1     380000
 6 BUFFER
SORT         .                                          4
5          2     350000
 7 FIXED TABLE  FULL         SYS.X$KGLDP          TABLE
(FIXED)         6          6          1     350000
 8 FIXED TABLE  FIXED INDEX  SYS.X$KGLLK (ind:1)  TABLE
(FIXED)         3          4          2       3500
 9 FIXED TABLE  FIXED INDEX  SYS.X$KGLOB (ind:1)  TABLE
(FIXED)         2          3          2       3500

SELECT
  ID,
  ACCESS_PREDICATES,
  FILTER_PREDICATES
FROM
  V$SQL_PLAN_STATISTICS_ALL
WHERE
  HASH_VALUE=3250939240
  AND CHILD_NUMBER=1
ORDER BY
  ID;

ID ACCESS_PREDICATES FILTER_PREDICATES
-- ----------------- -----------------
 1
 2
 3
 4
 5                   "S"."INST_ID"=USERENV('INSTANCE')
 6
 7
 8                   ("L"."KGLLKUSE"="S"."ADDR" AND
"L"."KGLLKHDL"="D"."KGLHDADR" AND "L"."KGLNAHSH"="D"."KGLNAHSH")
 9                   ("O"."KGLNAHSH"="D"."KGLRFHSH" AND
"O"."KGLHDADR"="D"."KGLRFHDL")

Why are you attempting to run this SQL statement?

A quick Google search finds this page:
http://download-uk.oracle.com/docs/cd/B13789_01/server.101/b10755/dyn...

V$ACCESS displays objects in the database that are currently locked
and the sessions that are accessing them.
Owner: Owner of the object

Charles Hooper
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Charles Hooper  
View profile  
 More options Jan 23 2008, 10:39 am
Newsgroups: comp.databases.oracle.server
From: Charles Hooper <hooperc2...@yahoo.com>
Date: Wed, 23 Jan 2008 07:39:43 -0800 (PST)
Local: Wed, Jan 23 2008 10:39 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 7:58 am, Charles Hooper <hooperc2...@yahoo.com> wrote:

The query eventually completed on the 32 bit version of Oracle
10.2.0.2 with the Oracle October 2006 CPU.

PARSE 1|CPU S     0.000000|CLOCK S    0.006227|ROWs 0
EXEC  1|CPU S     0.000000|CLOCK S    0.000201|ROWs 0
FETCH 2|CPU S 13112.828125|CLOCK S  926.981803|ROWs 6

Rwo Source Execution Plan:
       (Rows 6)   HASH UNIQUE (cr=0 pr=0 pw=0 time=568347223 us)
    (Rows 3463)    NESTED LOOPS  (cr=0 pr=0 pw=0 time=3464796755 us)
    (Rows 3463)     NESTED LOOPS  (cr=0 pr=0 pw=0 time=3464592419 us)
 (Rows 1613768)      MERGE JOIN CARTESIAN (cr=0 pr=0 pw=0
time=21019488 us)
     (Rows 236)       FIXED TABLE FULL X$KSUSE (cr=0 pr=0 pw=0
time=2376 us)
 (Rows 1613768)       BUFFER SORT (cr=0 pr=0 pw=0 time=12951356 us)
    (Rows 6838)        FIXED TABLE FULL X$KGLDP (cr=0 pr=0 pw=0
time=41073 us)
    (Rows 3463)      FIXED TABLE FIXED INDEX X$KGLLK (ind:1) (cr=0
pr=0 pw=0 time=13094082350 us)
    (Rows 3463)     FIXED TABLE FIXED INDEX X$KGLOB (ind:1) (cr=0 pr=0
pw=0 time=166548 us)

Note the merge Cartesian join between the 236 rows in X$KSUSE and the
1613768 rows from X$KGLDP.

The wait events:
0.03 seconds on latch: library cache

Charles Hooper
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
hpuxrac  
View profile  
 More options Jan 23 2008, 11:00 am
Newsgroups: comp.databases.oracle.server
From: hpuxrac <johnbhur...@sbcglobal.net>
Date: Wed, 23 Jan 2008 08:00:05 -0800 (PST)
Local: Wed, Jan 23 2008 11:00 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 12:23 am, Peter Teoh <htmldevelo...@gmail.com> wrote:

Works fine for me hpux 64 bit 10.2.0.3

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Frank van Bortel  
View profile  
 More options Jan 23 2008, 1:35 pm
Newsgroups: comp.databases.oracle.server
From: Frank van Bortel <frank.van.bor...@gmail.com>
Date: Wed, 23 Jan 2008 19:35:55 +0100
Local: Wed, Jan 23 2008 1:35 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

Odd...
Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Production
With the Partitioning, OLAP and Data Mining options

SQL> select distinct owner from v$access;
select distinct owner from v$access
*
ERROR at line 1:
ORA-01013: user requested cancel of current operation

SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release
10.2.0.3.0 - Production
With the Partitioning, OLAP and Data Mining options
[oracle102@cs-frank03 ~]$ uname -a
Linux cs-frank03 2.6.18-53.1.4.el5PAE #1 SMP Fri Nov 30 01:21:20 EST
2007 i686 i686 i386 GNU/Linux

--

Regards,
Frank van Bortel

Top-posting in UseNet newsgroups is one way to shut me up


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steve Howard  
View profile  
 More options Jan 23 2008, 2:16 pm
Newsgroups: comp.databases.oracle.server
From: Steve Howard <stevedhow...@gmail.com>
Date: Wed, 23 Jan 2008 11:16:03 -0800 (PST)
Local: Wed, Jan 23 2008 2:16 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 1:35 pm, Frank van Bortel <frank.van.bor...@gmail.com>
wrote:

Sorry, that will teach me to post prior to 8AM and my third cuppa'
joe :(.  I ran it without the distinct, and mine times out as well, on
both Linux and AIX.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Eberhard Niendorf  
View profile  
 More options Jan 23 2008, 4:45 pm
Newsgroups: comp.databases.oracle.server
From: Eberhard Niendorf <eberhard.niendorf_schr...@t-online.de>
Date: Wed, 23 Jan 2008 22:45:17 +0100
Local: Wed, Jan 23 2008 4:45 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

I could reproduce the hanging for 10.2.0.3 on x86_64, but after using

SQL> alter session set optimizer_mode = RULE;    or
SQL> alter session set optimizer_mode = FIRST_ROWS_n;

it works fine.

Eberhard Niendorf


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
joel garry  
View profile  
 More options Jan 23 2008, 5:07 pm
Newsgroups: comp.databases.oracle.server
From: joel garry <joel-ga...@home.com>
Date: Wed, 23 Jan 2008 14:07:14 -0800 (PST)
Local: Wed, Jan 23 2008 5:07 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 4:58 am, Charles Hooper <hooperc2...@yahoo.com> wrote:

> On Jan 23, 12:23 am, Peter Teoh <htmldevelo...@gmail.com> wrote:

> > This was attempted on 10gR2, 11gR1 and both had the same problem.

> I was able to reproduce this problem on Oracle 10.2.0.2 with the
> Oracle October 2006 CPU on 64 bit Windows 2003.

> From the udump trace file:
> ksedmp: internal or fatal error
> ORA-07445: exception encountered: core dump [ACCESS_VIOLATION]
> [__intel_new_memcpy+610] [PC:0x3236532] [ADDR:0x0] [UNABLE_TO_READ] []
> Current SQL statement for this session:
> select distinct owner from v$access

Looks like the fix for Note:353663.1 doesn't hit all the
possibilities.  But check out Note:415450.1, perhaps a windows-
specific problem, since there is that "intel" argument.  Looks like
there are some "unable to duplicate" similar problems, too.

No problem for me with hp-ux 9206.

jg
--
@home.com is bogus.
"When the pin is pulled, Mr. Grenade is not our friend." - U.S.
Marine Corps


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Charles Hooper  
View profile  
 More options Jan 23 2008, 9:14 pm
Newsgroups: comp.databases.oracle.server
From: Charles Hooper <hooperc2...@yahoo.com>
Date: Wed, 23 Jan 2008 18:14:56 -0800 (PST)
Local: Wed, Jan 23 2008 9:14 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 23, 5:07 pm, joel garry <joel-ga...@home.com> wrote:

I will have to take a look at those bug reports.

I may have found something that may help the OP - it hit me when I
found very slow performance with the same SQL statement on 32 bit
Oracle 10.2.0.3 and 11.1.0.6, after looking at the DBMS_XPLANs.

The DBMS_XPLAN on 10.2.0.3:
--------------------------------------------------------------------------- ----------------------------------------------
| Id  | Operation                  | Name            | Starts | E-Rows
| A-Rows |   A-Time   |  OMem |  1Mem | Used-Mem |
--------------------------------------------------------------------------- ----------------------------------------------
|   1 |  HASH UNIQUE               |                 |      1 |    105
|      5 |00:02:51.06 |       |       |          |
|   2 |   NESTED LOOPS             |                 |      1 |    105
|   1131 |00:02:51.04 |       |       |          |
|   3 |    NESTED LOOPS            |                 |      1 |     10
|   1131 |00:02:50.39 |       |       |          |
|   4 |     MERGE JOIN CARTESIAN   |                 |      1 |    100
|    180K|00:00:01.27 |       |       |          |
|*  5 |      FIXED TABLE FULL      | X$KSUSE         |      1 |      1
|    236 |00:00:00.01 |       |       |          |
|   6 |      BUFFER SORT           |                 |    236 |    100
|    180K|00:00:00.55 | 36864 | 36864 |32768  (0)|
|   7 |       FIXED TABLE FULL     | X$KGLDP         |      1 |    100
|    763 |00:00:00.01 |       |       |          |
|*  8 |     FIXED TABLE FIXED INDEX| X$KGLLK (ind:1) |    180K|      1
|   1131 |00:02:48.31 |       |       |          |
|*  9 |    FIXED TABLE FIXED INDEX | X$KGLOB (ind:1) |   1131 |     10
|   1131 |00:00:00.64 |       |       |          |
--------------------------------------------------------------------------- ----------------------------------------------

Predicate Information (identified by operation id):
---------------------------------------------------
   5 - filter("S"."INST_ID"=USERENV('INSTANCE'))
   8 - filter(("L"."KGLLKUSE"="S"."ADDR" AND
"L"."KGLLKHDL"="D"."KGLHDADR" AND "L"."KGLNAHSH"="D"."KGLNAHSH"))
   9 - filter(("O"."KGLNAHSH"="D"."KGLRFHSH" AND
"O"."KGLHDADR"="D"."KGLRFHDL"))

Note the MERGE JOIN CARTESIAN, and how the estimated rows compares
with the actual rows.

The DBMS_XPLAN on 11.1.0.6:
select distinct owner from v$access
--------------------------------------------------------------------------- -----------------------------------------------
| Id  | Operation                   | Name            | Starts | E-
Rows | A-Rows |   A-Time   |  OMem |  1Mem | Used-Mem |
--------------------------------------------------------------------------- -----------------------------------------------
|   1 |  HASH UNIQUE                |                 |      1 |
1 |      6 |00:00:40.28 |   951K|   951K|  860K (0)|
|   2 |   NESTED LOOPS              |                 |      1 |
1 |   2342 |00:00:40.27 |       |       |          |
|   3 |    MERGE JOIN CARTESIAN     |                 |      1 |
1 |   2842K|00:00:11.37 |       |       |          |
|   4 |     NESTED LOOPS            |                 |      1 |
1 |  16721 |00:00:00.38 |       |       |          |
|   5 |      FIXED TABLE FULL       | X$KGLDP         |      1 |
100 |  16721 |00:00:00.05 |       |       |          |
|*  6 |      FIXED TABLE FIXED INDEX| X$KGLOB (ind:1) |  16721 |
1 |  16721 |00:00:00.21 |       |       |          |
|   7 |     BUFFER SORT             |                 |  16721 |
1 |   2842K|00:00:02.91 |  4096 |  4096 | 4096  (0)|
|*  8 |      FIXED TABLE FULL       | X$KSUSE         |      1 |
1 |    170 |00:00:00.01 |       |       |          |
|*  9 |    FIXED TABLE FIXED INDEX  | X$KGLLK (ind:1) |   2842K|
1 |   2342 |00:00:15.49 |       |       |          |
--------------------------------------------------------------------------- -----------------------------------------------

Predicate Information (identified by operation id):
---------------------------------------------------
   6 - filter(("O"."KGLNAHSH"="D"."KGLRFHSH" AND
"O"."KGLHDADR"="D"."KGLRFHDL"))
   8 - filter("S"."INST_ID"=USERENV('INSTANCE'))
   9 - filter(("L"."KGLLKUSE"="S"."ADDR" AND
"L"."KGLLKHDL"="D"."KGLHDADR" AND "L"."KGLNAHSH"="D"."KGLNAHSH"))

The above executed more quickly, and the plan is slightly different,
but the MERGE JOIN CARTESIAN is still present, as is the difference
between the estimated and actual number of rows.

The fixed object stats must be wrong (I recall having a problem with
that a couple years ago when perfoming the following)...
SQL> CONNECT / AS SYSDBA
SQL> EXEC DBMS_STATS.GATHER_FIXED_OBJECTS_STATS('ALL');
BEGIN DBMS_STATS.GATHER_FIXED_OBJECTS_STATS('ALL'); END;

*
ERROR at line 1:
ORA-20000: Insufficient privileges to analyze an object in Fixed Ob
ORA-06512: at "SYS.DBMS_STATS", line 17951
ORA-06512: at "SYS.DBMS_STATS", line 18404
ORA-06512: at "SYS.DBMS_STATS", line 18951
ORA-06512: at line 1

The same error occurs on Oracle 10.2.0.2, 10.2.0.3, and 11.1.0.6 as
the internal user, SYS AS SYSDBA, and SYSTEM.

There must be another way:
SQL> EXEC DBMS_STATS.GATHER_SCHEMA_STATS('SYS',GATHER_FIXED=>TRUE)

PL/SQL PROCEDURE SUCCESSFULLY COMPLETED.

The new DBMS_XPLANs:
10.2.0.3:
--------------------------------------------------------------------------- ---------------------------------------------
| Id  | Operation                 | Name            | Starts | E-Rows
| A-Rows |   A-Time   |  OMem |  1Mem | Used-Mem |
--------------------------------------------------------------------------- ---------------------------------------------
|   1 |  HASH UNIQUE              |                 |      1 |      7
|      4 |00:00:00.09 |       |       |          |
|   2 |   NESTED LOOPS            |                 |      1 |   1822
|   1003 |00:00:00.08 |       |       |          |
|*  3 |    HASH JOIN              |                 |      1 |   1822
|   1003 |00:00:00.05 |   898K|   898K| 1099K (0)|
|*  4 |     HASH JOIN             |                 |      1 |   1822
|   1897 |00:00:00.03 |  1010K|  1010K|  639K (0)|
|*  5 |      FIXED TABLE FULL     | X$KSUSE         |      1 |    236
|    236 |00:00:00.01 |       |       |          |
|   6 |      FIXED TABLE FULL     | X$KGLLK         |      1 |   1822
|   1897 |00:00:00.01 |       |       |          |
|   7 |     FIXED TABLE FULL      | X$KGLDP         |      1 |   2892
|    649 |00:00:00.01 |       |       |          |
|*  8 |    FIXED TABLE FIXED INDEX| X$KGLOB (ind:1) |   1003 |      1
|   1003 |00:00:00.01 |       |       |          |
--------------------------------------------------------------------------- ---------------------------------------------

Predicate Information (identified by operation id):
---------------------------------------------------
   3 - access("L"."KGLLKHDL"="D"."KGLHDADR" AND
"L"."KGLNAHSH"="D"."KGLNAHSH")
   4 - access("L"."KGLLKUSE"="S"."ADDR")
   5 - filter("S"."INST_ID"=USERENV('INSTANCE'))
   8 - filter(("O"."KGLNAHSH"="D"."KGLRFHSH" AND
"O"."KGLHDADR"="D"."KGLRFHDL"))

The MERGE JOIN CARTESIAN is gone and the execution time dropped from 2
minutes, 51 seconds to 0.09 seconds.

11.1.0.6:
--------------------------------------------------------------------------- ----------------------------------------------
| Id  | Operation                  | Name            | Starts | E-Rows
| A-Rows |   A-Time   |  OMem |  1Mem | Used-Mem |
--------------------------------------------------------------------------- ----------------------------------------------
|   1 |  HASH UNIQUE               |                 |      1 |     19
|      1 |00:00:00.04 |  1037K|  1037K|  368K (0)|
|   2 |   NESTED LOOPS             |                 |      1 |   1139
|    134 |00:00:00.04 |       |       |          |
|   3 |    NESTED LOOPS            |                 |      1 |   1139
|    134 |00:00:00.03 |       |       |          |
|*  4 |     HASH JOIN              |                 |      1 |   1139
|   1144 |00:00:00.02 |  1010K|  1010K| 1205K (0)|
|*  5 |      FIXED TABLE FULL      | X$KSUSE         |      1 |    170
|    170 |00:00:00.01 |       |       |          |
|   6 |      FIXED TABLE FULL      | X$KGLLK         |      1 |   1139
|   1144 |00:00:00.01 |       |       |          |
|*  7 |     FIXED TABLE FIXED INDEX| X$KGLDP (ind:1) |   1144 |      1
|    134 |00:00:00.01 |       |       |          |
|*  8 |    FIXED TABLE FIXED INDEX | X$KGLOB (ind:1) |    134 |      1
|    134 |00:00:00.01 |       |       |          |
--------------------------------------------------------------------------- ----------------------------------------------

Predicate Information (identified by operation id):
---------------------------------------------------
   4 - access("L"."KGLLKUSE"="S"."ADDR")
   5 - filter("S"."INST_ID"=USERENV('INSTANCE'))
   7 - filter(("L"."KGLLKHDL"="D"."KGLHDADR" AND
...

read more »


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Frank van Bortel  
View profile  
 More options Jan 24 2008, 2:14 pm
Newsgroups: comp.databases.oracle.server
From: Frank van Bortel <frank.van.bor...@gmail.com>
Date: Thu, 24 Jan 2008 20:14:52 +0100
Local: Thurs, Jan 24 2008 2:14 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

Reproduces on Linux as well. But I'm on Intel, yes.
Don't know what  hardware Steve Howard uses for AIX - is
AIX 5.2 available for intel?!?
--

Regards,
Frank van Bortel

Top-posting in UseNet newsgroups is one way to shut me up


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Frank van Bortel  
View profile  
 More options Jan 24 2008, 2:20 pm
Newsgroups: comp.databases.oracle.server
From: Frank van Bortel <frank.van.bor...@gmail.com>
Date: Thu, 24 Jan 2008 20:20:31 +0100
Local: Thurs, Jan 24 2008 2:20 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

Charles to the rescue:

SQL> EXEC DBMS_STATS.GATHER_SCHEMA_STATS('SYS',GATHER_FIXED=>TRUE);

PL/SQL procedure successfully completed.

SQL> set timing on
SQL> select distinct owner from v$access;

OWNER
----------------------------------------------------------------
PUBLIC
SYSTEM
XDB
SYS

Elapsed: 00:00:00.01

At least there's a workaround.
--

Regards,
Frank van Bortel

Top-posting in UseNet newsgroups is one way to shut me up


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Charles Hooper  
View profile  
 More options Jan 24 2008, 3:13 pm
Newsgroups: comp.databases.oracle.server
From: Charles Hooper <hooperc2...@yahoo.com>
Date: Thu, 24 Jan 2008 12:13:11 -0800 (PST)
Local: Thurs, Jan 24 2008 3:13 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 24, 2:20 pm, Frank van Bortel <frank.van.bor...@gmail.com>
wrote:

Thanks for the feedback Frank.

That call solved the problem on 64 bit Windows, no more ORA-07445, and
the SQL statement executes quickly.  A little more testing to
determine why the following failed:
  EXEC DBMS_STATS.GATHER_FIXED_OBJECTS_STATS('ALL');

I found Metalink doc ID 272479.1, which suggests to use:
  EXEC DBMS_STATS.GATHER_FIXED_OBJECTS_STATS(NULL);

Then I started to wonder, did I find a work around a couple years ago
for this problem when I migrated to Oracle 10.2.0.2?  How to determine
if I collected statistics on the fixed tables?  A search on Metalink
found this article from 2004:
https://metalink.oracle.com/metalink/plsql/f?p=200:27:500015404803594...

In the article, Jonathan Lewis mentioned that tab_stats$ could be
checked.
Test database on 64 bit Windows:
SELECT
  *
FROM
  SYS.TAB_STATS$

The above returned about 582 rows after running:
  EXEC DBMS_STATS.GATHER_SCHEMA_STATS('SYS',GATHER_FIXED=>TRUE);

I then checked a production database, and found no rows returned.
Using the suggestion from the Metalink article:
  EXEC DBMS_STATS.GATHER_FIXED_OBJECTS_STATS(NULL);

The stats collection completed much more quickly, as it did not
analyze the full SYS schema, and there were 582 rows returned by the
query on SYS.TAB_STATS$.  It looks like this simple query may be used
to determine if fixed object statistics need to be collected.

I am still looking for the source of the suggestion to use 'ALL' as
the parameter for GATHER_FIXED_OBJECTS_STATS - it was apparently not
from "Expert Oracle Database 10g Administation", as that book shows
nothing after GATHER_FIXED_OBJECTS_STATS.

Charles Hooper
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
fitzjarrell@cox.net  
View profile  
 More options Feb 1 2008, 12:38 pm
Newsgroups: comp.databases.oracle.server
From: "fitzjarr...@cox.net" <fitzjarr...@cox.net>
Date: Fri, 1 Feb 2008 09:38:17 -0800 (PST)
Local: Fri, Feb 1 2008 12:38 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Jan 24, 2:13 pm, Charles Hooper <hooperc2...@yahoo.com> wrote:

Oracle has published Metalink Note 549895.1, regarding this same
problem.  Their solution is different, and doesn't involve fixed
object statistics.

David Fitzjarrell


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Charles Hooper  
View profile  
 More options Feb 1 2008, 1:40 pm
Newsgroups: comp.databases.oracle.server
From: Charles Hooper <hooperc2...@yahoo.com>
Date: Fri, 1 Feb 2008 10:40:37 -0800 (PST)
Local: Fri, Feb 1 2008 1:40 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Feb 1, 12:38 pm, "fitzjarr...@cox.net" <fitzjarr...@cox.net> wrote:

> On Jan 24, 2:13 pm, Charles Hooper <hooperc2...@yahoo.com> wrote:
> > I am still looking for the source of the suggestion to use 'ALL' as
> > the parameter for GATHER_FIXED_OBJECTS_STATS - it was apparently not
> > from "Expert Oracle Database 10g Administation", as that book shows
> > nothing after GATHER_FIXED_OBJECTS_STATS.

> > Charles Hooper
> > IT Manager/Oracle DBA
> > K&M Machine-Fabricating, Inc.
> Oracle has published Metalink Note 549895.1, regarding this same
> problem.  Their solution is different, and doesn't involve fixed
> object statistics.

> David Fitzjarrell

Thanks for the reference to the article.

It is an interesting article in that the author did not investigate
what was causing the bad execution plan, only that a "MERGE JOIN
CARTESIAN" operation appeared in the plan - and the plan indicated
that the join did (or should have) taken 0.01 seconds.  Instead of
addressing the cause of the problem, they supplied a bandage to
something that "might" have been the problem (even though it was not
indicated in the plan) by making the following change:
alter session set "_optimizer_cartesian_enabled"=false;

Cartesian merge joins are not necessarily bad in all cases.  Page 387
of "Cost-Based Oracle Fundamentals" contains a bit of information
about this type of join, and how it might be helpful.

I wonder who the author of that article is?  Did you notice this
wording on the article: "This document is being delivered to you via
Oracle Support's Rapid Visibility (RaV) Rapid Visibility (RaV)
process, and therefore has not been subject to an independent
technical review."  Maybe it should have been subject to review?

As far as I am aware, fixed object statistics are supposed to be
gathered on Oracle 10g databases.

On a side note, I found the source of the suggestion to use 'ALL' as
the parameter for GATHER_FIXED_OBJECTS_STATS.
"OCP Oracle Database 10g Exam Guide" by Alapati, who I believe is also
the author of teh very useful book "Expert Oracle Database 10g
Administation" by Sam Alapati:
http://www.oracle.com/technology/books/pdfs/exam_ch5.pdf

The suggestion to use 'ALL' can also be found here:
http://www.oracle.com/technology/books/pdfs/book_10g_chap9_ce1.pdf

Charles Hooper
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
fitzjarrell@cox.net  
View profile  
 More options Feb 1 2008, 3:48 pm
Newsgroups: comp.databases.oracle.server
From: "fitzjarr...@cox.net" <fitzjarr...@cox.net>
Date: Fri, 1 Feb 2008 12:48:06 -0800 (PST)
Local: Fri, Feb 1 2008 3:48 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Feb 1, 12:40 pm, Charles Hooper <hooperc2...@yahoo.com> wrote:

I. too, thought it odd that such a 'band-aid' was suggested by Oracle,
absent any real investigative work.  My choice is to compute the fixed
objects statistics, as I'd rather not adversely affect every other
query using a MERGE JOIN CARTESIAN in order to fix one errant example.

David Fitzjarrell


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
tit...@gmail.com  
View profile  
 More options Dec 26 2012, 7:41 am
Newsgroups: comp.databases.oracle.server
From: tit...@gmail.com
Date: Wed, 26 Dec 2012 04:41:37 -0800 (PST)
Local: Wed, Dec 26 2012 7:41 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
Hi all,
I have same problem with fixed tables

Oracle9i Enterprise Edition Release 9.2.0.8.0 - 64bit Production
OS AIX 5.3

SQL_TEXT
--------------------------------------------------------------------------- -----
SELECT * FROM V$DB_PIPES WHERE NAME NOT LIKE '%LOCK%' ORDER BY PIPE_SIZE DESC

Plan:
*************************************************************************** *****
Rows     Row Source Operation
-------  ---------------------------------------------------
    191  SORT ORDER BY (cr=0 r=0 w=0 time=32691509 us)
    191   FIXED TABLE FULL X$KGLOB (cr=0 r=0 w=0 time=32678781 us)

Elapsed times include waiting on following events:
  Event waited on                             Times   Max. Wait  Total Waited
  ----------------------------------------   Waited  ----------  ------------
  SQL*Net message to client                      14        0.00          0.00
  latch free                                     75        0.29         11.75
  SQL*Net message from client                    14        2.15          2.16
*************************************************************************** *****

But I can't create fixed index on X$KGLOB, because this is 9.2.0.8.
What can I do to eliminate this problem?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
tit...@gmail.com  
View profile  
 More options Dec 26 2012, 7:44 am
Newsgroups: comp.databases.oracle.server
From: tit...@gmail.com
Date: Wed, 26 Dec 2012 04:44:03 -0800 (PST)
Local: Wed, Dec 26 2012 7:44 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

On Wednesday, December 26, 2012 6:41:37 PM UTC+6, tit...@gmail.com wrote:
> But I can't create fixed index on X$KGLOB, because this is 9.2.0.8.

Sorry, I mean that I can't collect statistics on the fixed objects:

SQL> EXEC DBMS_STATS.GATHER_FIXED_OBJECTS_STATS('ALL');
BEGIN DBMS_STATS.GATHER_FIXED_OBJECTS_STATS('ALL'); END;

                 *
ERROR at line 1:
ORA-06550: line 1, column 18:
PLS-00302: component 'GATHER_FIXED_OBJECTS_STATS' must be declared
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Mladen Gogala  
View profile  
 More options Dec 26 2012, 1:16 pm
Newsgroups: comp.databases.oracle.server
From: Mladen Gogala <gogala.mla...@gmail.com>
Date: Wed, 26 Dec 2012 18:16:22 +0000 (UTC)
Local: Wed, Dec 26 2012 1:16 pm
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

On Wed, 26 Dec 2012 04:41:37 -0800, titan4 wrote:
> But I can't create fixed index on X$KGLOB, because this is 9.2.0.8.
> What can I do to eliminate this problem?

Upgrade sounds like a winner.

--
http://mgogala.byethost5.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
tit...@gmail.com  
View profile  
 More options Dec 27 2012, 1:02 am
Newsgroups: comp.databases.oracle.server
From: tit...@gmail.com
Date: Wed, 26 Dec 2012 22:02:25 -0800 (PST)
Local: Thurs, Dec 27 2012 1:02 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access
On Thursday, December 27, 2012 12:16:22 AM UTC+6, Mladen Gogala wrote:
> On Wed, 26 Dec 2012 04:41:37 -0800, titan4 wrote:

> Upgrade sounds like a winner.

We will not be able to upgrade in the next 2 years, unfortunately...

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Deadly Dirk  
View profile  
 More options Dec 27 2012, 3:23 am
Newsgroups: comp.databases.oracle.server
From: Deadly Dirk <d...@pfln.invalid>
Date: Thu, 27 Dec 2012 08:23:39 +0000 (UTC)
Local: Thurs, Dec 27 2012 3:23 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

On Wed, 26 Dec 2012 22:02:25 -0800, titan4 wrote:
> On Thursday, December 27, 2012 12:16:22 AM UTC+6, Mladen Gogala wrote:
>> On Wed, 26 Dec 2012 04:41:37 -0800, titan4 wrote:

>> Upgrade sounds like a winner.

> We will not be able to upgrade in the next 2 years, unfortunately...

Oh? I would really like to hear the reasoning behind this one. Are you
aware of the fact that version 9i is long gone and unsupported? That means
no patches. Absolutely none, zero, nada, zilch. Even worse, if you have
corruption or data loss of any kind, you cannot open a service request
with the Oracle Support. You are on your own. If the database is so
critical to the company that you cannot upgrade it, then the possibility
of losing that database and being beyond help should scare your management
shootless. Lightning strike could put your company out of business. And
lightning strikes do happen. Hurricanes in New York City also do happen.
There is a building in Jersey City NJ, called "Harbourside Financial
Center", built right on the Hudson coast, less than a mile from
the place where Hudson flows into the Atlantic Ocean. Beautiful waterfront
property, right across the river from the Wall Street. In the basement of
that building was a server room with quite a few servers. Then came the
hurricane Sandy. Long story short, here is what happened:

http://ireport.cnn.com/docs/DOC-867312

I will leave to your imagination to guess what has happened to the servers
in the basement. Imagine your 9.2.0.8 server was sleeping with the fishes,
just like Luca Brasi from the "Godfather". Where would you get help? Your
server is unsupported and Oracle Corp. would probably require a ton of
money and your first born. Your company may go out of business because of
such thing.

On the other hand, if that database is not that important, I don't see why
wouldn't you take it down and upgrade? A bug in 9.2.0.8? Tough luck my
friend, you're on your own. That's what happens when you run unsupported
versions.

--
I love the smell of napalm in the morning.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
tit...@gmail.com  
View profile  
 More options Dec 28 2012, 4:45 am
Newsgroups: comp.databases.oracle.server
From: tit...@gmail.com
Date: Fri, 28 Dec 2012 01:45:53 -0800 (PST)
Local: Fri, Dec 28 2012 4:45 am
Subject: Re: A potential bug (infinite loop) in Oracle: querying v$access

On Thursday, December 27, 2012 2:23:39 PM UTC+6, Deadly Dirk wrote:
> Oh? I would really like to hear the reasoning behind this one. Are you

Thank you, I know all the risks... but I can't disclose those reasons...

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Messages 1 - 25 of 33   Newer >
« Back to Discussions « Newer topic     Older topic »