For data export, import. Exp/imp can be used to import remote data to the client. However, expdp/impdp is not powerful.
Expdp/impdp is powerful, but the exported data can only be on the server. Next we will use the expdp and dblink
Export data to a local directory
If the space is allowed, we recommend that you export it to the server.
# Orac_remote is a local name, which can be configured through netca or directly modify the relevant configuration file
# Ensure that the system user of cmd_remote is open and the password is correct.
# You can run the select * from scott. emp @ to_success _remote test. If the test fails, you need to check the permission and the user's namespace named pai_remote.
1. Create a dblink connection
Create database link to_assist_remote
Connect to system identified by gpecnew using 'orac _ remote'
2. Create a directory
Create directory backup as '/backup'
Grant read, write on directory backup to system
3. Compile the parfile parameter file scott. par of expdp.
Userid = system/root
Directory = backup
Dumpfile = scott. dump
Logfile = scott. log
Schemas = scott
Network_link = to_assist_remote
4. Execute the command to export to the local device.
Expdp parfile = scott. par
5. Import to local
(Delete scott user and all tables locally during the test. drop user scott cascade)
Impdp system/root directory = backup dumpfile = scott. dump logfile = scott2.log