Thursday, April 8, 2010

Performing a compressed pipe export and import

I always forget how to do a compressed pipe export and import, so here are the commands, taken from the orafaq website.

Make a pipe process

mknod exp.pipe p
Start the compress and pipe it in the background

gzip < exp.pipe > scott.exp.gz &

Wait a second or so before kicking off the export

Run the export command

nohup exp userid=scott/tiger file=exp.pipe ... &


That does the export. To import the file, do this:

Make a new pipe process, run the uncompress in the background and then run the import command


mknod imp.pipe p

zcat expdat.dmp.Z > imp.pipe &

imp system/password file=imp.pipe full=Y log=imp.log resumable=y resumable_name=impjob resumable_timeout=7200 buffer=5000000


This should be all you need.

No comments:

Post a Comment