如何从dmp文件和日志文件导入Oracle数据库? [英] How to import an Oracle database from dmp file and log file?

查看:579
本文介绍了如何从dmp文件和日志文件导入Oracle数据库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我将如何从dmp文件创建数据库?我的系统上没有现有的具有相同结构的数据库,因此它必须包含作业,事件,表等.

How would I go about to create a database from a dmp-file? I do not have an existing database with the same structure on my system so it has to be complete with jobs, events, tables and so on.

我将dmp和日志文件放在E:驱动器中

I placed dmp and log file in E: drive

我尝试了导入实用程序

E:/>impdp system/tiger@oratest FILE=WB_PROD_FULL_20MAY11.dmp

但是我收到了错误消息

invalid argument value
bad dump file specification
unable to open dump file "E:\app\Vensi\admin\oratest\dpdump\WB_PROD_F
ULL_20MAY11.dmp" for read
unable to open file
unable to open file
(OS 2) The system cannot find the file specified.

当我在Windows资源管理器中看到dmp文件时(从Linux服务器获取)显示为崩溃转储文件

And when I see in Windows Explorer dmp file(taken from Linux server) is showing as Crash dump file

我不明白如何解决此问题.请帮我解决这个问题.

I donot understand how I can resolve this issue. Please help me to solve this issue.

我是Oracle的新手...

I'm a complete newbie on Oracle...

推荐答案

数据库如何导出?

  • 如果使用exp导出并且导出了完整模式,则

  • If it was exported using exp and a full schema was exported, then

  1. 创建用户:

  1. Create the user:

create user <username> identified by <password> default tablespace <tablespacename> quota unlimited on <tablespacename>;

  • 授予权利:

  • Grant the rights:

    grant connect, create session, imp_full_database to <username>;
    

  • imp开始导入:

  • Start the import with imp:

    imp <username>/<password>@<hostname> file=<filename>.dmp log=<filename>.log full=y;
    

  • 如果使用expdp导出,则使用impdp开始导入:

  • If it was exported using expdp, then start the import with impdp:

    impdp <username>/<password> directory=<directoryname> dumpfile=<filename>.dmp logfile=<filename>.log full=y;
    

  • 查看错误日志,似乎您没有指定目录,因此Oracle尝试在默认目录(即E:\app\Vensi\admin\oratest\dpdump\)中找到dmp文件.

    Looking at the error log, it seems you have not specified the directory, so Oracle tries to find the dmp file in the default directory (i.e., E:\app\Vensi\admin\oratest\dpdump\).

    将导出文件移动到上面的路径,或者创建目录对象以指向存在dmp文件的路径,然后将对象名称传递给上面的impdp命令.

    Either move the export file to the above path or create a directory object to pointing to the path where the dmp file is present and pass the object name to the impdp command above.

    这篇关于如何从dmp文件和日志文件导入Oracle数据库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

    查看全文
    登录 关闭
    扫码关注1秒登录
    发送“验证码”获取 | 15天全站免登陆