Oracle 18c Datapump-Tablespace level
Description:-
In this article we are going to see the Oracle 18c Datapump-Tablespace level backup
Syntax :
expdp system/Chennai#123@pdb1 directory=TEST_DIR tablspaces=users dumpfile=tbs.dmp logfile=tbs.log
Let’s start the Demo:
Pre-steps:-create a directory in the filesystem and creates a directory
[oracle@testdb ~]$ mkdir –p /u01/app/oracle/datapump [oracle@testdb ~]$ sqlplus '/as sysdba' SQL*Plus: Release 18.0.0.0.0 Production on Sat Jun 30 05:50:19 2018 Version 18.1.0.0.0 Copyright (c) 1982, 2017, Oracle. All rights reserved. Connected to: Oracle Database 18c Enterprise Edition Release 18.0.0.0.0 - Production Version 18.1.0.0.0 SQL> alter session set container=pdb1; Session altered. SQL> create or replace directory test_dir as '/u01/app/oracle/datapump'; Directory created.
Demo 1:-Export individual Tablespace From system Schema
[oracle@testdb oracle]$ expdp system/Chennai#123 directory=test_dir tablespaces=users dumpfile=users.dmp logfile=users.log
Export: Release 18.0.0.0.0 - Production on Sun Jul 1 11:14:26 2018
Version 18.1.0.0.0
Copyright (c) 1982, 2018, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 18c Enterprise Edition Release 18.0.0.0.0 - Production
Warning: Oracle Data Pump operations are not typically needed when connected to the root or seed of a container database.
Starting "SYSTEM"."SYS_EXPORT_TABLESPACE_01": system/******** directory=test_dir tablespaces=users dumpfile=users.dmp logfile=users.log
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
Processing object type TABLE_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
Processing object type TABLE_EXPORT/TABLE/STATISTICS/MARKER
Processing object type TABLE_EXPORT/TABLE/TABLE
Processing object type TABLE_EXPORT/TABLE/GRANT/OWNER_GRANT/OBJECT_GRANT
Processing object type TABLE_EXPORT/TABLE/COMMENT
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/REF_CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/TRIGGER
. . exported "C##DBAAS_BACKUP"."BKP_STATUS" 0 KB 0 rows
. . exported "C##DBAAS_MONITOR"."SQLDEV_JOBS" 0 KB 0 rows
. . exported "C##DBAAS_MONITOR"."SQLDEV_JOB_FILES" 0 KB 0 rows
ORA-39173: Encrypted data has been stored unencrypted in dump file set.
Master table "SYSTEM"."SYS_EXPORT_TABLESPACE_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SYSTEM.SYS_EXPORT_TABLESPACE_01 is:
/u01/app/oracle/datapump/users.dmp
Job "SYSTEM"."SYS_EXPORT_TABLESPACE_01" successfully completed at Sun Jul 1 11:15:18 2018 elapsed 0 00:00:51
Demo 2:-Export multiple Tablespace From system Schema
[oracle@testdb oracle]$ expdp system/Chennai#123 directory=test_dir tablespaces=users,chennai dumpfile=tbs.dmp logfile=tbs.log
Export: Release 18.0.0.0.0 - Production on Sun Jul 1 12:10:06 2018
Version 18.1.0.0.0
Copyright (c) 1982, 2018, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 18c Enterprise Edition Release 18.0.0.0.0 - Production
Warning: Oracle Data Pump operations are not typically needed when connected to the root or seed of a container database.
Starting "SYSTEM"."SYS_EXPORT_TABLESPACE_01": system/******** directory=test_dir tablespaces=users,chennai dumpfile=tbs.dmp logfile=tbs.log
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
Processing object type TABLE_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
Processing object type TABLE_EXPORT/TABLE/STATISTICS/MARKER
Processing object type TABLE_EXPORT/TABLE/TABLE
Processing object type TABLE_EXPORT/TABLE/GRANT/OWNER_GRANT/OBJECT_GRANT
Processing object type TABLE_EXPORT/TABLE/COMMENT
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/REF_CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/TRIGGER
. . exported "C##DBAAS_BACKUP"."BKP_STATUS" 0 KB 0 rows
. . exported "C##DBAAS_MONITOR"."SQLDEV_JOBS" 0 KB 0 rows
. . exported "C##DBAAS_MONITOR"."SQLDEV_JOB_FILES" 0 KB 0 rows
ORA-39173: Encrypted data has been stored unencrypted in dump file set.
Master table "SYSTEM"."SYS_EXPORT_TABLESPACE_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SYSTEM.SYS_EXPORT_TABLESPACE_01 is:
/u01/app/oracle/datapump/tbs.dmp
Job "SYSTEM"."SYS_EXPORT_TABLESPACE_01" successfully completed at Sun Jul 1 12:10:57 2018 elapsed 0 00:00:48
Catch Me On:- Hariprasath Rajaram
LinkedIn:https://www.linkedin.com/in/hari-prasath-aa65bb19/
Facebook:https://www.facebook.com/HariPrasathdba
FB Group:https://www.facebook.com/groups/894402327369506/
FB Page: https://www.facebook.com/dbahariprasath/?
Twitter: https://twitter.com/hariprasathdba