重庆思庄Oracle、Redhat认证学习论坛

标题: ORA-16018 异常处理记录 [打印本页]

作者: denglj    时间: 2022-6-23 09:15
标题: ORA-16018 异常处理记录
数据库:oracle 11.2.0.4
系统:CentOS 7.9
问题描述:设置log_archive_dest时报错ORA-16018,如下所示:
SQL> alter system set log_archive_dest='/u01/app/oracle/oradata/orclsou/arch';
alter system set log_archive_dest='/u01/app/oracle/oradata/orclsou/arch'
*
ERROR at line 1:
ORA-02097: parameter cannot be modified because specified value is invalid
ORA-16018: cannot use LOG_ARCHIVE_DEST with LOG_ARCHIVE_DEST_n or DB_RECOVERY_FILE_DEST

说明:归档目录默认存放于db_recovery_file_dest指定的闪回恢复区,
如果设置了db_recovery_file_dest,就不能设置log_archive_dest.
log_archive_dest与log_archive_dest_n或db_recovery_file_dest不能一起使用

log_archive_dest_1为指定归档目录
log_archive_dest_2参数配置错误会导致主备库切换后新主库无法传文件到新备库

解决方案:
SQL> archive log list;
Database log mode              Archive Mode
Automatic archival             Enabled
Archive destination            USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence     1
Next log sequence to archive   3
Current log sequence           3
SQL> alter system set log_archive_dest_1='location=/u01/app/oracle/oradata/orclsou/arch';

System altered.

SQL> archive log list;
Database log mode              Archive Mode
Automatic archival             Enabled
Archive destination            /u01/app/oracle/oradata/orclsou/arch
Oldest online log sequence     1
Next log sequence to archive   3
Current log sequence           3
SQL> select open_mode from v$database;

OPEN_MODE
----------
MOUNTED

如上,成功修改归档目录.






欢迎光临 重庆思庄Oracle、Redhat认证学习论坛 (http://bbs.cqsztech.com/) Powered by Discuz! X3.2