Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: exp a big tablespace
Here's a tip I mined many moons ago from I don't know where. It's a script to split the compressed file into smaller chunks using the standard UNIX split utility.
HTH Tony Aponte
January 16, 1998
Exporting a Database That's More Than 2GB When Compressed
This Tip of the Week entry comes from Devarajan Sundaravaradan, a Senior Consultant for Leading Edge Systems, Inc. in Edison, New Jersey.
In HP-UX, there is a 2GB limit on file sizes of 2GB. Many of us have reached this limit when exporting files and the most common solution is to do a filesystem compression of the export dump using named pipes and then store the compressed file. But what if the compressed file itself passes the 2GB limit? There is solution to this, too.
# Create new Named pipes.
mknod -p /dev/split_pipe
mknod -p /dev/compress_pipe # You can use the existing named pipe
# itself, instead of creating new. ======================================================================
Create a shell script under a file, named Split_export.sh
# -b1000m indicates to split command to split the input file into every 1000 MB size.
# As it splits, the split command will suffix aa, ab, ac, ad ... upto zz to the file name specified.
# The export file name is expfile.
nohup split -b1000m < /dev/split_pipe > /DumpDir/expfile &
nohup compress < /dev/compress_pipe > /dev/split_pipe &
exp username/password full=y file=/dev/compress_pipe and other parameters for export.
After saving the above three commands in split_export.sh, execute the following.
chmod a+x split_export.sh
nohup split_export.sh > /tmp/split_export.log 1>&2 &
After a few minutes you should see files in the export dump directory.
Create a shell script with the following command under the file name split_import.sh.
After creating provide execution permission to this script as follows:
Chmod a+x split_import.sh
# The import script assumes in this example that the above export script created 2 split files
# called expfileaa and expfileab. The order of the file for the cat command is very important.
nohup cat /dumpdir/expfileaa /dumpdir/expfileab > /dev/split_pipe &
# sleep 3 seconds
Sleep 3
nohup uncompress < /dev/split_pipe > /dev/compress_pipe &
#Sleep at this point is very important as some time is needed to uncompress the file and send it to the pipe.
sleep 60
imp username/password file=/dev/compress_pipe and other parameters for export.
nohup split_import.sh > /tmp/split_import.log 1>&2 &
Wait for the import to finish.
Home! | Tip & Code Archive | Subscribe & Advertise | Search?
All specific technical questions from users of Oracle supported products should be directed to Oracle's Technical Support Department. Oracle does not provide any warranty as to the accuracy of any information provided through Oracle Magazine Interactive. Oracle shall not be liable for any damages incurred as a result of reliance on any information provided herein.
Copyright © 1998 Oracle Corporation. All Rights Reserved.
-----Original Message-----
From: Andrew Cook [mailto:cook_at_bkik.hu]
Sent: Thursday, November 08, 2001 3:30 AM
To: Multiple recipients of list ORACLE-L
Subject: exp a big tablespace
Hello,
I want to export a big tablespace (big is relative 9GB :) ) but I get an
error message EXP-0002: error in writing to export file and EXP-00222:
System error message 22 ... I think my SunOS 5.5.1 not supported large
files .. But How to export this big tablespace? I think my SuSe 7.1 support
big files. This is correct ?
Thx for your help!
Cook
-- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Andrew Cook INET: cook_at_bkik.hu Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).Received on Tue Nov 20 2001 - 15:23:07 CST
![]() |
![]() |