ORACLE ORA-39070: Unable to open the log file-guardiangel_MySQL, Oracle及数据库讨论区_Weblogic技术|Tuxedo技术|中间件技术|Oracle论坛|JAVA论坛|Linux/Unix技术|hadoop论坛_联动北方技术论坛  
网站首页 | 关于我们 | 服务中心 | 经验交流 | 公司荣誉 | 成功案例 | 合作伙伴 | 联系我们 |
联动北方-国内领先的云技术服务提供商
»  游客             当前位置:  论坛首页 »  自由讨论区 »  MySQL, Oracle及数据库讨论区 »
总帖数
1
每页帖数
101/1页1
返回列表
0
发起投票  发起投票 发新帖子
查看: 2512 | 回复: 0   主题: ORACLE ORA-39070: Unable to open the log file-guardiangel        下一篇 
    本主题由 koei123 于 2015-6-1 14:57:08 移动
justfriend
注册用户
等级:新兵
经验:61
发帖:62
精华:0
注册:2011-11-21
状态:离线
发送短消息息给justfriend 加好友    发送短消息息给justfriend 发消息
发表于: IP:您无权察看 2015-4-9 14:11:40 | [全部帖] [楼主帖] 楼主

导出测试时,报如下错误:

oracle@pc-centos u01]$ expdp  \'/  as  sysdba\'  directory=backupdir  full=y dumpfile=fullexp.dmp logfile=fullexp.log parallel=2
Export: Release 11.2.0.1.0 - Production on Wed Jan 15 05:03:00 2014
Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORA-39002: invalid operation
ORA-39070: Unable to open the log file.
ORA-29283: invalid file operation
ORA-06512: at "SYS.UTL_FILE", line 536
ORA-29283: invalid file operation


原因:在操作系统未有实际备份目录,创建并授权。

一、查看备份目录

SQL> select * from dba_directories;
OWNER                          DIRECTORY_NAME                 DIRECTORY_PATH
------------------------------ ------------------------------ --------------------------------------------------------------------------------
SYS                            BACKUPDIR                    /u01/backupdir/
SYS                            SQLDR                       /u01/oracle/sqldr
SYS                            EXPDIR                      /u01/expdir
SYS                            SUBDIR                         /u01/app/oracle/product/11.2.0/dbhome_1/demo/schema/order_entry//2002/Sep
SYS                            SS_OE_XMLDIR                   /u01/app/oracle/product/11.2.0/dbhome_1/demo/schema/order_entry/
SYS                            LOG_FILE_DIR                   /u01/app/oracle/product/11.2.0/dbhome_1/demo/schema/log/
SYS                            DATA_FILE_DIR                  /u01/app/oracle/product/11.2.0/dbhome_1/demo/schema/sales_history/
SYS                            XMLDIR                      /ade/b/1191423112/oracle/rdbms/xml
SYS                            MEDIA_DIR                      /u01/app/oracle/product/11.2.0/dbhome_1/demo/schema/product_media/
SYS                            DATA_PUMP_DIR                /u01/app/oracle/admin/orcl/dpdump/
SYS                            ORACLE_OCM_CONFIG_DIR          /u01/app/oracle/product/11.2.0/dbhome_1/ccr/state
11 rows selected


二、在操作系统上查看目录

root@pc-centos ~]# cd /u01
[root@pc-centos u01]# ls
app  expdir  temp


三、创建目录

[root@pc-centos u01]# mkdir backupdir
[root@pc-centos u01]# ls
app  backupdir  expdir  temp
[root@pc-centos u01]# ls -rlt
total 16
drwxr-xr-x. 4 oracle oinstall 4096 May 10  2012 app
drwxr-xr-x. 2 oracle oinstall 4096 Jul 26 20:40 temp
drwxr-xr-x. 2 oracle oinstall 4096 Jul 27 12:33 expdir
drwxr-xr-x. 2 root   root     4096 Jan 15 05:04 backupdir


四、授权

root@pc-centos u01]# chown -R oracle:oinstall backupdir
[root@pc-centos u01]# ls -rlt
total 16
drwxr-xr-x. 4 oracle oinstall 4096 May 10  2012 app
drwxr-xr-x. 2 oracle oinstall 4096 Jul 26 20:40 temp
drwxr-xr-x. 2 oracle oinstall 4096 Jul 27 12:33 expdir
drwxr-xr-x. 2 oracle oinstall 4096 Jan 15 05:04 backupdir


再执行导出,正常。

--转自 北京联动北方科技有限公司

该贴由koei123转至本版2015-6-1 14:57:07



赞(0)    操作        顶端 
总帖数
1
每页帖数
101/1页1
返回列表
发新帖子
请输入验证码: 点击刷新验证码
您需要登录后才可以回帖 登录 | 注册
技术讨论