简体   繁体   English

Oracle 11g 中的 IMPDP - 从一种模式到另一种模式

[英]IMPDP in Oracle 11g - From One Schema to other Schema

I used to run commands to get Oracle database backup in the old way using 'exp' and 'imp fromuser touser.我曾经使用“exp”和“imp fromuser touser”以旧方式运行命令来获取Oracle数据库备份。 Now, I am trying to user new command to take backup 'expdp' and 'impdp'.现在,我正在尝试使用新命令来备份“expdp”和“impdp”。

Steps:脚步:

  1. Got backup using expdp with schema parameter on the production server.在生产服务器上使用带有架构参数的 expdp 进行备份。 my username is 'xxx' (Not sure it's fully exported with procedures, function, and view).我的用户名是“xxx”(不确定它是否完全导出了过程、函数和视图)。

  2. Now, on my dev server first I made another user called 'yyy'.现在,首先在我的开发服务器上,我创建了另一个名为“yyy”的用户。 I gave directory access to user 'yyy' and trying to run command impdp as below.我为用户“yyy”提供了目录访问权限,并尝试运行如下命令 impdp。

    C:\\impdp yyy/yyy remap_schema=xxx:yyy directory=abc dumpfile=123.dmp logfile=123.log C:\\impdp yyy/yyy remap_schema=xxx:yyy directory=abc dumpfile=123.dmp logfile=123.log

Now, I am getting an error like the below.现在,我收到如下错误。

Import: Release 11.1.0.6.0 - Production on Thursday, 24 January, 2013 9:53:58

Copyright (c) 2003, 2007, Oracle.  All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production

With the Partitioning, OLAP, Data Mining, and Real Application Testing options
ORA-31626: job does not exist
ORA-31633: unable to create master table "yyy.SYS_IMPORT_FULL_05"
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 95
ORA-06512: at "SYS.KUPV$FT", line 978
ORA-01031: insufficient privileges

Do I miss any steps?我错过了任何步骤吗? like I have to create a job or anything, not sure.就像我必须创造一份工作或任何事情一样,不确定。 basically, I got backup from one user and need to restore on another user in Oracle.基本上,我从一个用户那里得到了备份,需要在 Oracle 中的另一个用户上恢复。

Please help me.请帮我。

User yyy will need appropriate privledges necessary to create the objects.用户 yyy 将需要创建对象所需的适当权限。

See: privileges required to import objects into your own schema.请参阅:将对象导入您自己的架构所需的权限。

http://docs.oracle.com/cd/E11882_01/server.112/e22490/original_import.htm#BABFHCBI http://docs.oracle.com/cd/E11882_01/server.112/e22490/original_import.htm#BABFHCBI

Also:还:

http://docs.oracle.com/cd/E11882_01/server.112/e22490/dp_overview.htm#CJAIBFJG http://docs.oracle.com/cd/E11882_01/server.112/e22490/dp_overview.htm#CJAIBFJG

Many Data Pump Export and Import operations require the user to have the DATAPUMP_EXP_FULL_DATABASE role and/or the DATAPUMP_IMP_FULL_DATABASE role.许多数据泵导出和导入操作要求用户具有 DATAPUMP_EXP_FULL_DATABASE 角色和/或 DATAPUMP_IMP_FULL_DATABASE 角色。 These roles are automatically defined for Oracle databases when you run the standard scripts that are part of database creation.当您运行作为数据库创建一部分的标准脚本时,这些角色会自动为 Oracle 数据库定义。 (Note that although the names of these roles contain the word FULL, these roles are actually required for all export and import modes, not only Full mode.) (请注意,虽然这些角色的名称中包含 FULL 一词,但实际上所有导出和导入模式都需要这些角色,而不仅仅是 Full 模式。)

The DATAPUMP_EXP_FULL_DATABASE role affects only export operations. DATAPUMP_EXP_FULL_DATABASE 角色仅影响导出操作。 The DATAPUMP_IMP_FULL_DATABASE role affects import operations and operations that use the Import SQLFILE parameter. DATAPUMP_IMP_FULL_DATABASE 角色影响导入操作和使用导入 SQLFILE 参数的操作。 These roles allow users performing exports and imports to do the following:这些角色允许执行导出和导入的用户执行以下操作:

•Perform the operation outside the scope of their schema • 在其架构范围之外执行操作

I believe, import user donot have permission on import database directory.我相信,导入用户没有导入数据库目录的权限。 In the Import db, select directory_name,directory_path from dba_directories;在导入数据库中,从 dba_directories 中选择 directory_name,directory_path; It will show the directory names sql>grant read,write on directory abc to ;它将显示目录名称 sql>grant read,write on directory abc to ;

Robertson Oracle Database SME +91-9886321339 Robertson Oracle 数据库 SME +91-9886321339

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM