database 在 12c 中查找数据泵转储位置

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/27611981/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-08 07:52:06  来源:igfitidea点击:

Finding Data Pump Dump Location in 12c

databaseoracleimportoracle12c

提问by James Panetti

First and foremost, apologies for a very novice question here. I was just starting to get the hang of how the data pump dump worked in 11g when the customers I support moved to 12c. Darn the luck. :)

首先,在这里为一个非常新手的问题道歉。当我支持的客户迁移到 12c 时,我才刚刚开始了解数据泵转储在 11g 中是如何工作的。该死的运气。:)

So a hopefully quick question: I'm using a coworker's Windows server running 12c to try to import a customer's data pump dump (have their dump and log file), but I have no idea where to place the dump for import. When I run:

所以一个希望很快的问题:我正在使用运行 12c 的同事的 Windows 服务器来尝试导入客户的数据泵转储(有他们的转储和日​​志文件),但我不知道在哪里放置转储以进行导入。当我运行时:

select * from dba_directories where directory_name='DATA_PUMP_DIR';   

this is the output returned:

这是返回的输出:

c:\ade\aime_v\oracle/admin/seeddata/dpdump/

That directory does not exist anywhere on this machine, plus it looks like an unusual directory path. (My coworker is on vacation, else I'd just ask of course).

该目录在这台机器上的任何地方都不存在,而且它看起来像一个不寻常的目录路径。(我的同事正在休假,否则我当然会问)。

So has something changed in 12c where it treats directories a bit differently? I keep thinking surely the one who created this server couldn't have just pointed the data pump dir to a non-existent path like that. I'm presently googling myself in circles, so I suppose the short question is simply where do I begin as a first step in figuring out where my directory is for dropping my dump import file?

那么 12c 中对目录的处理方式是否有所改变?我一直在想,创建这个服务器的人肯定不能只是将数据泵目录指向这样一条不存在的路径。我目前正在搜索自己的圈子,所以我想这个简短的问题很简单,作为第一步,我应该从哪里开始,找出我的目录在哪里放置我的转储导入文件?

Again, apologies for the embarrassingly newbie question, and thanks in advance for entertaining my question.

再次为这个令人尴尬的新手问题道歉,并提前感谢您接受我的问题。

采纳答案by Mark Stewart

Oracle will let you create a directory metadata entry to a non-existant physical directory which is what happened here. So whatever user has CREATE ANY DICTIONARYauthority would need to (re-)create the Oracle metadata directory to an existing directory, and ensure the operating system permissions on the physical directory are set up to allow the Oracle user ID to read and write to that directory. As @OldProgrammer suggested, it looks like someone combined half Unix and half Windows path separators.

Oracle 将允许您为不存在的物理目录创建目录元数据条目,这就是这里发生的情况。因此,任何具有CREATE ANY DICTIONARY权限的用户都需要(重新)创建 Oracle 元数据目录到现有目录,并确保对物理目录的操作系统权限设置为允许 Oracle 用户 ID 读取和写入该目录。正如@OldProgrammer 所建议的那样,看起来有人将半 Unix 和半 Windows 路径分隔符组合在一起。

If there is a directory c:\ade\aime_v\oracle\admin\seeddata\dpdump (and your dump file is there) then the following should work; if you are importing from a non-dba ID (some_user in the sample below), you will need to have the dba grant read on that directory also:

如果有一个目录 c:\ade\aime_v\oracle\admin\seeddata\dpdump(并且您的转储​​文件在那里),那么以下应该可以工作;如果您从非 dba ID(以下示例中的 some_user)导入,您还需要在该目录上读取 dba 授权:

drop directory data_pump_dir;
create directory data_pump_dir as 'c:\ade\aime_v\oracle\admin\seeddata\dpdump';
-- grant read on data_pump_dir to some_user;

回答by Ashish Sahu

Use the following sql query.

使用以下 sql 查询。

select * from dba_directories where directory_name='DATA_PUMP_DIR';