Create multiple redo log groups manually

Source: Internet
Author: User

Command for viewing logs:
1. view log member information
SQL> select group #, member, status from v $ logfile order by group #;
2. view the log group information and the currently used log Group
SQL> select * from v $ log;
3. Add a log Group
SQL> alter database add logfile group 4 (
'/Database/oradata/yang/redo04.log ',
'/Database/oradata/yang/redo044.log') size 50 m;
4. Add log members
SQL> alter database add logfile member
'/Database/oradata/yang/redo05.log' to group 5;
5. Delete log members
SQL> alter database drop logfile member
'/Database/oradata/yang/redo05.log ';
6. delete a log Group
SQL> alter database drop logfile group 5;
7. After you manually delete the Oracle log group members in the operating system, you must manually delete the records in the control file. Otherwise, an error will be reported in the warning file when the system is started.
Manually delete the log member information in the control file:
SQL> alter database drop logfile member
'/Db/oracle/oradata/yang/redo05.log ';
8. Rename the log file
SQL> alter database rename file '/db/oracle/oradata/yang/redo01.log'
To '/db/oracle/oradata/yang/redo011.log ';
Note: Each log group contains at least two members and at least two log groups. We recommend that you create five log groups.
9. Change the database to archive mode.
SQL> archive log list view database archive Mode
SQL> shutdown immediate shut down the database normally
SQL> startup mount start database to mount status
SQL> alter database archivelog
SQL> alter database open; open the database
10. Archiving Log Path redirection or multi-path archiving log
SQL> show parameter recover: Check the size of the quick recovery zone. The default value is 2 GB.
SQL> show parameter archive
SQL> alter system set log_archive_dest_1 = 'location =
/Home/oracle/archivelog '; Path 1 of archiving logs
SQL> alter system set log_archive_dest_2 =
'Location = USE_DB_RECOVERY_FILE_DEST ';
Path 2

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.