Home » RDBMS Server » Server Utilities » Oracle10g imp tables containing LOB (Oracle 10.2.0.4 linux)
Oracle10g imp tables containing LOB [message #483603] |
Tue, 23 November 2010 07:29 |
|
junwen
Messages: 12 Registered: November 2010 Location: Malaysia
|
Junior Member |
|
|
Hi there, I am still very new to Oracle and I have an unsolved issue, google a lot but still can't figure it out. Would appreciate any thoughts.
A full database exported from Oracle 10.2.0.4 and import back to the same instance with different user/schema name. The whole database is in single tablespace, SOURCE_TS. Since SOURCE_TS already exist in the same instance. A brand new user and its default tablespace will be created before the import. SOURCE_TS cannot be access by this new user.
Since my database has many tables containing LOB column, those LOB tables will be pre-create before the import start. Initially, those LOB tables imported successfully but at one stage, it fails. Subsequent LOB tables all failed since then.
Quote:IMP-00017: following statement failed with ORACLE error 1950:
"CREATE TABLE "I43NAV_LOC_VEC" ("VID" NUMBER NOT NULL ENABLE, "BLK_NO" N"
"UMBER NOT NULL ENABLE, "DATATYPE" NUMBER, "VEC_STORAGE_TYPE" VARCHAR2(12) N"
"OT NULL ENABLE, "REL_PATH" VARCHAR2(256), "BYTES_USED" NUMBER, "BLOB_DAT"
"A" BLOB, "BFILE_DATA" BFILE) PCTFREE 10 PCTUSED 0 INITRANS 1 MAXTRANS 255 "
"STORAGE(INITIAL 81920 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT) TA"
"BLESPACE "SOURCE_TS" LOGGING NOCOMPRESS LOB ("BLOB_DATA") STORE AS ("
"TABLESPACE "SOURCE_TS" ENABLE STORAGE IN ROW CHUNK 16384 PCTVERSION 1"
"0 NOCACHE LOGGING STORAGE(INITIAL 81920 FREELISTS 1 FREELIST GROUPS 1 BUFF"
"ER_POOL DEFAULT))"
IMP-00003: ORACLE error 1950 encountered
ORA-01950: no privileges on tablespace 'SOURCE_TS'
I am not able to find out any reason why it fails, since out of 150, 80 of my tables containing LOB column were imported correctly suggested that my imp parameters were correct.
It doesn't seems to be my backup file problem too, I tried twice and the first LOB table failed is not the same with the previous attempts.
Initially I thought might be quota, but unlimited quota to the new tablespace is granted. Even if it is not granted, the error returned would be complaining about quota limit reached in the new tablespace, not SOURCE_TS.
If this is not about disk space or quota issue, in what condition the imp will tries to create table in SOURCE_TS, instead of my new tablespace? I will need to understand the IMP utility logic to sort this out.
Thanks for your time.
-
Attachment: log.txt
(Size: 0.78KB, Downloaded 1706 times)
[Updated on: Tue, 23 November 2010 07:31] Report message to a moderator
|
|
|
|
|
Re: Oracle10g imp tables containing LOB [message #483610 is a reply to message #483607] |
Tue, 23 November 2010 08:03 |
|
Mahesh Rajendran
Messages: 10708 Registered: March 2002 Location: oracleDocoVille
|
Senior Member Account Moderator |
|
|
It is the intended behavior dictated by
Quote:LOB ("BLOB_DATA") STORE AS ("
"TABLESPACE "SOURCE_TS" ENABLE
During import, Oracle will try to write to Source_TS for lobsegments.
Extract the ddl, pre-create the tables with tablespace_name you want.
Import with ignore=y.
or
just use datapump with remap options.
[Updated on: Tue, 23 November 2010 08:04] Report message to a moderator
|
|
|
|
|
Re: Oracle10g imp tables containing LOB [message #483646 is a reply to message #483613] |
Tue, 23 November 2010 18:53 |
|
junwen
Messages: 12 Registered: November 2010 Location: Malaysia
|
Junior Member |
|
|
Can you please correct me if I am wrong in the following concept?
When I exp my tables, the oracle dump file contained DDL to re-create ALL those tables, constraints, indexes etc, with destination tablespace SOURCE_TS. (well, I see that in DDL produced with INDEXFILE)
When I import the Oracle dump file to another tablespace, with IGNORE=Y and pre-created LOB tables in new tablespace (not old tablespace, user should not write into SOURCE_TS, so no permission granted), it should ignore that DDL to create in SOURCE_TS, instead it should creates those tables in default tablespace, which is my new tablespace.
That is happening with all my simple tables and some of my LOB tables, except the other half of my LOB tables. The entire tables are in a single tablespace.
One possible cause is, of course, like you said, those failed LOB tables, have not been pre-created in my New Tablespace. That is very much possible, and is the only reason I can thought of.
But since it is created by a program, I have no way to intercept in between to check if half of tables are pre-created before the import starts (the program pre-create those tables and run the import in a single session).
I am pursuing the issue with the program vendor currently, but would like to know any other possible reason imp tries to create table in original tablespace as in DDL, apart from pre-create LOB tables.
I am trying to learn how the IMP tool logic works, like "if no pre-create LOB table lies around for default tablespace, I will try to create the table in original tablespace, but I will fail if that tablespace doesn't exist or I have not granted create table role".
Manish, what you were saying is, only when LOB tables were not pre-created in default tablespace, the imp session will tries to create LOB tables in its original tablespace.
Imp session not lying, so that is the only cause, I guess?
[Updated on: Tue, 23 November 2010 19:08] Report message to a moderator
|
|
|
|
|
|
|
|
Re: Oracle10g imp tables containing LOB [message #487773 is a reply to message #483603] |
Fri, 31 December 2010 01:04 |
|
junwen
Messages: 12 Registered: November 2010 Location: Malaysia
|
Junior Member |
|
|
I got the issue sorted out. This is not an Oracle issue, rather Java Development issue.
Some of the LOB tables indeed didn't get created, while parsing from DDL file obtained via SHOW=Y import.
The parsing was done with Java string buffer.
Thanks for all the hands and guidance.
|
|
|
Goto Forum:
Current Time: Mon Dec 23 10:47:07 CST 2024
|