Tablespace reorg
Hi,
I want to reorg my database. I am working on ECC6 ,oracle 10g & AIX operating System.I have reorg tablespaces using the option successfully.
brspace -f tbreorg -s psapddicd -t "*" -p 4
But table have long field can not reorg with this option. And if i try to change the LONG field to LOB field.Than it will impact on performance . Beacuse we have no option to convert LOB field to LONG field after reorg.
Thanks
Hi,
I have start again with the following option
1:- Create a new tablespace using the command
brspace -f tscreate -t PSAPPRD700new -s 20G -a yes -m 20G
-i 1024M -l PSAPPRD700
I have increass the size of new tablespace up to 75 GB, its 30 Gb bigger than old tablespace.
2:- After that i start the online reorg using
brspace -f tbreorg -s PSAPPRD700 -t "*" -n PSAPPRD700new -p 4
But after that i get the following error
BR0301W SQL error -12091 at location BrReorgCheck-5, SQL statement:
'BEGIN DBMS_REDEFINITION.CAN_REDEF_TABLE (UNAME => '"SAPPRD"', TNAME => '"AAB_ID_PROPT"', OPTIONS_FLAG => DBMS_REDEFINITION.CONS_USE_PK); END;'
ORA-12091: cannot online redefine table "SAPPRD"."AAB_ID_PROPT" with materialized views
ORA-06512: at "SYS.DBMS_REDEFINITION", line 137
ORA-06512: at "SYS.DBMS_REDEFINITION", line 1478
ORA-06512: at line 1
BR1111I Reorganization of table SAPPRD.AAB_ID_PROPT will be skipped
Now can you please suggest me some solution .
I am performing reorg on oracle 10g
Thanks & Regards
Rudra
Similar Messages
-
Migration LONG to LOB in manual space management tablespaces
Hi everyone,
We have Netweaver 7.0 and Oracle 11g and we are considering to migrate our manual tablespaces to ASSM. The first problem we've found is we can't do that online due to the LONG data type. So we decided to migrate LONG to LOB first. Note 835552 says that for Oracle version 11g the conversion is from LONG to SECUREFILE. But we follow seeking notes and in 1426979 (Oracle 11g: SecureFiles - The new way to store LOB data) one of the prerequisites for the conversion is to use ASSM tablespaces.
At this point, we can't migrate (online) to ASSM due to LONG data and neither can migrate to SECUREFILE due to the ASSM.
My question is: is it possible to make the migration from LONG to SECUREFILE specifying in the brspace a new tablespace with ASSM?
Thanks in advanced.Hello
It is in fact possible to reorganize segment to a specific target tablespace using brspace option -n|-newts
brspace -u / -f tbreorg -a long2lob -o sapsr3 -s <source_tablesapce> -t allsel -n <target_tablespace_in_ASSM>
It is odd that in 11g you are not in ASSM, so you upgrade to that version and never performed tablespace reorg ?
620803 - Oracle 9i: Automatic Segment Space Management
The new ASSM function is available as of Oracle Release 9i. As of Oracle 10g, ASSM is already contained in the standard system, and new tablespaces are by default created as ASSM tablespaces.
Regards -
What are the step involved in online table reorg in oracle 10g?
Hi All,
Could you please provide the step by step how to perform the online table reorg ?
Thaks
BalaEtbin wrote:
You mean http://docs.oracle.com/cd/B19306_01/appdev.102/b14258/d_redefi.htm#ARPLS042 ?
Regards
EtbinNo, not table redefinition, I think he means a tablespace reorg as you can do through Enterprise Manager. -
Hi
I have saparate tablespace for data and index....(oracle9i)
allocated size of my data tablespace is 8 gb, but used is only 2 gb(from dba_segments),
if i m trying to resize the datafile by 3 gb it it giving error saying
ORA-03297: file contains used data beyond requested RESIZE value
i think this is because of HWM is set high...m i correct...
to solve this problem i'll take tablespace dump, create new tablespace with size 2 gb and impot the dump...(is there any another way to solve this problem)
so my que. is wat happend to my indexes and constraints which are in different tablespace.....?Since you are 9i you should use the ALTER TABLE MOVE TABLESPACE method, create an intermediate tablespace to hold the data or simply move all tables to new tablespace.
alter table scott.table1 move tablespace new_tablespaces;remember to rebuilt indexes after move, this is table care the index tablespace reorg too.
Also remember recollect statistics of schema -
ORA-1653: unable to extend table PERFSTAT.STATS
Hi there,
I know it's Friday and by the end of the week we normally are not that alert anymore.
However now we have a very puzzling problem, one that leaves two DBA's very amazed.
This morning our alert-log of a 9.2.0.8 database on AIX 5.3 showed:
ORA-1653: unable to extend table PERFSTAT.STATS in tablespace TOOLSEasy, one would say. Extend the tablespace and you're done.
However the tablespace is on autoextend, not even mentioned that it has 2.5Gb of free space.
It is also "Locally Managed", with uniform extent size of 16Kb and manual "segment space management"
The index of this table is in the same tablespace.
The storage parameters are set to "unlimited" possibilities.
A manual
exec statspack.snapresults in the same error where as a
create table statstest as select * from stats$sqltext ; works fine. The mentioned source table here is the one which seems unable to extend due to the "tablespace restrictions"
Some storage parameters:
CREATE TABLE "PERFSTAT"."STATS$SQLTEXT" (
"HASH_VALUE" NUMBER NOT NULL ENABLE,
"TEXT_SUBSET" VARCHAR2 (31) NOT NULL ENABLE,
"PIECE" NUMBER NOT NULL ENABLE,
"SQL_TEXT" VARCHAR2 (64),
"ADDRESS" RAW (8),
"COMMAND_TYPE" NUMBER,
"LAST_SNAP_ID" NUMBER,
CONSTRAINT "STATS$SQLTEXT_PK" PRIMARY KEY
("HASH_VALUE", "TEXT_SUBSET", "PIECE
USING INDEX
PCTFREE 10 INITRANS 2 MAXTRANS 255
STORAGE
INITIAL 1048576
NEXT 1048576
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
FREELISTS 1
FREELIST GROUPS 1
BUFFER_POOL DEFAULT
) TABLESPACE "TOOLS"
ENABLE
PCTFREE 5
PCTUSED 40
INITRANS 1
MAXTRANS 255
NOCOMPRESS
LOGGING
STORAGE (INITIAL 5242880
NEXT 5242880
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
FREELISTS 1
FREELIST GROUPS 1
BUFFER_POOL DEFAULT)
TABLESPACE "TOOLS"Can this be some kind of Data Dictionairy corruption ??virendra.k wrote:
The next extent clause in creation script says that it is required to have at least 1G of contiguous memory. But the satement fails which means that a chunk of this size cannot be allocated. The situation may arise due to fragmentation of tablespace. See metalink doc id [1020182.6|https://metalink2.oracle.com/metalink/plsql/f?p=130:14:9000433346754441541::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,1020182.6,1,0,1,helvetica] if the largest free chunk >= 1G. Other wise increase the size of tablespace. It may help you.
I don't understand the result of 1G you calculated.
I only see: NEXT 1048576 of the primary key, which is 1M and NEXT 5242880 ( 5M) of the table itself.
However it the Note lead me to the solution.
The largest piece of contiguous free space in the tablespace is, according to this Note:
TABLESPACE NAME CONTIGUOUS BYTES
TOOLS 3,407,872 ==> 3Mb
TOOLS 3,407,872
TOOLS 3,407,872
TOOLS 3,301,376
TOOLS 3,194,880
TOOLS 3,194,880
TOOLS 3,194,880
TOOLS 3,194,880
TOOLS 3,088,384
So I executed the following:
SQL> alter table stats$sqltext storage (next 1m);And subsequently:
SQL> exec statspack.snap;Which now succeeds !!
Conclusion: Tablespace REORG needs to be planned.
One more strange thing however:
I altered the NEXT_EXTENT size back to 5M, and again the statspack.snap now works OK.
It must be the either a background COALESCE that solved the problem, or the (maybe existing) corruption in the dictionary is now fixed/gone
Thanks for the assistance -
Help needed with BRtools/sapdba!!!
Hi SAP gurus!!
We have to perform reorganization as part of archiving post processing activity.
pls refer the following link:
http://help.sap.com/saphelp_nw70/helpdata/EN/8d/3e4e81462a11d189000000e8323d3a/frameset.htm
It says" If data has been archived or simply deleted and the associated tables were accessed via an index, then index should be reorganized"
1) How we come to know that data is accessed via index?
2)Which is the less time consuming among the below ?
1- table space reorg ; 2- index reorg; 3- table reorg
3) After performing the delete action in archiving will the space gain shows automatically in DB02 or do we need to do a "refresh action" .I heard about update statistics is this is that refresh action (assumed). and how to do this from SAP level( Any Tcode)?
4)We have 4.7kernel rel 640 and oracle 10.2 on AIX , Which is the best applicable? A)BRTOOLS B)sapdba.
5)Which one can be used online(Avoiding downtime) i mean SAPDBA/Brtools
and if downtime is necessary . How to roughly estimate the needed downtime?
6)Can this(reorg) be done through any Tcode and is it(doing with Tcode) good than using SAPDBA/Brtools?
Your responses are highly appreciated
Points would be liberally rewarded.
Thanks a lot in advance!!> We have to perform reorganization as part of archiving post processing activity.
Ok, can be a good idea.
> It says" If data has been archived or simply deleted and the associated tables were accessed via an index, then index should be reorganized"
Well, that's by far not all "it says".
Basically when you delete/archive data the storage structures inside the oracle database (tables and indexes) won't release allocated space automatically.
Therefore, depending on what you do with these tables/indexes it's a good idea to release this space - this is called reorganisation.
> 1) How we come to know that data is accessed via index?
Pretty simple - check the explain plan of the SQL that access the table.
How you can do this? There are many ways: via shared cursor cache (ST05), via SQL Trace (ST05) ...
> 2)Which is the less time consuming among the below ?
> 1- table space reorg ; 2- index reorg; 3- table reorg
Think about it, yourself!
Tablespace reorg means: take all segments (tables and indexes) in a specific tablespace and reorganize them.
Sound like a lot of work to do and usually it is.
Index reorg means: take one or more indexes and rebuild them. This is usually pretty fast, but of course depends on your data.
Table reorg means: you guess it - yes! Take one or more tables and reorganize it.
As it is necessary to rebuild all indexes on the reorganized tables, the amount of work to do here it bigger than for index reorg but usually still far smaller than for the tablespace reorg.
> 3) After performing the delete action in archiving will the space gain shows automatically in DB02 or do we need to do a "refresh action" .I heard about update statistics is this is that refresh action (assumed). and how to do this from SAP level( Any Tcode)?
As already written: the space won't be released until you reorganize. You don't have to run update statistics to update these information. Just reorganize.
> 4)We have 4.7kernel rel 640 and oracle 10.2 on AIX , Which is the best applicable? A)BRTOOLS B)sapdba.
There is no choice. SAPDBA is not supported for 10g and is deprecated a very loong time now!
BRTOOLS are the tools for the SAP Oracle DBA.
> 5)Which one can be used online(Avoiding downtime) i mean SAPDBA/Brtools
> and if downtime is necessary . How to roughly estimate the needed downtime?
BRTOOLS can reorganize all tables that do not contain LONG RAW fields online.
To estimate the reorganization time for a offline reorg you can export the table and import it into another schema.
> 6)Can this(reorg) be done through any Tcode and is it(doing with Tcode) good than using SAPDBA/Brtools?
No, there is no such transaction. Use the BRTOOLS.
Please test out the procedure on a test system before you try it out on the production instance.
Check [SAP Note 646681 Reorganizing tables with BRSPACE|https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes/sdn_oss_bc_db/~form/handler%7b5f4150503d3030323030363832353030303030303031393732265f4556454e543d444953504c4159265f4e4e554d3d363436363831%7d]
before doing anything...
And perhaps you may want to visit the ADM505 SAP course. It covers reorganization as well as the usage of the BRTOOLS.
regards,
Lars -
Taking free space out after TDMS copy
Hello Experts,
I have performed a TDMS copy from Production to one of our quality systems. Since I have taken only 6 months data the size of our quality system Database is reduced which was previously equal to Production.
1)At present around 1 TB of space is free in PSAPSR3 tablespace whichI want to bring to OS level filesystem. I do not wantto go for whole tablespace reorg due to some specific reasons like large no of tables with Long fields, space issues etc.
If anyone of you have faced a similarsituation pleasedo guide.
Regards,
UmeshHello Rajesh,
I already found tables for reorg and tried reorg for some of those tables , but the space released after table reorg is at tablespace level and not at OS file system. So again the issue remains the same to pull out space from tablespace without reorg.
I have searched various forums but everthing at the end comes to tablespace reorg . Since I have space contraints , I am searching for workaround for this.
Regards,
Umesh. -
Hi all, i just upgrade s ystem from 4.7 to ECC6 , its on AIX with oracle 10.0.2 .
i notice the spam take very long time to run
to run this import queue, it take more than 6 hours
SAPKB70012
SAPKA70012
SAPKIPYJ7C
SAPKW70013
SAPKNA7009
SAPKH60009
SAPKH60010
topas to monitor OS performance also did not show anything :
EVENTS/QUEUES FILE/TTY
Wed Jan 16 11:12:41 2008 Interval: 2 Cswitch 6088 Readch 558.7K
Syscall 16633 Writech 417.3K
Kernel 4.6 |## | Reads 2909 Rawin 0
User 42.2 |############# | Writes 2984 Ttyout 170
Wait 2.8 |# | Forks 0 Igets 1
Idle 50.4 |############### | Execs 0 Namei 25
Runqueue 0.5 Dirblk 5
Network KBPS I-Pack O-Pack KB-In KB-Out Waitqueue 0.5
lo0 1059.2 2821.3 2821.3 529.6 529.6
en0 0.9 9.9 1.0 0.7 0.3 PAGING MEMORY
en1 0.0 0.0 0.0 0.0 0.0 Faults 43 Real,MB 7792
Steals 0 % Comp 67.7
Disk Busy% KBPS TPS KB-Read KB-Writ PgspIn 0 % Noncomp 33.1
dac0 0.0 107.2 13.4 95.3 11.9 PgspOut 0 % Client 33.1
hdisk8 0.0 59.6 7.4 59.6 0.0 PageIn 27
hdisk3 0.0 31.8 4.0 31.8 0.0 PageOut 4 PAGING SPACE
Sios 31 Size,MB 20480
Name PID CPU% PgSp Owner % Used 0.6
oracle 929902 42.6 6.6 orat01 NFS (calls/sec) % Free 99.3
R3trans 897100 6.0 23.7 t01adm ServerV2 0
topas 708622 0.4 1.8 root ClientV2 0 Press:
nmbd 282762 0.0 0.8 root ServerV3 0 "h" for help
java.bin 958516 0.0 44.2 orat01 ClientV3 0 "q" to quit
and there is 1 R3trans running
R3trans -w /usr/sap/trans/tmp/SAPIB70012.T01 /usr/sap/trans/tmp/SAPKKB70012.T01
Any idea how to improve it ? because i have another system on AIX but using DB2, it having less memory and cpu , still faster when doing SPAMHi,
After upgrade, before running patches its always advisable to run Tablespace REORG.
Regards,
Siddhesh -
Issues with Reorg on a tablespace from DB13
Hello,
System: SAP DB2 on z/OS
When we schedule 'Reorg on one R/3 tablespace' in DB13 for more than 1 tablespace with 5 minute (Say 1st job scheduled at 7:00 and 2nd at 7:05) interval the reorg fails for the second job with the following error.
DSNU180I -XXXA DSNUGUCC - UTILITY IS NOT COMPATIBLE WITH THE REORG TABLESPACE UTILITY
UTILID = PA002631, OBJECT = SY00MAP.QX000001
The object in contention is the temporary QT mapping tables created for online reorg.
The above QX000001 indexspace is used for the first reorg job (07:00) and the same QX000001 ndexspace is picked for the second reorg job (07:05) .
Is there a way to prevent this ?
This issue exists in SAP 6.20 and 7.00 systems
Thanks,
Aravinthanthis means that you had a utility left out there in stopped status. this error probably occurred due to a previous utility that did not complete or failed and was not terminated.
-
Trying to use brspace to do a reorg
I am trying to reorg ALL the tables in one tablespace at once:
brspace -f tbreorg -a reorg -i psapfact2i -m offline -n psapfact2d -s psapfactd -t "*"
I get this back:
BR1001I BRSPACE 7.00 (33)
BR1002I Start of BRSPACE processing: sdxtkjdu.tbr 2008-04-22 11.57.42
BR0484I BRSPACE log file: /oracle/BQA/sapreorg/sdxtkjdu.tbr
BR0280I BRSPACE time stamp: 2008-04-22 11.57.45
BR1009I Name of database instance: BQA
BR1010I BRSPACE action ID: sdxtkjdu
BR1011I BRSPACE function ID: tbr
BR1012I BRSPACE function: tbreorg
BR0280I BRSPACE time stamp: 2008-04-22 11.57.47
BR1039I Selecting information about tables and indexes...
BR0285I This function can take several seconds/minutes - be patient...
BR0280I BRSPACE time stamp: 2008-04-22 11.57.49
BR0814I Number of tables/partitions in schema of owner SAPR3: 15948/1024
BR0280I BRSPACE time stamp: 2008-04-22 11.57.56
BR0815I Number of indexes/partitions in schema of owner SAPR3: 21106/6021
BR0280I BRSPACE time stamp: 2008-04-22 11.57.56
BR0660I List display 352 - no selection possible
List of tables for reorganization
Pos. Owner Table Pt. DgPk. Rows Space[KB] Data[KB:%]
1 - SAPR3 /BI0/E0BWTC_C02 NO 1 0 72 0:0
2 - SAPR3 /BI0/E0BWTC_C03 NO 1 0 72 0:0
3 - SAPR3 /BI0/E0BWTC_C04 NO 1 0 72 0:0
4 - SAPR3 /BI0/E0BWTC_C05 NO 1 0 72 0:0
5 - SAPR3 /BI0/E0BWTC_C06 NO 1 0 72 0:0
6 - SAPR3 /BI0/E0BWTC_C07 NO 1 0 72 0:0
7 - SAPR3 /BI0/E0BWTC_C09 NO 1 0 72 0:0
8 - SAPR3 /BI0/E0BWTC_C11 NO 1 0 72 0:0
9 - SAPR3 /BI0/E0PCA_C01 YES 1 0 584 0:0
10 - SAPR3 /BI0/E0PCA_C02 NO 1 0 72 0:0
11 - SAPR3 /BI0/F0BWTC_C02 YES 1 5405 1040 713:69
12 - SAPR3 /BI0/F0BWTC_C03 YES 1 0 72 0:0
13 - SAPR3 /BI0/F0BWTC_C04 YES 1 0 72 0:0
14 - SAPR3 /BI0/F0BWTC_C05 YES 1 128 144 6:4
15 - SAPR3 /BI0/F0BWTC_C06 YES 1 0 72 0:0
16 - SAPR3 /BI0/F0BWTC_C07 YES 1 0 72 0:0
17 - SAPR3 /BI0/F0BWTC_C09 YES 1 0 72 0:0
18 - SAPR3 /BI0/F0BWTC_C11 YES 1 0 72 0:0
19 - SAPR3 /BI0/F0PCA_C01 YES 1 9985560 715472 565588:79
20 - SAPR3 /BI0/F0PCA_C02 YES 1 3964200 144840 100654:69
Press <Rtn> - scroll, 'c' - cont, 'h' - header, 's' - stop ...
21 - SAPR3 /BIC/E100000 NO 1 289140 18440 13836:75
22 - SAPR3 /BIC/E100001 NO 1 147720 9224 7069:77
23 - SAPR3 /BIC/E100002 NO 1 587930 50184 40191:80
24 - SAPR3 /BIC/EMMPUR_C01 NO 1 0 72 0:0
25 - SAPR3 /BIC/EZCO_C50 NO 1 0 72 0:0
26 - SAPR3 /BIC/EZCO_C51 NO 1 0 72 0:0
27 - SAPR3 /BIC/EZECCS_C04 NO 1 0 72 0:0
28 - SAPR3 /BIC/EZMMPURC01 NO 1 0 72 0:0
29 - SAPR3 /BIC/EZPCA_C03 YES 1 0 488 0:0
30 - SAPR3 /BIC/EZPURC001 YES 1 0 2664 0:0
31 - SAPR3 /BIC/EZPURC002 YES 1 0 296 0:0
32 - SAPR3 /BIC/EZQM_C50 YES 1 0 16488 0:0
33 - SAPR3 /BIC/EZRC_C50 NO 1 0 72 0:0
34 - SAPR3 /BIC/EZRC_C51 YES 1 0 488 0:0
35 - SAPR3 /BIC/F100000 YES 1 0 72 0:0
36 - SAPR3 /BIC/F100001 YES 1 0 72 0:0
37 - SAPR3 /BIC/F100002 YES 1 0 72 0:0
38 - SAPR3 /BIC/FMMPUR_C01 YES 1 590150 53328 42648:80
39 - SAPR3 /BIC/FZCO_C50 YES 1 478120 55552 41555:75
40 - SAPR3 /BIC/FZCO_C51 YES 1 32610 4176 2898:69
Press <Rtn> - scroll, 'c' - cont, 'h' - header, 's' - stop ...
41 - SAPR3 /BIC/FZECCS_C04 YES 1 744980 34696 25463:73
42 - SAPR3 /BIC/FZMMPURC01 YES 1 9719 976 655:67
43 - SAPR3 /BIC/FZPCA_C03 YES 1 11251680 741872 593350:80
44 - SAPR3 /BIC/FZPURC001 YES 1 0 72 0:0
45 - SAPR3 /BIC/FZPURC002 YES 1 0 8 0:0
46 - SAPR3 /BIC/FZQM_C50 YES 1 0 72 0:0
47 - SAPR3 /BIC/FZRC_C50 YES 1 62090 4576 1819:40
48 - SAPR3 /BIC/FZRC_C51 YES 1 0 8 0:0
49 - SAPR3 RSDMFACTAB NO 1 0 72 0:0
50 - SAPR3 RSMDMCNVTAB NO 1 0 72 0:0
Standard keys: c - cont, b - back, s - stop, r - refr, h - help
BR0662I Enter your choice:
c
BR0280I BRSPACE time stamp: 2008-04-22 11.58.02
BR0663I Your choice: 'c'
BR0259I Program execution will be continued...
BR0280I BRSPACE time stamp: 2008-04-22 11.58.02
BR0657I Input menu 353 - please enter/check input values
Options for reorganization of tables: SAPR3./BI0/E0BWTC_C02,... (50 tables)
1 ~ New destination tablespace (newts) ........ [PSAPFACT2D]
2 ~ Separate index tablespace (indts) ......... [PSAPFACT2I]
3 - Parallel threads (parallel) ............... [1]
4 ~ Table/index parallel degree (degree) ...... []
5 # Create DDL statements (ddl) ............... [yes]
6 ~ Category of initial extent size (initial) . []
7 # Sort by fields of index (sortind) ......... []
8 - Table reorganization mode (mode) .......... [offline]
Standard keys: c - cont, b - back, s - stop, r - refr, h - help
BR0662I Enter your choice:
Why is it only doing 50 of the 353 tables?From DB02 then saved to an excel file:
Owner Object Type Tablespace KBytes Blocks Extents MaxExtents Next (K)
1 SAPR3 /BIC/EZQM_C50200509 TABLE PART PSAPFACTD 64 8 1 -1 0
2 SAPR3 /BIC/EZQM_C50200508 TABLE PART PSAPFACTD 64 8 1 -1 0
3 SAPR3 /BIC/EZQM_C50200507 TABLE PART PSAPFACTD 64 8 1 -1 0
4 SAPR3 /BIC/EZQM_C50200506 TABLE PART PSAPFACTD 64 8 1 -1 0
595 SAPR3 /BIC/EZRC_C5192003003 TABLE PART PSAPFACTD 64 8 1 -1 0
596 SAPR3 /BIC/EZRC_C5192003002 TABLE PART PSAPFACTD 64 8 1 -1 0
597 SAPR3 /BIC/EZRC_C5192003001 TABLE PART PSAPFACTD 64 8 1 -1 0 -
Reorg tables in 8.1.7
I'm planning to reorg 500+ tables in 5-6 schemas from prod. instance to new one. DB is 8.1.7.4
I'm thinking on using 2 approaches:
1) using db cloning from current prod. to new then re-org selected tables to different tablespaces, or
2) export tables using table mode than import to new prod. by chaning default_tablespace for target user.
Which is better option if objective is to re-org tables to different tablespaces within schemas. Also want to use new lay-out mgmt, i.e. change dictionary to locally managed, tune the new instance, etc.
Thanks in advance.
BAMOr just create a database link from your new box to the production box. You can then run CREATE TABLE new_name AS SELECT * FROM old_name@the_db_link; Though INDEXES will not be created...
-
Tablespace Reorganisation in Oracle 10g Database
Dear All,
I'm planning of doing a carrying out a Tablespace Reorganisation of the schema tablespace on the production server. I need your views regarding the process to be taken and tuning that is required before carrying out such an activity. For your information, the size of the tablespace is around 3TB. Also, since it is the production server, we can't have an outage for more than 24hrs. Hence, I would like some help from all of you in order to carry out this activity successfully in the time frame.
Regarding the process :
I have some ideas about how to do the tablespace reorganisation in oracle 10g. But, if I carry out the activity my way, its going it to take atleast 3-4 days to complete (which won't be acceptable).
Areas of concern :
1) Steps to perform the tablespace reorganisation in Oracle 10g DB.
2) Size of the temporary tablespace before starting the Reorg.
3) Any further suggestions / recomendations regarding tuning up of Oracle Parameters for enhancement of speed and acuracy of the activity.
System Specifications :
SAP - BI 7.0 (SAP NetWeaver 2004s)
DB - Oracle 10.2.0.2.0, DBSL Patch Level - 158
OS - AIX 5.3
Looking forward to some good and prompt suggestions from all of you !!
Please provide your valuable inputs.
NOTE :: We have successfully performed the reorganization in the rest of the landscape on the same schema tablespace without any issues.
Thanks and Regards,
Deoraj Alok.It is quite an old thread, but let me put in my view points, which could help others.
1. The Size of PSAPTEMP and PSAPUNDO tablespace should be 1.5*largest Table Size.
2. Another Important thing is , if the time is in an issue, what you can do is to reorg. only top 50 largest tables where maximum space is being wasted. Folowing is the query to determine the TOP 50 tables which has the highest WASTED size.
SELECT * FROM
(SELECT
SUBSTR(TABLE_NAME, 1, 21) TABLE_NAME,
NUM_ROWS,
AVG_ROW_LEN ROWLEN,
BLOCKS,
+ROUND((AVG_ROW_LEN + 1) * NUM_ROWS / 1000000, 0) NET_MB,+
+ROUND(BLOCKS * (8000 - 23 * INI_TRANS) *+
(1 - PCT_FREE / 100) / 1000000, 0) GROSS_MB,
ROUND((BLOCKS * (8000 - 23 * INI_TRANS) * (1 - PCT_FREE / 100) -
+(AVG_ROW_LEN + 1) * NUM_ROWS) / 1000000) "WASTED_MB",+
Tablespace_Name
FROM DBA_TABLES
WHERE
NUM_ROWS IS NOT NULL AND
OWNER LIKE 'SAP%' AND
PARTITIONED = 'NO' AND
(IOT_TYPE != 'IOT' OR IOT_TYPE IS NULL)
ORDER BY 7 DESC)
WHERE ROWNUM <=50;
I am sure that, only these 50 tables will reduce the maximum space and you can ignore rest of the tables.
3. Even you can find out all the Tables which are having LONG and LONG RAW fields by using this query
Select Distinct TABLE_NAME From dba_tab_cols Where Owner='SAPYSP' and (DATA_TYPE='LONG' OR DATA_TYPE='LONG RAW');
Now, from the results of this query you can see how many Tables are present in the Top 50 Tables. There will be a few only and you can export/import these few tables in offline mode.
4. After reorg, fi you want to claim the free disk space also, it would not be that easy because of the high water mark present in datafiles but you can try with
Alter datafile <datafile id> resize <Size>M
5. If free disk space is the first priority the you need to create another Table space (which should have size as big as it can have all the tables) and you re-organize in this new tablespace. After Reorg, drop the old tablespace and rename the new Table space with the old one (Rename Tablespace Command will work only in Oracle 10g).
I hope this information helps all those who are going to do reorg in their respective projects. However, You can further put your question if in doubt and I will try to answer them. -
Bring down the number of tablespaces in Oracle 9.2.0.8
We plan to reorginize our tablespaces to LMTS to about 10-15 tablepaces, currently we have 56 tablespaces with 200 datafiles.
We plan to use brtools to created the new LMTS tablespaces and move the tables (all with no long or long raw type of data) with
alter table xxx move tablespace new_tablespace_name;
and export/import the remaining tables with long and/or long raw columns.
My question is would SAP care about the tablespace name (obviously we'll have new tablespace names after reorg) as far as upgrade and transport are considered?
Did anyone have done those type of reorg before? I appreciate your feedback.Sharon,
We have done a similar exercise on our BW system. The answer to your question is NO, SAP does not care of the actual names as long as SAP has the tablespaces registered in its dictionary. It is a good practice to stick to the standard SAP naming convention for clarity.
We have used brspace to perform online and offline reorgs. The advantage of this process is that it does make changes to SAP dictionary when the change are done and it is important to cross check if the new tablespaces are registered in SAP tables before you start using the system, the change can be done manually using SQL or using SE16 in case brspace skips it.
I have listed important SAP notes to refer for this activity.
Note 646681 - Reorganising tables with BRSPACE
Note 46272 - Implement new data class in technical settings
Note 737598 - New BRSPACE options for control of Reorg and Rebuild
Cheers,
Nisch -
How to reorganization index in new tablespace
How to reorganization index in new tablespace? for size? for? number of extents? or both?
What's Oracle version?
Why you want to reorg your index?
You could rebuild your index
alter index <index_name> rebuild tablespace <tablespace_name>check Jonathan's note regarding index rebuild,
http://jonathanlewis.wordpress.com/2008/02/09/index-rebuild-10g/ -
Snapshot too old error during drop tablespace
Hi Experts
When we are doing BW reorg and steps followed are
1. created a newtablespace with source tablespace TABART class reference.
2. Export the source tablespace to the filesystem level.
3. DROP the source tablespace now.
4. Rename the new tablespace to source tablespace name.
5. Import
Here in the third step i have received snapshot too old error.
BR0301E SQL error -604 at location BrSqlExecute-1, SQL statement:
'/* BRSPACE */ drop tablespace PSAPADSOLD including contents and datafiles cascade constraints'
ORA-00604: error occurred at recursive SQL level 1
ORA-01555: snapshot too old: rollback segment number 0 with name "SYSTEM" too small
BR1017E Execution of SQL statement 'drop tablespace PSAPADSOLD including contents and datafiles cascade constraints' failed
so i tried to rename the tablespace and set to offline and tried to import only 240 tables were imported compared to 24057 tables.Still the PSAPADS - Source tablespace shows 65000 elements.
my queries:
1. After Export of the tablespace how come the Source tablespace retain the tables.
2. why i could not able to drop the tablespace
I had increased the UNDO_RETENTION to 86400 my oracle version is 10.2.04.
Source table space PSAPADS is 80 GB and has only 30 GB data and the remaining are free.
PSAPUNDO was 17GB in size.
Kinldy suggest
Regards
BalaHi Stefa
Thanks for your reply.
how to find the System undo is still active.How to track which Undo which is active and their steps.
As per the metalink note our PSAPUNDO is Locally Managed Tablepsace hence the second workaround is applicable..
How to validate this will not give a problem again while i am doing reorganization.
When i checked a sap note 1039060 this note is applicable to windows i dont how it can be impleneted.
Whether any merge fix will help on this
Regards
Bala
Maybe you are looking for
-
My iPhone is recognized, but does not let me sync the phone or anything. That is the screen it shows... How it happened; I plugged in my iphone for the first time, then it asked me to register... My computer then froze and I clicked cancel and restar
-
Report Layout and Report Query APEX tables
Does anyone know a quick way to delete report layouts and report queries from the APEX tables that they are stored in. We currently have to go into the shared components area and delete them one by one using the builder. If we could just get the tabl
-
How to install latest mac OS x on iMac without original dvd
hi. I have imac Intel based and early 2008 model. I used Yosemite in it... I erased the Whole HDD.. Now it shows flashing folder icon with question mark..i don't have original DVD or internet connection.. My friend has mac book pro running Yosemite..
-
Dear All, My apologies if this posting is on the wrong board. I've a problem with our content engine returning an error of: "Tre reply from server is not valid" The URL of the site is http://hiring.monster.co.uk/jobs/createtitle.aspx?mode=qb. I've at
-
Hi, can any one pls let me know the steps we should fallow in an inbound idoc processing. I have the messagte type , basic type, process code and i have to create partner profile , pls let me know what are the steps to be fallowed thanks, Deepak