r*t 发帖数: 34 | 1 An urgent problem, thanks a lot if anybody can help!!!
I have several parallel processes like this:
my_program parameter1 &
my_program parameter2 &
...
my_program parametern &
In most of time, it runs as expected, but sometime it do give me an error li
ke this:
"Truncating table TABLE_A, ORA-00054: resource busy and acquire with NOWAIT
specified"
I am very positive that I have already removed all the truncation codes from
my program, but I still have this kind of error. Could anybody give me a h |
z***y 发帖数: 7151 | 2 这可能是rollback 没有完成。 你是不是曾经强制结束过语句?如果是, 你应该等回
滚结束。
你或者看一下有没有没有提交的transaction.
你可以试着在系统不忙的时候再试一次。
我不做oracle很久,如果说错了还望见谅。 |
r*t 发帖数: 34 | 3 Thanks a lot for your advice. I have similar guess but I don't know how to
verify it. Do you have any idea about turning on the oracle tracing? or
other methods that I can get some useful log info.
Thanks!
【在 z***y 的大作中提到】 : 这可能是rollback 没有完成。 你是不是曾经强制结束过语句?如果是, 你应该等回 : 滚结束。 : 你或者看一下有没有没有提交的transaction. : 你可以试着在系统不忙的时候再试一次。 : 我不做oracle很久,如果说错了还望见谅。
|
c*****d 发帖数: 6045 | 4 举个例子,ora-00054是这样发生的
session A:
update scott.dept set loc='beijing';
然后不commit也不rollback
session B:
alter table scott.dept drop column dname;
ORA-00054: resource busy and acquire with NOWAIT specified
truncate table scott.dept;
ORA-00054: resource busy and acquire with NOWAIT specified
li
NOWAIT
from
hi
pac
t
d
【在 r*t 的大作中提到】 : An urgent problem, thanks a lot if anybody can help!!! : I have several parallel processes like this: : my_program parameter1 & : my_program parameter2 & : ... : my_program parametern & : In most of time, it runs as expected, but sometime it do give me an error li : ke this: : "Truncating table TABLE_A, ORA-00054: resource busy and acquire with NOWAIT : specified"
|
c*****d 发帖数: 6045 | 5 想追踪什么语句导致ora-00054,可以这么做
alter system set events='54 trace name errorstack forever, level 10'
这样当发生ora-00054的时候,会在udump目录产生一个trace文件
比如下面的的这个trace文件说明是truncate操作导致ora-00054
********************************************************
Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Production
With the Partitioning, OLAP and Data Mining options
ORACLE_HOME = #############
System name: Linux
Node name: #############
Release: 2.4.20-8smp
Version: #1 SMP Thu Mar 13 17:45 |
B*****g 发帖数: 34098 | 6 ding
【在 c*****d 的大作中提到】 : 想追踪什么语句导致ora-00054,可以这么做 : alter system set events='54 trace name errorstack forever, level 10' : 这样当发生ora-00054的时候,会在udump目录产生一个trace文件 : 比如下面的的这个trace文件说明是truncate操作导致ora-00054 : ******************************************************** : Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Production : With the Partitioning, OLAP and Data Mining options : ORACLE_HOME = ############# : System name: Linux : Node name: #############
|
k******t 发帖数: 257 | 7 Why don't you check v$session and v$sql to find out session holding
table_A when ora-54 occurs.
li
NOWAIT
【在 r*t 的大作中提到】 : An urgent problem, thanks a lot if anybody can help!!! : I have several parallel processes like this: : my_program parameter1 & : my_program parameter2 & : ... : my_program parametern & : In most of time, it runs as expected, but sometime it do give me an error li : ke this: : "Truncating table TABLE_A, ORA-00054: resource busy and acquire with NOWAIT : specified"
|
c*****d 发帖数: 6045 | 8 估计他是晚上执行批处理,人不在
所以可以写个event trigger把v$session, v$sql记录下来
第二天再看
不过hold table_A的应该都是他的my_program
error
【在 k******t 的大作中提到】 : Why don't you check v$session and v$sql to find out session holding : table_A when ora-54 occurs. : : li : NOWAIT
|
r*t 发帖数: 34 | 9 Thank you very much! It really helps! Now I found where is the problem.
Thanks again!
【在 c*****d 的大作中提到】 : 想追踪什么语句导致ora-00054,可以这么做 : alter system set events='54 trace name errorstack forever, level 10' : 这样当发生ora-00054的时候,会在udump目录产生一个trace文件 : 比如下面的的这个trace文件说明是truncate操作导致ora-00054 : ******************************************************** : Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Production : With the Partitioning, OLAP and Data Mining options : ORACLE_HOME = ############# : System name: Linux : Node name: #############
|