首頁 資料庫 mysql教程 Oracle 11g版本EXPDP 的COMPRESSION参数压缩比堪比“gzip -9”

Oracle 11g版本EXPDP 的COMPRESSION参数压缩比堪比“gzip -9”

Jun 07, 2016 pm 04:00 PM

Oracle 11g的EXPDP工具提供了真正意义上的ldquo;备份压缩rdquo;,这个技术在备份空间不足的情况下非常实用。Oracle在改进和优化

这个压缩比例可以和操作系统“gzip -9”相媲美,某些特例下有可能比gzip还要高效。体验之,供参考。

1.Oracle 11g中expdp帮助页中关于COMPRESSION参数的描述
secooler@secDB /home/oracle$ expdp -help
……
COMPRESSION
Reduce the size of a dump file.
Valid keyword values are: ALL, DATA_ONLY, [METADATA_ONLY] and NONE.
……

可见,11g中的COMPRESSION参数提供四个选项,分别是ALL、DATA_ONLY、METADATA_ONLY和NONE,非常的丰富,稍后我们将使用ALL参数进行操作。

2.Oracle 10g中关于COMPRESSION参数的描述如下
Keyword              Description (Default)
---------------------------------------------------------------------
……
COMPRESSION          Reduce size of dumpfile contents where valid
                      keyword values are: (METADATA_ONLY) and NONE.
……
10g中的COMPRESSION参数只提供METADATA_ONLY和NONE两个选项,,基本上没有提供压缩功能。

3.使用11g EXPDP工具的四个压缩参数分别生成四个dump文件
1)使用ALL参数
secooler@secDB /expdp$ expdp sec/sec dumpfile=sec_ALL.dmp logfile=sec_ALL.log tables=t directory=dump_dir compression=ALL

