Friday 12 November 2021

Move Redolog files from One drive to another Drive in Oracle (Windows)

 SQL> select member from v$logfile;
MEMBER
--------------------------------------------------------------------------------
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_1_JRR7NHRN_.LOG
E:\ORCL\ONLINELOG\O1_MF_1_JRR7NHY2_.LOG
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_2_JRR7NLC7_.LOG
E:\ORCL\ONLINELOG\O1_MF_2_JRR7NLJJ_.LOG
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_3_JRR7NNPZ_.LOG
E:\ORCL\ONLINELOG\O1_MF_3_JRR7NNX3_.LOG
6 rows selected.

SQL> shut immediate
Database closed.
Database dismounted.
ORACLE instance shut down.


Move redolog files from E:\ORCL\ONLINELOG\ to required destination C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\, cut paste.


SQL> startup mount
ORACLE instance started.
Total System Global Area 5100272704 bytes
Fixed Size                  9038912 bytes
Variable Size             905969664 bytes
Database Buffers         4177526784 bytes
Redo Buffers                7737344 bytes
Database mounted.


SQL> alter database rename file 'E:\ORCL\ONLINELOG\O1_MF_1_JRR7NHY2_.LOG' to 'C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_1_JRR7NHY2_.LOG';
Database altered.
SQL> alter database rename file 'E:\ORCL\ONLINELOG\O1_MF_2_JRR7NLJJ_.LOG' to 'C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_2_JRR7NLJJ_.LOG';
Database altered.
SQL> alter database rename file 'E:\ORCL\ONLINELOG\O1_MF_3_JRR7NNX3_.LOG' to 'C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_3_JRR7NNX3_.LOG';
Database altered.


SQL> select member from v$logfile;
MEMBER
--------------------------------------------------------------------------------
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_1_JRR7NHRN_.LOG
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_1_JRR7NHY2_.LOG
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_2_JRR7NLC7_.LOG
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_2_JRR7NLJJ_.LOG
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_3_JRR7NNPZ_.LOG
C:\APP\ORACLE\ORADATA\ORCL\ONLINELOG\O1_MF_3_JRR7NNX3_.LOG
6 rows selected.



SQL> alter database open;
Database altered.
SQL>

No comments:

Post a Comment

How to put newly created Oracle database in archivelog mode?

SQL> ARCHIVE LOG LIST SQL> alter system set log_archive_dest_1='LOCATION=/oracle/archive/ORADB' scope=both; SQL> ALTER SYST...