OCI threaded sample causes ORA-00022 or ORA-01001
I have created a sample program which initializes environment in OCI_THREADED mode and then starts multiple threads. Usually it completes successfully, but sometimes it terminates with error ORA-00022 (invalid session ID; access denied) or ORA-01001 (invalid cursor). I have checked with Oracle 9.2 and 10.2, problem occurs on both. Do I something wrong in my code ? My code requires creation of record rec1 (id number primary key, val number) containing rows with id equal to 0 .. 100:
#include <pthread.h>
#include <oci.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
static char g_User, g_Pass;
static OCIEnv *g_pOciEnv = NULL;
static OCIError *g_pOciError = NULL;
static OCIServer *g_pOciServer = NULL;
enum { NUM_THR = 20, NUM_INC = 30 };
typedef struct {
OCIError *pOciError;
OCISession *pOciSession;
OCISvcCtx *pOciSvcCtx;
} OciSession;
static void CheckError(OCIError *pOciError, sword status)
OraText errbuf[512];
sb4 errcode;
int i;
if( status != OCI_SUCCESS ) {
fflush(stdout);
if( status == OCI_ERROR ) {
for(i = 1; OCIErrorGet(pOciError, (ub4) i, NULL, &errcode,
errbuf, (ub4)sizeof(errbuf), OCI_HTYPE_ERROR) ==
OCI_SUCCESS; ++i)
fprintf(stderr, "Error: %s\n", errbuf);
}else
fprintf(stderr, "unexpected error %d\n", (int)status);
exit(1);
static void InitSession(OciSession *pSes)
OCIHandleAlloc((dvoid *)g_pOciEnv, (dvoid **)&pSes->pOciError,
OCI_HTYPE_ERROR, 0, NULL);
CheckError(pSes->pOciError, OCIHandleAlloc((dvoid*)g_pOciEnv,
(dvoid**)&pSes->pOciSession, OCI_HTYPE_SESSION, 0, NULL));
CheckError(pSes->pOciError, OCIAttrSet((dvoid *)pSes->pOciSession,
OCI_HTYPE_SESSION, g_User, strlen(g_User), OCI_ATTR_USERNAME,
pSes->pOciError));
CheckError(pSes->pOciError, OCIAttrSet((dvoid *)pSes->pOciSession,
OCI_HTYPE_SESSION, g_Pass, strlen(g_Pass), OCI_ATTR_PASSWORD,
pSes->pOciError));
CheckError(pSes->pOciError, OCIHandleAlloc((dvoid *)g_pOciEnv,
(dvoid**)&pSes->pOciSvcCtx, OCI_HTYPE_SVCCTX, 0, NULL));
CheckError(pSes->pOciError, OCIAttrSet((dvoid *)pSes->pOciSvcCtx,
OCI_HTYPE_SVCCTX, (dvoid*)g_pOciServer, 0,
OCI_ATTR_SERVER, pSes->pOciError));
CheckError(pSes->pOciError, OCISessionBegin(pSes->pOciSvcCtx,
pSes->pOciError, pSes->pOciSession, OCI_CRED_RDBMS,
OCI_DEFAULT));
CheckError(pSes->pOciError, OCIAttrSet(pSes->pOciSvcCtx, OCI_HTYPE_SVCCTX,
(dvoid*)pSes->pOciSession, 0, OCI_ATTR_SESSION,
pSes->pOciError));
static void CleanupSession(OciSession *pSes)
CheckError(pSes->pOciError, OCITransRollback(pSes->pOciSvcCtx,
pSes->pOciError, OCI_DEFAULT));
CheckError(pSes->pOciError, OCISessionEnd(pSes->pOciSvcCtx,
pSes->pOciError, pSes->pOciSession, OCI_DEFAULT));
OCIHandleFree(pSes->pOciSession, OCI_HTYPE_SESSION);
OCIHandleFree(pSes->pOciSvcCtx, OCI_HTYPE_SVCCTX);
OCIHandleFree(pSes->pOciError, OCI_HTYPE_ERROR);
static void ThreadFun(void pv)
char sText[] = "select val from rec1 where id = :ses ";
int i, nSes = (int)pv, nVal;
OciSession ses;
OCIStmt *pStmt;
OCIDefine *pODefine = NULL;
OCIBind *pOBind = NULL;
InitSession(&ses);
OCIHandleAlloc(g_pOciEnv, (void**)&pStmt, OCI_HTYPE_STMT, 0, NULL);
CheckError(ses.pOciError, OCIStmtPrepare(pStmt, ses.pOciError,
(OraText*)sText, strlen(sText), OCI_V7_SYNTAX, OCI_DEFAULT));
CheckError(ses.pOciError, OCIBindByName(pStmt, &pOBind,
ses.pOciError, "ses", strlen("ses"), &nSes, sizeof(int),
SQLT_INT, NULL, NULL, NULL,
0, NULL, OCI_DEFAULT));
CheckError(ses.pOciError, OCIDefineByPos(pStmt, &pODefine,
ses.pOciError, 1, &nVal, sizeof(int), SQLT_INT, NULL, NULL,
NULL, OCI_DEFAULT));
for(i = 0; i < NUM_INC; ++i) {
CheckError(ses.pOciError, OCIStmtExecute(ses.pOciSvcCtx, pStmt,
ses.pOciError, 1, 0, NULL, NULL, OCI_DEFAULT));
printf("%d %d\n", nSes, i);
CheckError(ses.pOciError, OCIHandleFree(pStmt, OCI_HTYPE_STMT) );
CleanupSession(&ses);
int main(int argc, char *argv[])
pthread_t thread[NUM_THR];
int i;
if( argc < 3 ) {
printf("usage: %s user password [dblink]\n", argv[0]);
return 0;
g_User = argv[1];
g_Pass = argv[2];
OCIEnvCreate(&g_pOciEnv, OCI_THREADED, NULL, NULL, NULL, NULL, 0, NULL);
OCIHandleAlloc((dvoid *)g_pOciEnv, (dvoid**)&g_pOciError,
OCI_HTYPE_ERROR, 0, NULL);
OCIHandleAlloc((dvoid*)g_pOciEnv, (dvoid**)&g_pOciServer,
OCI_HTYPE_SERVER, 0, NULL);
CheckError(g_pOciError, OCIServerAttach(g_pOciServer, g_pOciError,
(text*)argv[3], argc>3 ? strlen(argv[3]) : 0, OCI_DEFAULT));
for(i = 0; i < NUM_THR; ++i)
pthread_create(thread+i, NULL, ThreadFun, (void*)i);
for(i = 0; i < NUM_THR; ++i)
pthread_join(thread, NULL);
OCIServerDetach(g_pOciServer, g_pOciError, OCI_DEFAULT);
OCIHandleFree(g_pOciServer, OCI_HTYPE_SERVER);
OCIHandleFree(g_pOciEnv, OCI_HTYPE_ENV);
printf("OK\n");
return 0;
In your code the join for thread looks like:
for(i = 0; i < NUM_THR; ++i)
pthread_join(thread, NULL);
is this actually what is there in your code or is it just a typo in posting the message ? If it is the former case then the problem is here itself
Similar Messages
-
ORA-00022 with Database Link and Trigger
Hello altogether,
I got a very strange behaviour with my oracle 10.2.
I have two nets N1 and N2, where N1 can access the servers in N2, but not the other way round. In both nets I have an Oracle database running (D1 and D2).
In N1 I calculate some data, which must be replicated to the database in N2. I do this by using triggers on my tables in database D1 copying the inserted or changed data to D2 by using a shared public database link.
This works fine most of the time. But sometimes I get the following error:
ERROR [STDERR] Caused by: java.sql.SQLException: ORA-02068: following severe error from D2
ORA-00022: invalid session ID; access denied
ORA-06512: at "CUSTOMER", line 13
ORA-04088: error during execution of trigger 'CUSTOMER'
When I use the database links manually, they work.
Any idea?
Thank you!!
DanielThe ORA-02068 message might be important
02068, 00000, "following severe error from %s%s"
// *Cause: A severe error (disconnect, fatal Oracle error) received from
// the indicated database link. See following error text.
// *Action: Contact the remote system administrator.Have you searched Oracle support for any bugs associated with the ORA-02068?
Was the remote session killed, the remote database changed to restricted session, or bounced?
I take it the distributed session is created using a dedicated session and not shared server?
HTH -- Mark D Powell -- -
ORA-00022: invalid session ID; access denied
Cause: Either the session specified does not exist or the caller does not have the privilege to access it.
Action: Specify a valid session ID that you have privilege to access, that is either you own it or you have the CHANGE_USER privilege.
Any idea to solve this error? Thanks...I got this error message when i start to do transaction with oracle 10g in my c# application. I want to grant CHANGE_USER priviledge, but i can't find that priviledge in Oracle 10g. Any other solution for that? Can anyone help me? Thanks...
-
Hi,everyone,
I had installed R Enterprise in my Oracle 11.2.0.1 base on win7,using the R 2.13.2, ORE 1.1, I can using the part function: like
library(ORE)
options(STERM='iESS', str.dendrogram.last="'", editor='emacsclient.exe', show.error.locations=TRUE)
> ore.connect(user = "RQUSER",password = "RQUSERpsw",conn_string = "", all = TRUE)
> ore.is.connected()
[1] TRUE
> ore.ls()
[1] "IRIS_TABLE"
> demo(package = "ORE")
Demos in package 'ORE':
aggregate Aggregation
analysis Basic analysis & data processing operations
basic Basic connectivity to database
binning Binning logic
columnfns Column functions
cor Correlation matrix
crosstab Frequency cross tabulations
derived Handling of derived columns
distributions Distribution, density, and quantile functions
do_eval Embedded R processing
freqanalysis Frequency cross tabulations
graphics Demonstrates visual analysis
group_apply Embedded R processing by group
hypothesis Hyphothesis testing functions
matrix Matrix related operations
nulls Handling of NULL in SQL vs. NA in R
push_pull RDBMS <-> R data transfer
rank Attributed-based ranking of observations
reg Ordinary least squares linear regression
row_apply Embedded R processing by row chunks
sql_like Mapping of R to SQL commands
stepwise Stepwise OLS linear regression
summary Summary functionality
table_apply Embedded R processing of entire table
> demo("aggregate",package = "ORE")
demo(aggregate)
---- ~~~~~~~~~
Type <Return> to start : Return
> #
> # O R A C L E R E N T E R P R I S E S A M P L E L I B R A R Y
> #
> # Name: aggregate.R
> # Description: Demonstrates aggregations
> # See also summary.R
> #
> #
> #
>
> ## Set page width
> options(width = 80)
> # List all accessible tables and views in the Oracle database
> ore.ls()
[1] "IRIS_TABLE"
> # Create a new table called IRIS_TABLE in the Oracle database
> # using the built-in iris data.frame
>
> # First remove previously created IRIS_TABLE objects from the
> # global environment and the database
> if (exists("IRIS_TABLE", globalenv(), inherits = FALSE))
+ rm("IRIS_TABLE", envir = globalenv())
> ore.drop(table = "IRIS_TABLE")
> # Create the table
> ore.create(iris, table = "IRIS_TABLE")
> # Show the updated list of accessible table and views
> ore.ls()
[1] "IRIS_TABLE"
> # Display the class of IRIS_TABLE and where it can be found in
> # the search path
> class(IRIS_TABLE)
[1] "ore.frame"
attr(,"package")
[1] "OREbase"
> search()
[1] ".GlobalEnv" "ore:RQUSER" "ESSR"
[4] "package:ORE" "package:ORExml" "package:OREeda"
[7] "package:OREgraphics" "package:OREstats" "package:MASS"
[10] "package:OREbase" "package:ROracle" "package:DBI"
[13] "package:stats" "package:graphics" "package:grDevices"
[16] "package:utils" "package:datasets" "package:methods"
[19] "Autoloads" "package:base"
> find("IRIS_TABLE")
[1] "ore:RQUSER"
> # Select count(Petal.Length) group by species
> x = aggregate(IRIS_TABLE$Petal.Length,
+ by = list(species = IRIS_TABLE$Species),
+ FUN = length)
> class(x)
[1] "ore.frame"
attr(,"package")
[1] "OREbase"
> x
species x
1 setosa 50
2 versicolor 50
3 virginica 50
> # Repeat FUN = summary, mean, min, max, sd, median, IQR
> aggregate(IRIS_TABLE$Petal.Length, by = list(species = IRIS_TABLE$Species),
+ FUN = summary)
species Min. 1st Qu. Median Mean 3rd Qu. Max. NA's
1 setosa 1.0 1.4 1.50 1.462 1.575 1.9 0
2 versicolor 3.0 4.0 4.35 4.260 4.600 5.1 0
3 virginica 4.5 5.1 5.55 5.552 5.875 6.9 0
> aggregate(IRIS_TABLE$Petal.Length, by = list(species = IRIS_TABLE$Species),
+ FUN = mean)
species x
1 setosa 1.462
2 versicolor 4.260
3 virginica 5.552
> aggregate(IRIS_TABLE$Petal.Length, by = list(species = IRIS_TABLE$Species),
+ FUN = min)
species x
1 setosa 1.0
2 versicolor 3.0
3 virginica 4.5
> aggregate(IRIS_TABLE$Petal.Length, by = list(species = IRIS_TABLE$Species),
+ FUN = max)
species x
1 setosa 1.9
2 versicolor 5.1
3 virginica 6.9
> aggregate(IRIS_TABLE$Petal.Length, by = list(species = IRIS_TABLE$Species),
+ FUN = sd)
species x
1 setosa 0.1736640
2 versicolor 0.4699110
3 virginica 0.5518947
> aggregate(IRIS_TABLE$Petal.Length, by = list(species = IRIS_TABLE$Species),
+ FUN = median)
species x
1 setosa 1.50
2 versicolor 4.35
3 virginica 5.55
> aggregate(IRIS_TABLE$Petal.Length, by = list(species = IRIS_TABLE$Species),
+ FUN = IQR)
species x
1 setosa 0.175
2 versicolor 0.600
3 virginica 0.775
> # More than one grouping column
> x = aggregate(IRIS_TABLE$Petal.Length,
+ by = list(species = IRIS_TABLE$Species,
+ width = IRIS_TABLE$Petal.Width),
+ FUN = length)
> x
species width x
1 setosa 0.1 5
2 setosa 0.2 29
3 setosa 0.3 7
4 setosa 0.4 7
5 setosa 0.5 1
6 setosa 0.6 1
7 versicolor 1.0 7
8 versicolor 1.1 3
9 versicolor 1.2 5
10 versicolor 1.3 13
11 versicolor 1.4 7
12 virginica 1.4 1
13 versicolor 1.5 10
14 virginica 1.5 2
15 versicolor 1.6 3
16 virginica 1.6 1
17 versicolor 1.7 1
18 virginica 1.7 1
19 versicolor 1.8 1
20 virginica 1.8 11
21 virginica 1.9 5
22 virginica 2.0 6
23 virginica 2.1 6
24 virginica 2.2 3
25 virginica 2.3 8
26 virginica 2.4 3
27 virginica 2.5 3
> # Sort the result by ascending value of count
> ore.sort(data = x, by = "x")
species width x
1 virginica 1.4 1
2 virginica 1.7 1
3 versicolor 1.7 1
4 virginica 1.6 1
5 setosa 0.5 1
6 setosa 0.6 1
7 versicolor 1.8 1
8 virginica 1.5 2
9 versicolor 1.1 3
10 virginica 2.4 3
11 virginica 2.5 3
12 virginica 2.2 3
13 versicolor 1.6 3
14 setosa 0.1 5
15 virginica 1.9 5
16 versicolor 1.2 5
17 virginica 2.0 6
18 virginica 2.1 6
19 setosa 0.3 7
20 versicolor 1.4 7
21 setosa 0.4 7
22 versicolor 1.0 7
23 virginica 2.3 8
24 versicolor 1.5 10
25 virginica 1.8 11
26 versicolor 1.3 13
27 setosa 0.2 29
> # by descending value
> ore.sort(data = x, by = "x", reverse = TRUE)
species width x
1 setosa 0.2 29
2 versicolor 1.3 13
3 virginica 1.8 11
4 versicolor 1.5 10
5 virginica 2.3 8
6 setosa 0.4 7
7 setosa 0.3 7
8 versicolor 1.0 7
9 versicolor 1.4 7
10 virginica 2.1 6
11 virginica 2.0 6
12 virginica 1.9 5
13 versicolor 1.2 5
14 setosa 0.1 5
15 versicolor 1.6 3
16 versicolor 1.1 3
17 virginica 2.4 3
18 virginica 2.5 3
19 virginica 2.2 3
20 virginica 1.5 2
21 virginica 1.6 1
22 virginica 1.4 1
23 setosa 0.6 1
24 setosa 0.5 1
25 versicolor 1.8 1
26 virginica 1.7 1
27 versicolor 1.7 1
> # Preserve just 1 row for duplicate x's
> ore.sort(data = x, by = "x", unique.keys = TRUE)
species width x
1 setosa 0.5 1
2 virginica 1.5 2
3 versicolor 1.1 3
4 setosa 0.1 5
5 virginica 2.0 6
6 setosa 0.3 7
7 virginica 2.3 8
8 versicolor 1.5 10
9 virginica 1.8 11
10 versicolor 1.3 13
11 setosa 0.2 29
> ore.sort(data = x, by = "x", unique.keys = TRUE, unique.data = TRUE)
species width x
1 setosa 0.5 1
2 virginica 1.5 2
3 versicolor 1.1 3
4 setosa 0.1 5
5 virginica 2.0 6
6 setosa 0.3 7
7 virginica 2.3 8
8 versicolor 1.5 10
9 virginica 1.8 11
10 versicolor 1.3 13
11 setosa 0.2 29
but when I use the following The ore.doEval command get the errors,
> ore.doEval(function() { 123 })
Error in .oci.GetQuery(conn, statement, ...) :
ORA-29400: data cartridge error
ORA-24323: ?????
ORA-06512: at "RQSYS.RQEVALIMPL", line 23
ORA-06512: at line 4
and I try to run the demo("row_apply", package="ORE") get the same errors:
demo("row_apply",package = "ORE")
demo(row_apply)
---- ~~~~~~~~~
Type <Return> to start : Return
> #
> # O R A C L E R E N T E R P R I S E S A M P L E L I B R A R Y
> #
> # Name: row_apply.R
> # Description: Execute R code on each row
> #
> #
>
> ## Set page width
> options(width = 80)
> # List all accessible tables and views in the Oracle database
> ore.ls()
[1] "IRIS_TABLE"
> # Create a new table called IRIS_TABLE in the Oracle database
> # using the built-in iris data.frame
>
> # First remove previously created IRIS_TABLE objects from the
> # global environment and the database
> if (exists("IRIS_TABLE", globalenv(), inherits = FALSE))
+ rm("IRIS_TABLE", envir = globalenv())
> ore.drop(table = "IRIS_TABLE")
> # Create the table
> ore.create(iris, table = "IRIS_TABLE")
> # Show the updated list of accessible table and views
> ore.ls()
[1] "IRIS_TABLE"
> # Display the class of IRIS_TABLE and where it can be found in
> # the search path
> class(IRIS_TABLE)
[1] "ore.frame"
attr(,"package")
[1] "OREbase"
> search()
[1] ".GlobalEnv" "ore:RQUSER" "ESSR"
[4] "package:ORE" "package:ORExml" "package:OREeda"
[7] "package:OREgraphics" "package:OREstats" "package:MASS"
[10] "package:OREbase" "package:ROracle" "package:DBI"
[13] "package:stats" "package:graphics" "package:grDevices"
[16] "package:utils" "package:datasets" "package:methods"
[19] "Autoloads" "package:base"
> find("IRIS_TABLE")
[1] "ore:RQUSER"
> # The table should now appear in your R environment automatically
> # since you have access to the table now
> ore.ls()
[1] "IRIS_TABLE"
> # This is a database resident table with just metadata on the R side.
> # You will see this below
> class(IRIS_TABLE)
[1] "ore.frame"
attr(,"package")
[1] "OREbase"
> # Apply given R function to each row
> ore.rowApply(IRIS_TABLE,
+ function(dat) {
+ # Any R code goes here. Operates on one row of IRIS_TABLE at
+ # a time
+ cbind(dat, dat$Petal.Length)
+ })
Error in .oci.GetQuery(conn, statement, ...) :
ORA-29400: data cartridge error
ORA-24323: ?????
ORA-06512: at "RQSYS.RQROWEVALIMPL", line 26
ORA-06512: at line 4
>
whether my oracle's version 11.2.0.1 has no the RDBMS bug fix, and other problems? ThanksOracle R Enterprise 1.1. requires Oracle Database 11.2.0.3, 11.2.0.4. On Linux and Windows. Oracle R Enterprise can also work with an 11.2.0.1 or 11.2.0.2 database if it is properly patched.
Embedded R execution will not work without a patched database. Follow this procedure to patch the database:
1. Go to My Oracle Support:http://support.oracle.com
2. Log in and supply your Customer Support ID (CSI).
3. Choose the Patches & Updates tab.
4. In the Patch Search box, type 11678127
and click Search
5. Select the patch for your version of Oracle Database, 11.2.0.1.
6. Click Download to download the patch.
7. Install the patch using OPatch. Ensure that you are using the latest version of OPatch.
Sherry -
I have a new installed database running in ARCIHVELOG mode on SUSE 10SP3. Catalog is not used. When I try to restore the database from a level 0 backup based on SCN, ORA-01180 and ORA-01110 were raised out today. Please help me through this. Thx. The senario follows:
1. I got the current SCN by "select dbms_flashback.get_system_change_number from dual". Say it's 12345;
2. I did a level 0 hot backup with current control file, archived logs and parameter files. Everything went well;
3. Some other DMLs are applied to the database;
4. I want to do a SCN-based incomplete recovery for this database to SCN 12345. Then I
1) shutdown immediate;
2) startup nomount;
3) restore the control file from backupset;
5) startup mount;
6) catalog start with "[backupset path]";
7) restore database until scn 12345.
Just at step 4.7, ORA-01180 and ORA-01110 were raised out, saying cannot create data file 1. Note: Backup files are existing and file permissions are all OK.
Then I issues "list incarnation of database". There is just one record with incarnation id 1.
So I queried v$log_history, found serveral record there. The most recent one has NEXT_SCN later than 12345, say 12400. Then I tried to restore database until this SCN. It WORKED! The restore and recovery succeeded.
My questions are:
1. Why cannot I restore the database to a previous SCN, say 12345, but 12400 is OK?.
2. If the database was RESETLOG prior to my recovery, should I reset database to the incarnation where I took my backup? What can I do if there is no that incarnation information in my control file?
Waiting for your suggestion.Hi guys. There is one update.
This issue is caused by the incorrect SCN vs. backup set. I got this SCN before the backup started. According to Oracle docs, it's not allowed for an SCN based recovery.
Now, I changed the sequence of my operations, so that SCN is got once backup is done, which is exact the "most recent sequence# and least SCN" mentioned by some thread in this forum. It works now.
Anyone could explain why the SCN got prior to the level 0 backup is not recognized by restore/recovery phase? Thanks. -
Instance terminted with ORA-00445 and ORA-00494
Hi Folks,
Oracle 11g Instance terminated after ORA-00445 and ORA-00494. Not sure what is the problem didnot have this problem before. Can any body pls help?
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
PL/SQL Release 11.2.0.1.0 - Production
CORE 11.2.0.1.0 Production
TNS for Linux: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production
Below is the message found in alertlog.
Archived Log entry 17939 added for thread 1 sequence 17973 ID 0xee1270c6 dest 1:
Thu Apr 19 02:32:15 2012
WARNING:io_getevents timed out 600 sec
Thu Apr 19 02:32:17 2012
WARNING:io_getevents timed out 600 sec
Thu Apr 19 02:33:32 2012
WARNING:io_getevents timed out 600 sec
Thu Apr 19 02:35:56 2012
Process 0x0xdfb80810 appears to be hung while dumping
Current time = 1203097316, process death time = 1203032607 interval = 60000
Attempting to kill process 0x0xdfb80810 with OS pid = 7563
OSD kill succeeded for process 0xdfb80810
Thu Apr 19 02:36:32 2012
WARNING:io_getevents timed out 600 sec
Thu Apr 19 02:38:11 2012
Errors in file /apps/opt/oracle/admin/diag/rdbms/vchsit2/vchsit2/trace/vchsit2_smco_8548.trc (incident=76297):
ORA-00445: background process "W000" did not start after 120 seconds
Incident details in: /apps/opt/oracle/admin/diag/rdbms/vchsit2/vchsit2/incident/incdir_76297/vchsit2_smco_8548_i76297.trc
Thu Apr 19 02:38:11 2012
Errors in file /apps/opt/oracle/admin/diag/rdbms/vchsit2/vchsit2/trace/vchsit2_arc2_7523.trc (incident=76329):
ORA-00494: enqueue [CF] held for too long (more than 900 seconds) by 'inst 1, osid 7315'
Incident details in: /apps/opt/oracle/admin/diag/rdbms/vchsit2/vchsit2/incident/incdir_76329/vchsit2_arc2_7523_i76329.trc
Thu Apr 19 02:38:11 2012
Fatal NI connect error 12537, connecting to:
(LOCAL=NO)
VERSION INFORMATION:
TNS for Linux: Version 11.2.0.1.0 - Production
Oracle Bequeath NT Protocol Adapter for Linux: Version 11.2.0.1.0 - Production
TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.1.0 - Production
Time: 19-APR-2012 02:38:11
Tracing not turned on.
Tns error struct:
ns main err code: 12537
TNS-12537: TNS:connection closed
ns secondary err code: 12560
nt main err code: 0
nt secondary err code: 0
nt OS err code: 0
opiodr aborting process unknown ospid (2743) as a result of ORA-609
Thu Apr 19 02:38:12 2012
Trace dumping is performing id=[cdmp_20120419023812]
Killing enqueue blocker (pid=7315) on resource CF-00000000-00000000 by (pid=7523)
by killing session 6.1
Killing enqueue blocker (pid=7315) on resource CF-00000000-00000000 by (pid=7523)
by terminating the process
ARC2 (ospid: 7523): terminating the instance due to error 2103
Instance terminated by ARC2, pid = 7523
Thu Apr 19 10:43:07 2012Hi;
Please see:
ORA-00445: Background Process "xxxx" Did Not Start After 120 Seconds [ID 1345364.1]
Regard
Helios -
Ora 600 and ora 7445 error in oracle 10g r2
hi all,
we are using Oracle 10g r2.
os is windows 2003 server,
ram is 4 gb.
front end is java .
we got a below mentioned errors.
i got the RA-00600: internal error code, arguments: [qerghFetch:inc], [], [], [], [], [], [], [],
and ORA-07445: exception encountered: core dump [ACCESS_VIOLATION] [unable_to_trans_pc] [PC:0x61F04AC9] [ADDR:0xC] [UNABLE_TO_READ] []
and Error 0 in kwqmnpartition(), aborting txn errors.
for aug 3 11.42.47 we got a ora 600 error after that through front end (java) users can't able to connect the database.the not able to executed the query session disconnected error.
what is reason for theis error . how it will rectifiy.?
pls advice.Below i attached the alret log message .
Sun Aug 02 04:04:24 2009
Error 0 in kwqmnpartition(), aborting txn
Sun Aug 02 05:48:10 2009
Error 0 in kwqmnpartition(), aborting txn
Sun Aug 02 05:49:10 2009
Error 0 in kwqmnpartition(), aborting txn
Sun Aug 02 07:38:49 2009
Thread 1 advanced to log sequence 1732
Current log# 3 seq# 1732 mem# 0: E:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\REDO03.LOG
Sun Aug 02 07:44:14 2009
Error 0 in kwqmnpartition(), aborting txn
Sun Aug 02 07:45:14 2009
Error 0 in kwqmnpartition(), aborting txn
Sun Aug 02 22:00:26 2009
Thread 1 advanced to log sequence 1733
Current log# 1 seq# 1733 mem# 0: E:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\REDO01.LOG
Mon Aug 03 07:08:15 2009
Thread 1 advanced to log sequence 1734
Current log# 2 seq# 1734 mem# 0: E:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\REDO02.LOG
Mon Aug 03 09:28:23 2009
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 09:30:27 2009
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 11:42:47 2009
Errors in file e:\oracle\product\10.2.0\admin\orcl\udump\orcl_ora_6012.trc:
ORA-00600: internal error code, arguments: [qerghFetch:inc], [], [], [], [], [], [], []
Mon Aug 03 13:20:00 2009
Thread 1 advanced to log sequence 1735
Current log# 3 seq# 1735 mem# 0: E:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\REDO03.LOG
Mon Aug 03 16:07:07 2009
Errors in file e:\oracle\product\10.2.0\em_2\rdbms\trace\orcl_ora_4756.trc:
ORA-07445: exception encountered: core dump [ACCESS_VIOLATION] [unable_to_trans_pc] [PC:0x61F04AC9] [ADDR:0xC] [UNABLE_TO_READ] []
Mon Aug 03 16:07:11 2009
Process m000 died, see its trace file
Mon Aug 03 16:07:11 2009
ksvcreate: Process(m000) creation failed
Mon Aug 03 16:08:37 2009
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 16:10:40 2009
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 17:25:05 2009
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 17:27:11 2009
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 17:32:19 2009
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 17:33:24 2009
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 18:52:08 2009
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 18:54:09 2009
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 19:05:33 2009
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Mon Aug 03 19:09:02 2009
Errors in file e:\oracle\product\10.2.0\em_2\rdbms\trace\orcl_ora_5132.trc:
ORA-07445: exception encountered: core dump [ACCESS_VIOLATION] [unable_to_trans_pc] [PC:0x7C34126B] [ADDR:0x0] [UNABLE_TO_WRITE] []
Mon Aug 03 19:10:27 2009
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txn
Error 0 in kwqmnpartition(), aborting txnHi reshumakur
As this is your PRODUCTION system THEN_ The best help to offer in case of ORA-600, and ORA-7445 is to open SR with metalink. Submit with the SR the following
1- Alert log
2- Trace files (in ur case e:\oracle\product\10.2.0\admin\orcl\udump\orcl_ora_6012.trc: and e:\oracle\product\10.2.0\em_2\rdbms\trace\orcl_ora_4756.trc:)
3- Describe what was happening when you had these errors.
Try to avoid free help when you have ORA-600 and ORA-07445. This errors could be becuase of BUGS. Oracle Support will know this from the call stack in the trace file.
Then Do your best to patch 10.2.0.4 and the latest CPU patch.
Good Luck -
Decode failures using ora:getAttachmentContent or ora:getAttachmentProperty functoins
Hi,
I have a BPEL process that is started using the ums-email-adapter. The bpel process should abstract each attachment in the email and upload it to an ORacle BPM 12c ACM case.
In the basis I got this working, with pretty simple emails. But in other cases, where the email is more complex the abstraction of the attachment using the ora:getAttachmentContent or ora:getAttachmentProperty function fail with a error like:
<bpelFault><faultType>0</faultType><subLanguageExecutionFault xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable"><part name="summary"><summary>An error occurs while processing the XPath expression; the expression is ora:getAttachmentProperty('Content-Type', 'ReceiveMessage_ReceiveNotification_InputVariable','body', '/ns2:message/ns2:attachment[$AttachmentId]').</summary></part><part name="detail"><detail>XPath expression failed to execute.
An error occurs while processing the XPath expression; the expression is ora:getAttachmentProperty('Content-Type', 'ReceiveMessage_ReceiveNotification_InputVariable','body', '/ns2:message/ns2:attachment[$AttachmentId]').
The XPath expression failed to execute; the reason was: java.lang.RuntimeException: Failed to decode properties string ,att.contentId=1,Content-Type=multipart/related;
boundary "---- _Part_188_790028878.1418047669530",.
Check the detailed root cause described in the exception message text and verify that the XPath query is correct.
</detail></part><part name="code"><code>XPath expression failed to execute</code></part></subLanguageExecutionFault></bpelFault>
This exception is not even catched by the faultHandler, so I can't even simply ignore or handle it.
Has anyone an idea on what causes this and how to work around it? Or simply detect this case before calling the the ora:getAttachmentContent or ora:getAttachmentProperty functions?
Btw: I used the simple 'String' option in configuring the ums-email adapter. Tried with the Opaque option as well, but same issue there.
Thanks in advance.
Regards,
Martien
Message was edited by: Martien van den AkkerI found a workaround myself: Darwin-IT: ora:getAttachmentProperty: Failed to decode properties string.
-
SQL*Loader error ORA-00600 and ORA-26095
Hi all,
We have a problem with the SQL*Loader Utility. We use an 8i-Database (8.1.7) and SQL*Loader 9.2.0.1.0. We have no Trims or other functions active in the control file and do a direct path load.
It used to work properly until this morning.
Now we have the following errors (it is in German - but I can translate it):
Satz 90153: Abgelehnt - Fehler in Tabelle SCHEMA1.T_IMPORT.
ORA-00600: Interner Fehlercode, Argumente: [klaprs_50], [7], [], [], [], [], [], []
... about 50 equal errors
Specify SKIP=90171 when continuing the load.
SQL*Loader-926: OCI-Fehler; uldlm:OCIDirPathFinish für Tabelle SCHEMA1.T_IMPORT
ORA-26095: Nicht verarbeitete Stream-Daten vorhanden
SQL*Loader-2026: Der Ladevorgang wurde abgebrochen, weil er nicht fortgesetzt werden kann.
Specify SKIP=90171 when continuing the load.
Trnaslation:
00600 - Internal error code, arguments: ...
OCI-Fehler = OCI error
für Tabelle = for table
ORA-26095: Nicht verarbeitete Stream-Daten vorhanden = Non processed stream data existing
SQL*Loader-2026: Der Ladevorgang wurde abgebrochen, weil er nicht fortgesetzt werden kann. = Load process has been cancelled as it cannot be continued.
Has anyone got a clue?!?!?!Hi,
It's very clear that import 9i is for an import into 9i database.
Upgrade 8i to 9i indicates that we can make an export 8i from 8i database and import 9i into 9i database, but never use a tools like export from other version...
If you want import data from 9i database into 8i use exp tools 8i, and imp 8i.
I devise you to read Metalink note 132904.1 - compatibility matrix for export & import between different oracl version.
Nicolas. -
OBIA- Connection Problems ORA-00604 and ORA-02248
Hi,
i have an installation OBI Server, Presentation Services, and Scheduler on RH Linux 64Bit, Oracle 11 DB, OBI Admin on Win xp,
in online mode when i try import from Database i got following errors:ORA-00604 and ORA-02248
but i can Create ibots and i see with sqlplus the created ibots in the DB.
have anyone an idea, why the scheduler can read and write in the DB, but i cant read via Admintool, i try to connect the same db)
Thxcan you connect from Windows box using SQLPLUS? yes i can connect
are you using native connection in Admin tool or ODBC? I try to use Native (OCI) to connect the Oracle DB
check the above to eliminate the connectivity issues. -
Oracle/PLSQL: ORA-00932 ErrorError: ORA-00932: inconsistent datatypes
I am getting this error in a PL/SQL package, using SQL using the NVL function.
Oracle/PLSQL: ORA-00932 ErrorError: ORA-00932: inconsistent datatypes. Cause: You tried to perform an operation between two different datatypes, but the datatypes are not compatible.
I do not get this error on a 10.2.0.4 instance of the database running in Windows.
Anyone come accross this type of issue in 11g Rel.2 or after migrating from 10g to 11g??
Thanks.Dear user520935,
What are the contents of the package? Where do you exactly get that error?
http://ora-00932.ora-code.com/
Have you checked the metalink about it? There are lots of articles about it.
Ogan -
ORA-01405: and ORA-08180
Hello All,
I have this mapping the gets deployed perfectly with no errors nor warning during the deployments. The problem is that whenever this mapping gets started or executed it fires the following warnings :
Warning
ORA-01405: fetched column value is NULL
Warning
ORA-08180: no snapshot found based on specified time
I don't actually know what does such warning mean so if anyone could give a hand i'd be grateful.
Regards,
HossamP.Sam wrote:
Hello All,
I have this mapping the gets deployed perfectly with no errors nor warning during the deployments. The problem is that whenever this mapping gets started or executed it fires the following warnings :
Warning
ORA-01405: fetched column value is NULL
Warning
ORA-08180: no snapshot found based on specified time
I don't actually know what does such warning mean so if anyone could give a hand i'd be grateful.
Regards,
HossamThe Oracle docs note this on the ora-01405 error*:
ORA-01405 fetched column value is NULL
Cause: The INTO clause of a FETCH operation contained a NULL value, and no indicator was used. The column buffer in the program remained unchanged, and the cursor return code was +2. This is an error unless you are running Oracle with DBMS=6, emulating version 6, in which case it is only a warning.
Action: You may do any of the following:
* Use the NVL function to convert the retrieved NULL to another value, such as zero or blank. This is the simplest solution.
* Use an indicator to record the presence of the NULL. You probably should use this option when you want a specific action to be taken when a NULL arises.
* Revise the cursor definition so that no columns possibly containing NULL values are retrieved.
ORA-01405 is thrown when you attempt to execute FETCH, which was returned as a NULL value, but there was no indicator in use. If you are using Oracle DBMS=6 (version 6) ORA-01405 is only a warning.
You might try resolving ORA-01405 by substituting a value with NVL function when a NULL value appears, or simply construct your cursor so that NULL values are not returned (you may also specify that columns with NULL values are not received).
The error ORA-8180 is reported when the time which is specified, is
mapped to a SCN which is beyond the bounds of a valid scn. Most likely
the specified time corresponds with a date which is more than 5 days ago
(server uptime). You can never flashback more than 5 days ago (server
uptime), irrespective of UNDO_RETENTION.
SOLUTION: Specify a more recent date to flashback. E.g.:
exp scott/tiger file=exp_flash.dmp log=exp_flash.log tables=flash
flashback_time='"2004-06-12 13:24:26"' -
Hi All,
can i make sure if i get ora-121 or ora-01034 errors then the database is down.
As my database is getting down on every 3rd sunday of a month.
Thanks & Regards
MeghHi..
>
Error: ORA-00121 (ORA-121)
Text: SHARED_SERVERS specified without DISPATCHERS
Cause: A definition for SHARED_SERVERS was specified in the INIT.ORA
file, but no definition for DISPATCHERS was specified. Without a
value for DISPATCHERS, shared servers will never be used.
Action: Add a definition for DISPATCHERS in the INIT.ORA file (or take
out the definition for SHARED_SERVERS, if shareds servers are not
being used).
>
For ORA-00121 refer to Metalink Doc ID: Note:235608.1
>
Error: ORA 1034
Text: Oracle not available
Cause: Oracle was not started up.
Possible causes include the following:
The SGA requires more space than was allocated for it.
The operating system variable pointing to the instance was improperly
defined.
Action: Refer to accompanying messages for possible causes and correct the
problem mentioned in the other messages.
Retry after Oracle has been initialized.
If Oracle has been initialized, then on some operating systems, verify
that Oracle was linked correctly.
See the platform-specific Oracle documentation.
>
HTH
Anand -
How to write the listener.ora and tnsnames.ora
Hi, there
I store my oracle database in the machine A. In the machine B,
it only install the oracle without create database. How should
I write the
listener.ora and tnsnames.ora? So that the machine B could
acces the database which store in the machines A.
Could you give me a simple example and with some description.
Thanks you very much!!
nullwrjih (guest) wrote:
: Hi, there
: I store my oracle database in the machine A. In the machine B,
: it only install the oracle without create database. How should
: I write the
: listener.ora and tnsnames.ora? So that the machine B could
: acces the database which store in the machines A.
: Could you give me a simple example and with some description.
: Thanks you very much!!
1 - you can simply copy the files from the server to the client.
If they are correct, it must work fine
2 - Follow the examples inside the
$ORACLE_HOME/network/admin/samples
3 - Follow my examples:
I will try to make it simple:
The server must have the listener.ora. The client does not need
it if you don't have a database there.
I cannot tell you what is mandatory in the file, and what is not.
The listener.ora has the interface (addr or name)
to listen, the port/proto, and some info about your database
($ORACLE_HOME and Name).
#--- Listener.ora -- my minimal settings ---
LISTENER =
(ADDRESS_LIST =
(ADDRESS=(PROTOCOL= TCP)(Host=Server)(Port= 1521))
(ADDRESS=(PROTOCOL= IPC)(KEY = ORCL))
STARTUP_WAIT_TIME_LISTENER = 1
CONNECT_TIMEOUT_LISTENER = 10
TRACE_LEVEL_LISTENER = OFF
TRACE_LEVEL_CLIENT=OFF
SID_LIST_LISTENER =
(SID_LIST=(SID_DESC=
(SID_NAME = SACS)
(ORACLE_HOME=/oracle/805)))
#---- end of listener.ora ---
Both machines can, and should have similar TNSNAMES.ORA:
tnsnames.ora has the address or name of the server, and the Name
of the database you wish to connect to.
#--- tnsnames.ora --- minimal.
ORCL = (DESCRIPTION =
(ADDRESS_LIST=(ADDRESS = (PROTOCOL = TCP)(Host=Server)(Port =
1521)))
(CONNECT_DATA = (SID = SACS)))
#--- end of tnsnames.ora ---
And finally sqlnet.ora, that is very usefull for setting secure
networks or
just logging for looking for errors. You can also set your
keepalive timeout.
#--- sqlnet.ora
TRACE_LEVEL_CLIENT = OFF
names.directory_path = (TNSNAMES)
SQLNET.EXPIRE_TIME = 10
#-- end of sqlnet.ora --
null -
Work around/Alternate solution for Oracle error ORA-01460 and ORA-02063
After the installation of Oracle.DataAccess version 2.111.7.20, I get the following error.(the code worked fine with Oracle.DataAccess version 9.2.0.700 )
I have attached the error as well as the sample code.
ORA-01460 and ORA-02063 are known bugs in the new ODP but would like to know if there is any Work around/Alternate solution for this problem(other than
the use of stored procs)..
Thanks!
Error:
ORA-01460: unimplemented or unreasonable conversion requested
ORA-02063: preceding line from BSREAD_STAGINGRO at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure, Boolean bCheck)
at Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode, OracleConnection conn, String procedure, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, Boolean bCheck)
at Oracle.DataAccess.Client.OracleCommand.ExecuteReader(Boolean requery, Boolean fillRequest, CommandBehavior behavior)
at Oracle.DataAccess.Client.OracleCommand.ExecuteReader()
SampleCode
private bool isValidFieldData(string clientName, string fieldNumber, string uniqueID, string clientID)
using (OracleConnection mBSConnection = new OracleConnection(mBSConnectionString))
OracleDataReader oRdr = null;
OracleCommand Valid_FieldData_Command = null;
try
Valid_FieldData_Command = new OracleCommand();
Valid_FieldData_Command.Connection = mBSConnection;
Valid_FieldData_Command.CommandText = "SELECT uniqueid FROM EXTDB.BSData WHERE agencyid = :agencyid and agencyname=:agencyname AND fieldnumber =:fieldnumber AND uniqueid = :uniqueid";
Valid_FieldData_Command.Parameters.Add(":agencyid", OracleDbType.Varchar2, 255).Value = agencyID;
Valid_FieldData_Command.Parameters.Add(":agencyname", OracleDbType.Varchar2, 255).Value = agencyName;
Valid_FieldData_Command.Parameters.Add(":fieldnumber", OracleDbType.Varchar2, 255).Value = fieldNumber;
Valid_FieldData_Command.Parameters.Add(":uniqueid", OracleDbType.Varchar2, 255).Value = uniqueID;
mBSConnection.Open();
oRdr = Valid_FieldData_Command.ExecuteReader(); ->Error occurs here
The error occurs whenever the length of any of the parameter is increased. But there is no specific length where it is breaking down.
For example in this case, it breaks down with the given error if
agencyID > 8
agencyName > 6
fieldNumber > 9
uniqueid > 6The problem was mapping input parameter type.
VARCHAR2-type mapping input parameter works with String-type PF parameter. But CHAR-type won't.
Maybe you are looking for
-
Dumb questions on oracle database jobs scheduling: Assume we are scheduling database jobs with all default values( except what to run,when to run) job_queue_processes=1000 1) If a job is scheduled to run every 5 minutes. Currently if the job is takin
-
Windows 8.1 - safe to delete "Browser Choice"?
Windows 8.1 The European Union ordered Microsoft to include a program in the Windows OS sold in Europe. This program makes a pop up to invite PC users to use browsers different than Internet explorer. This is not a malware or adware issue. This obli
-
Firefox Mobile 4 beta 3 (and pre-beta 4) fails to install on Archos 101 Tablet using Android 2.1 Eclair with no specific error. Is this a know issue or has someone been able to successfully install?
-
Suddenly, CS6 version of Adobe Illustrator is not opening,. Getting an error message that it requires a "legacy version of Java Runtime." Talked with Apple Customer Service about this and they learned that Oracle is no longer making that version avai
-
HT4413 Time Machine- moving files onto a new mac- compatibility issues?
If you use Time Machine to load files from a mac running snow leopard to a new mac running lion, will everything work normally in lion thereafter on the new mac? It won't try to revert the new computer to snow leopard, will it? Also, I want to clear