Oracle Schema Backup (Data Pump)
Oracle Schema Backup (Data Pump)
Topic Introduction: 'Oracle Schema Backup (Data Pump)' For many reasons, we lose our data from the database, it can be a Database fall, system problem, hacker attack, virus, etc. To be risk-free users need to take a backup every specific time of schema or database. In this tutorial, we will see how to take a backup a schema on oracle 19c by command.
Export Schema/User in Oracle 19c :
1. We Need to create a Directory to store the backup files.
2. Need to grant read-write privilege to the user.
3. Need to run backup command on command prompt.
2. Need to grant read-write privilege to the user.
3. Need to run backup command on command prompt.
Directory Creation for keeping Export DMP:
CREATE OR REPLACE DIRECTORYMY_BACKUP_EXPDIR AS'D:\DBbackup\Export';
Granting Read Write privilege to the User:
GRANT READ, WRITE ON DIRECTORY MY_BACKUP_EXPDIR TO HR;
Run the script to the command prompt for Export:
expdp hr/hr@orclpdb directory=MY_BACKUP_EXPDIR dumpfile=HRback.dmp logfile=HRback.log
Note: 1. Directory needs to create by sys user and granted by another to hrtemp user.
No comments