Export: Release 11.2.0.1.0 - Production on Sat Mar 20 22:48:52 2010

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, Oracle Label Security, OLAP, Data Mining,
Oracle Database Vault and Real Application Testing options
Starting "SEC"."SYS_EXPORT_TABLE_01":  sec/******** dumpfile=sec_ALL.dmp logfile=sec_ALL.log tables=t directory=dump_dir compression=ALL
Estimate in progress using BLOCKS method...
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 136 MB
Processing object type TABLE_EXPORT/TABLE/TABLE
. . exported "SEC"."T"                                  14.26 MB 1155520 rows
Master table "SEC"."SYS_EXPORT_TABLE_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SEC.SYS_EXPORT_TABLE_01 is:
  /expdp/sec_ALL.dmp
Job "SEC"."SYS_EXPORT_TABLE_01" successfully completed at 22:49:08

2)使用DATA_ONLY参数
secooler@secDB /expdp$ expdp sec/sec dumpfile=sec_DATA_ONLY.dmp logfile=sec_DATA_ONLY.log tables=t directory=dump_dir compression=DATA_ONLY

Export: Release 11.2.0.1.0 - Production on Sat Mar 20 22:49:32 2010

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, Oracle Label Security, OLAP, Data Mining,
Oracle Database Vault and Real Application Testing options
Starting "SEC"."SYS_EXPORT_TABLE_01":  sec/******** dumpfile=sec_DATA_ONLY.dmp logfile=sec_DATA_ONLY.log tables=t directory=dump_dir compression=DATA_ONLY
Estimate in progress using BLOCKS method...
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 136 MB
Processing object type TABLE_EXPORT/TABLE/TABLE
. . exported "SEC"."T"                                  14.26 MB 1155520 rows
Master table "SEC"."SYS_EXPORT_TABLE_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SEC.SYS_EXPORT_TABLE_01 is:
  /expdp/sec_DATA_ONLY.dmp
Job "SEC"."SYS_EXPORT_TABLE_01" successfully completed at 22:49:48

3)使用METADATA_ONLY参数
secooler@secDB /expdp$ expdp sec/sec dumpfile=sec_METADATA_ONLY.dmp logfile=sec_METADATA_ONLY.log tables=t directory=dump_dir compression=METADATA_ONLY

Export: Release 11.2.0.1.0 - Production on Sat Mar 20 22:50:16 2010

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, Oracle Label Security, OLAP, Data Mining,
Oracle Database Vault and Real Application Testing options
Starting "SEC"."SYS_EXPORT_TABLE_01":  sec/******** dumpfile=sec_METADATA_ONLY.dmp logfile=sec_METADATA_ONLY.log tables=t directory=dump_dir compression=METADATA_ONLY
Estimate in progress using BLOCKS method...
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 136 MB
Processing object type TABLE_EXPORT/TABLE/TABLE
. . exported "SEC"."T"                                  111.7 MB 1155520 rows
Master table "SEC"."SYS_EXPORT_TABLE_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SEC.SYS_EXPORT_TABLE_01 is:
  /expdp/sec_METADATA_ONLY.dmp
Job "SEC"."SYS_EXPORT_TABLE_01" successfully completed at 22:50:27

4)使用NONE参数
secooler@secDB /expdp$ expdp sec/sec dumpfile=sec_NONE.dmp logfile=sec_NONE.log tables=t directory=dump_dir compression=NONE

Export: Release 11.2.0.1.0 - Production on Sat Mar 20 22:50:43 2010

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

本網站聲明
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn

熱門文章

倉庫:如何復興隊友
3 週前 By 尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island冒險:如何獲得巨型種子
3 週前 By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O.能量晶體解釋及其做什麼(黃色晶體)
1 週前 By 尊渡假赌尊渡假赌尊渡假赌

熱門文章

倉庫:如何復興隊友
3 週前 By 尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island冒險:如何獲得巨型種子
3 週前 By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O.能量晶體解釋及其做什麼(黃色晶體)
1 週前 By 尊渡假赌尊渡假赌尊渡假赌

熱門文章標籤

記事本++7.3.1

記事本++7.3.1

好用且免費的程式碼編輯器

SublimeText3漢化版

SublimeText3漢化版

中文版,非常好用

禪工作室 13.0.1

禪工作室 13.0.1

強大的PHP整合開發環境

Dreamweaver CS6

Dreamweaver CS6

視覺化網頁開發工具

SublimeText3 Mac版

SublimeText3 Mac版

神級程式碼編輯軟體(SublimeText3)

減少在Docker中使用MySQL內存的使用 減少在Docker中使用MySQL內存的使用 Mar 04, 2025 pm 03:52 PM

減少在Docker中使用MySQL內存的使用

如何使用Alter Table語句在MySQL中更改表? 如何使用Alter Table語句在MySQL中更改表? Mar 19, 2025 pm 03:51 PM

如何使用Alter Table語句在MySQL中更改表?

mysql無法打開共享庫怎麼解決 mysql無法打開共享庫怎麼解決 Mar 04, 2025 pm 04:01 PM

mysql無法打開共享庫怎麼解決

什麼是 SQLite?全面概述 什麼是 SQLite?全面概述 Mar 04, 2025 pm 03:55 PM

什麼是 SQLite?全面概述

在 Linux 中運行 MySQl(有/沒有帶有 phpmyadmin 的 podman 容器) 在 Linux 中運行 MySQl(有/沒有帶有 phpmyadmin 的 podman 容器) Mar 04, 2025 pm 03:54 PM

在 Linux 中運行 MySQl(有/沒有帶有 phpmyadmin 的 podman 容器)

在MacOS上運行多個MySQL版本:逐步指南 在MacOS上運行多個MySQL版本:逐步指南 Mar 04, 2025 pm 03:49 PM

在MacOS上運行多個MySQL版本:逐步指南

如何保護MySQL免受常見漏洞(SQL注入,蠻力攻擊)? 如何保護MySQL免受常見漏洞(SQL注入,蠻力攻擊)? Mar 18, 2025 pm 12:00 PM

如何保護MySQL免受常見漏洞(SQL注入,蠻力攻擊)?

如何為MySQL連接配置SSL/TLS加密? 如何為MySQL連接配置SSL/TLS加密? Mar 18, 2025 pm 12:01 PM

如何為MySQL連接配置SSL/TLS加密?

See all articles