mount 状态修改日志文件名称
SQL> select open_mode,DATABASE_ROLE from v$database;
OPEN_MODE DATABASE_ROLE
-------------------- ----------------
MOUNTED PHYSICAL STANDBY
查看redo文件状态
GROUP# THREAD# SEQUENCE# BYTES BLOCKSIZE MEMBERS ARC STATUS FIRST_CHANGE# FIRST_TIM NEXT_CHANGE# NEXT_TIME
---------- ---------- ---------- ---------- ---------- ---------- --- ---------------- ------------- --------- ------------ ---------
1 1 115 52428800 512 1 NO CURRENT 3769973 28-JUL-22 2.8147E+14
3 1 114 52428800 512 1 NO INACTIVE 3744793 28-JUL-22 3769973 28-JUL-22
2 1 113 52428800 512 1 NO INACTIVE 3708300 27-JUL-22 3744793 28-JUL-22
select member from v$logfile;
MEMBER
--------------------------------------------------------------------------------
/home/oracle/app/oracle/oradata/helowin/redo03.log
/home/oracle/app/oracle/oradata/helowin/redo02.log
/home/oracle/app/oracle/oradata/helowin/redo01.log
修改文件位置
alter database rename file '/home/oracle/app/oracle/oradata/helowin/redo03.log' to '/home/oracle/test/redo03.log';
alter database rename file '/home/oracle/app/oracle/oradata/helowin/redo02.log' to '/home/oracle/test/redo02.log';
alter database rename file '/home/oracle/app/oracle/oradata/helowin/redo01.log' to '/home/oracle/test/redo01.log';
select member from v$logfile;
MEMBER
--------------------------------------------------------------------------------
/home/oracle/test/redo03.log
/home/oracle/test/redo02.log
/home/oracle/test/redo01.log
生成redo日志文件,重新初始日志文件:
alter database clear logfile group 1;
alter database clear logfile group 2;
alter database clear logfile group 3;