Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Converting from EXP to EXPDB

Status
Not open for further replies.

BenLoosli

Technical User
Jan 23, 2019
3
US
I am trying to convert my backups from using EXP to using EXPDB, but the syntax is way different and I get errors with no backup done.

The command I am trying is:
expdb <user>/<pass>@SID DIRECTORY=e:\Oracle_bkup dumpfile=orcldmp.exp logfile-orcldmp.log

I get the following errors:
ORA-39002
ORA-39070
ORA-39087

The database schema and all is from a PTC Windchill system.
 
What is EXPDB? Oracle has an application called EXPDP (Data pump). Also why use expdp when RMAN (Recovery Manager) comes with the database and is specifically made to do database backups. and recover the database if an error occurs.

To help you the error is occurring because expdp uses a directory object, not a directory path. for example if you set up a directory path as the SYS user using the following commands

CREATE OR REPLACE DIRECTORY
DATA_PUMP_DIR AS
'e:\Oracle_bkup\';

GRANT READ, WRITE ON DIRECTORY DATA_PUMP_DIR TO <USER_RUNNING_THE_EXPDP>;

Then your command would be

expdb <user>/<pass>@SID DIRECTORY=DATA_PUMP_DIR dumpfile=orcldmp.exp logfile-orcldmp.log

The directory objects folder MUST be on the server running the oracle database and the folder (e:\Oracle_bkup) must be owned by the user running the oracle database and that user must have read/write priviledges on the folder. The dumpfile will be created in that folder.



Bill
Lead Application Developer
New York State, USA
 
My mistake, I am trying to use expdp.
Doesn't exp and expdp come with Oracle, too?
What makes RMAN better than expdp for a simple backup?
 
expdp can be used to restore individual tables but doesn't protect against things like corrupt data files or a totally hosed database. RMAN is the backup tool for oracle and can totally recover a corrupt or damaged database. And if you are running in archive log mode (always for production databases) it will recover your database to the last committed transaction.
expdp is a table backup tool that is a single point of time backup and will only allow the particular table to be reloaded to the specific point of time that the backup was performed.



Bill
Lead Application Developer
New York State, USA
 
Thanks Bill

In my application expdp will be fine as it is not a transaction based 24/7 system. The Windchill application is storing engineering data files, reports and some meta data about these files.
 
Thats fine. However you should have at least one good RMAN backup or a physical copy of the datafiles when the database is down so if you get a corrupted data file or your server crashes you can recover your database. Make sure to include the control files and store them on a different server or on a backup medium. as for the exppd dumpfile keep at least one good copy of the previous dumpfile in case the dumpfile gets corrupted.

Bill
Lead Application Developer
New York State, USA
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top