Second, the OMF management of the log file
Log file management parameters: Db_create_online_log_dest_n
Db_create_online_log_dest_n:oracle the default path when you create an online log file and a control file without explicitly specifying a path
--View the parameters of the log file, the following is an db_create_online parameter that is not set
Sql> Show PARAMETER Db_create_online
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
Db_create_online_log_dest_1 string
Db_create_online_log_dest_2 string
Db_create_online_log_dest_3 string
Db_create_online_log_dest_4 string
Db_create_online_log_dest_5 string
--From the above you can see that the system reserved a log group members to form OMF, in general, we just need a member. Because you set a parameter file here
--The following is the creation of a log file without a setting, the default is to place a file in the path of the data file and in the flashback area, because both of these paths are OMF paths, as follows:
Sql> SELECT member from V$logfile;
Member
--------------------------------------------------------------------------------
/u01/app/oracle/oradata/orcl/redo03.log
/u01/app/oracle/oradata/orcl/redo02.log
/u01/app/oracle/oradata/orcl/redo01.log
/u01/app/oracle/oradata/orcl/orcl/onlinelog/o1_mf_4_5vtgzjyz_.log
/u01/app/oracle/flash_recovery_area/orcl/onlinelog/o1_mf_4_5vtgzlhb_.log
Sql> Show PARAMETER Db_create_file_dest
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
Db_create_file_dest STRING/U01/APP/ORACLE/ORADATA/ORCL
Sql> Show Parameter Db_recovery_file_dest
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
Db_recovery_file_dest String/u01/app/oracle/flash_recovery
_area
Db_recovery_file_dest_size Big Integer 2G
--Store the log file under the specified Disk1,disk2
Sql> Ho Mkdir/u01/app/oracle/disk1
Sql> Ho Mkdir/u01/app/oracle/disk2
sql> ALTER SYSTEM SET db_create_online_log_dest_1 = '/u01/app/oracle/disk1 ';
System altered.
sql> ALTER SYSTEM SET db_create_online_log_dest_2 = '/u01/app/oracle/disk2 ';
System altered.
sql> ALTER DATABASE ADD logfile;
Database altered.
Sql> SELECT * from V$logfile; /* You can see the new log file under Disk1,disk2 * * *
group# STATUS TYPE member Is_
---------- ------- ------- ---------------------------------------- ---
3 Online/u01/app/oracle/oradata/orcl/redo03.log NO
2 Online/u01/app/oracle/oradata/orcl/redo02.log NO
1 Online/u01/app/oracle/oradata/orcl/redo01.log NO
4 Online/u01/app/oracle/oradata/orcl/orcl/online NO
See more highlights of this column: http://www.bianceng.cnhttp://www.bianceng.cn/database/Oracle/