Operating System - HP-UX
1748232 Members
3356 Online
108759 Solutions
New Discussion юеВ

Re: How to export from VLDB using named pipe import into target DB

 
SOLVED
Go to solution
Frank de Vries
Respected Contributor

How to export from VLDB using named pipe import into target DB

This question has problem been posted before.
I have an Oracle VLDB onb hpux11 and its export dmp would fill up my filesystem to its limit. I prefer not to extend my filesystem.
I heard you can go via a named pipe, and import
(imp) directly into a target database.
That sounds very nice, but unfortunately I lack examples.
Any workable examples would be handy,
will give full marks.
NB: I have prepared a sample parfile:
buffer=1000000
file=exp_pipe
log=/picnew/export/P03/exp_pipe.infas.log
owner=infasusra
rows=yes
constraints=yes
indexes=no
compress=yes
grants=yes
consistent=yes

Now how to import that straight away ?
Thanks.
Look before you leap
4 REPLIES 4
Yogeeraj_1
Honored Contributor

Re: How to export from VLDB using named pipe import into target DB

hi,

will it not be better that you use the sqlplus COPY command in this case?
==============================================================================================
COPY {FROM database | TO database | FROM database TO database}
{APPEND|CREATE|INSERT|REPLACE} destination_table
[(column, column, column, ...)] USING query
where database has the following syntax:

username[/password]@connect_identifier

==============================================================================================
I find it more efficient than what you are trying to do here!

Please let us know.

best regards
Yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Tim Martens_1
New Member
Solution

Re: How to export from VLDB using named pipe import into target DB

Hi Frank,

There is a note on metalink (Note:30528.1) explaining how to read / write to a named pipe. What you want to do isn't covered here (and I don't know if it's possible), but there is an interesting example on how to export to and import from a compressed file through a named pipe (This should cover you diskspace problem). I'll include the example:

Creating a compressed export file
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
% mknod /tmp/exp_pipe p # Make the pipe
% compress < /tmp/exp_pipe > export.dmp.Z & # Background compress
% exp file=/tmp/exp_pipe # Export to the pipe

Reading a compressed export file
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
% mknod /tmp/imp_pipe p # Make the pipe
% uncompress < export.dmp.Z > /tmp/imp_pipe & # Background uncompress
% imp file=/tmp/imp_pipe # Import from the pipe

Hope this helps.
Regards,
Tim
twang
Honored Contributor

Re: How to export from VLDB using named pipe import into target DB

1. To export:

/usr/sbin/mknod exp_pipe p
gzip < exp_pipe > FULLDMP.dmp.gz &
exp sys/ file=exp_pipe full=y buffer=4000000 statistics=NONE log=EXP.log

2. To import:

/usr/sbin/mknod imp_pipe p
gzip -d < FULLDMP.dmp.gz > imp_pipe &
imp sys/ file=imp_pipe full=y commit=y buffer=4000000 log=IMP.log
Frank de Vries
Respected Contributor

Re: How to export from VLDB using named pipe import into target DB

sorry I am a bit late with allocating
points.
I fell ill that week and never came
back to it, until I noticed it again
today.
My sincere apologies as your answers
are still usefull.
Thanks
Look before you leap