[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 396
  • Last Modified:

export

I want to export schema sch1 from db1 which is residing in serv1 to a location /back
which is in serv2

what is the command

how we make directory in db1 and grants..

before we start export using expdp
we have to create directory,.
I am confused about the syntax to create directory..
0
thomasliju
Asked:
thomasliju
1 Solution
 
johnsoneSenior Oracle DBACommented:
The command to create a directory is CREATE DIRECTORY, documentation is here -> http://docs.oracle.com/cd/E16655_01/server.121/e17209/statements_5008.htm#SQLRF01207  Good examples in the doc.  What are you confused about with this command?

I am not an expert on expdp, however, I don't believe you can do what you are asking.  The directory has to be on serv1 to use expdp.  What you would need to do is have the client installed on serv2 and run the exp command there.  Or, you could have an NFS mount of the directory, but I wouldn't recommend that.
0
 
DavidSenior Oracle Database AdministratorCommented:
In oracle, this is to create and use aliases that are platform independent.  One example of the syntax is at http://docs.oracle.com/cd/B19306_01/server.102/b14200/statements_5007.htm.

Is this clear to you, or would an example help?

dvz
0
 
slightwv (䄆 Netminder) Commented:
If you run datapump versions, you would need to manually transmit the file from serv1 to serv2.

You would need to create the database directory on serv2 for impdp.

This is why I prefer the classic version.  No need for database directories and it can from from remote clients.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 
DavidSenior Oracle Database AdministratorCommented:
I just came across an 11gR2 doc that implies a NETWORK_LINK eliminates the need to pass a dumpfile, classic style.  One more feature for my to-explore list....

"Specifying a connect identifier when you invoke the Import utility is different from performing an import operation using the NETWORK_LINK parameter. When you start an import operation and specify a connect identifier, the local Import client connects to the database instance identified by the connect identifier and imports the data from the dump file named on the command line to that database instance.

Whereas, when you perform an import using the NETWORK_LINK parameter, the import is performed using a database link, and there is no dump file involved. (A database link is a connection between two physical database servers that allows a client to access them as one logical database.)"  source: http://docs.oracle.com/cd/E11882_01/server.112/e22490/dp_import.htm#SUTIL300
0
 
slightwv (䄆 Netminder) Commented:
The issue with NETWORK_LINK you need to create a database link (DBLINK) between the two databases.  This is not always viable, allowed or desired depending on what databases you are exporting and importing.

For example:
If you are taking data from production and refreshing a test or dev database, you probably should NEVER create a database link between a production and non-production database.
0
 
DavidSenior Oracle Database AdministratorCommented:
Yeah, I suppose we have a subscriber or two who would want to try that.....
0
 
Steve WalesSenior Database AdministratorCommented:
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now