Failure groups in ASM

Source: Internet
Author: User

The Automatic Storage Management (ASM) technology in Oracle Database 10 Gb provides an image redundancy method to protect data loss caused by possible disk failures. You know, we may need raid to achieve this purpose in the past, but now the Oracle database itself provides you with this option, put all the eggs in the Oracle basket. We are unbreakable.

ASM provides three redundancy methods.

External Redundancy indicates that Oracle does not help you manage images. functions are implemented by external storage systems, such as RAID technology.
Normal redundancy (default) indicates that Oracle provides two images to protect data.
High Redundancy indicates that Oracle provides three images to protect data.

First, let's give a preview. If you have time to write it again, believe me. If you have internal documents (many of the words used in this article come from some Metalink internal translations, because inernal does not do link.

What is ASM failure group?
Oracle uses failure group to provide high data availability. The image algorithm used by ASM is not an image of the entire disk, but an image of the extent level. Therefore, it is obvious that it is unwise to use disks of different capacities for each failure group, because problems may occur when Oracle allocates the next extent. In normal redundancy mode, each extent allocated in the ASM environment has a primary copy and a second copy, the ASM algorithm ensures that second copy and primary copy must be in different failure groups. This is the meaning of failure group. Through this algorithm, ASM ensures that even if all the disks in a failure group are damaged, the data is still intact.

When Oracle allocates extent, the extent in all failure groups that have the same data is called an extent set. When Oracle writes data to a file, primary copy mayAnyFailure group, while second copy is in another failure group. When Oracle reads data, unless primary copy is unavailableRead data from primary copy firstOracle ensures that Data Reading is distributed across multiple disks as much as possible.

Because a disk that shares a hardware module is likely to be damaged or invalid at the same time, when designing a failure group, we should put a large disk in a tray disk in a failure group, so that we can take a tray, invalidate the failure group, and replace it with a new tray and disk, this is the same as raid.

Once set, the ASM redundancy mode cannot be changed. If we want to change normal redundancy to high redundancy, we can only create a new failure group, then, move the files in the old failure group to the new failure group using RMAN or dbms_file_transfer.

What happens if no failure groups is created in the ASM environment?
Even if it is not explicitly specified, failure groups will always be created. In this case, each disk belongs to a failure group. When creating a disk group, the failure group is created by default. The name is the disk name.

How many failure groups should be created?

When should I use external redundancy? When should I use normal or high redundancy?

How can I recover a fault in a failure group?
-How to Use the kfed utility to view the ASM disk Header

The database we tested is oracle10.2.0.2. First, we need to compile and generate the kfed program. The methods for generating kfed in other versions of Oracle are slightly different.
CD $ ORACLE_HOME/rdbms/lib
Make-F ins_rdbms.mk ikfed
Kfed programs will be generated in the $ ORACLE_HOME/bin directory.

The kfed syntax is:Kfed read * devicename * text = * filename *
Suppose we want to read the/dev/raw/raw1 file header, then use the following statement
Kfed read/dev/raw/raw1 text = raw1.out
In this way, raw1's file header information will be dump to the raw1.out file. If you are interested, you can check the file content. Basically, you can guess what the content is based on the name and value, including the time when the ASM disk was created, the size of each block, the disk name, the disk group, and the header status. Although most of the content can be obtained from the data dictionary of the ASM instance, when we encounter an ASM disk failure, the information provided by kfed is often easier for us to determine the problem.

-How to clear the ASM Disk

Sometimes an ASM disk cannot be deleted due to a fault, and it cannot be added or deleted, generally, the status of the disk header is incorrect, but the disk header still retains information about some disk groups. In this case, we need to clear the disk and then add it to the disk group again.
Dd If =/dev/Zero of = * diskname * BS = * blocksize * COUNT = 10000.

 

 Original article addressHttp://www.dbform.com/archives/218

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.