select OWNER, TABLE_NAME, COLUMN_NAME, SEGMENT_NAME, INDEX_NAME from DBA_LOBS where TABLE_NAME='AUD_PRODUCT_BIG_DATA'; /* OWNER TABLE_NAME COLUMN_NAME SEGMENT_NAME INDEX_NAME -------- -------------------- ----------- ------------------------- ------------------------ SCH_DMALL AUD_PRODUCT_BIG_DATA DESCRIPTION AUD_PRODUCT_BIG_DATA_CLOB SYS_IL0000126287C00004$$ */ select bytes/1024/1024 from dba_segments where segment_name='SYS_LOB0000126287C00004$$'; --22GB
After moving the LOB column with the storage option of "SECUREFILE" and "MEDIUM COMPRESS" option the size of the LOB segment decreased to approx. 833Mb. More than 1/25 compression which is as valuable as gold in this production database.
ALTER TABLE sch_dmall.aud_product_big_data move lob (description) store AS SECUREFILE aud_product_big_data_clob (TABLESPACE TS_AUD_LOB_SEGMENT COMPRESS MEDIUM) parallel 4; select bytes/1024/1024 from dba_segments where segment_name='AUD_PRODUCT_BIG_DATA_CLOB'; --833.125
There are three levels of compression which is LOW MEDIUM and HIGH which defines the compression level. Of course the higher the level gets, the more CPU power you need to spend. here I used MEDIUM to see the result and it is pretty convincing to not to change the setting.
References:
http://blog.trivadis.com/b/mathiaszarick/archive/2012/03/05/lob-compression-with-oracle-strange-multiple-physical-reads.aspx
http://www.oracle-base.com/articles/11g/secure-files-11gr1.php
I want to add one line SQL to prevent physical I/O overhead of LOB segments.
ReplyDeleteSQL> ALTER TABLE aud_product_big_data_clob MODIFY LOB (DESCRIPTION) (CACHE READS);
Sincerely yours.
Good One.. Well Explained
ReplyDeleteVisit oracletraining
Its really awesome blog..If anyone wants to get Software Testing Course in Chennai visit FITA IT academy located at Chennai. Rated as No.1 Software Testing Training Institutes in Chennai
ReplyDeleteRegards.....
Testing Training in Chennai | QTP Course in Chennai
ReplyDeleteThe information you posted here is useful to make my career better keep updates...If anyone want to get Cloud Computing Course in Chennai, Please visit FITA academy located at Chennai. Rated as No.1 Cloud Computing Training Institutes in Chennai
I have read your blog and i got a very useful and knowledgeable information from your blog.You have done a great job . If anyone want to get Salesforce Admin Training in Chennai, Please visit FITA academy located at Chennai Velachery. Rated as No.1 Salesforce Training Institutes in Chennai.
ReplyDelete