Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Reminder about the risk of database file damage

2025-01-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Preface

Recently, Xiao y has dealt with several cases of case with corrupted Oracle database files, because some Bug are at greater risk, so they dare not have the slightest snub, so share them quickly! Hope to help friends in need! Risk hint!

As shown in the figure above, a known defect in Linux 5amp 6 will result in a bad block with all zeros in the Oracle data file under certain trigger conditions. The defects in the operating system will not only lead to the corruption of Oracle database data files, but also lead to the corruption of archived logs and online logs. If the online log of current status is corrupted, the impact on the database will be fatal. Need to be paid attention to!

BUG trigger condition:

A known flaw on a Linux can be triggered when the following conditions are met, resulting in corruption of database data files or archived files or online log files:

1. The operating system is Linux, and the version is Redhat 5ax 6 or Oralce Linux 5ax 6.

2. The file system where the data file / archive log / online log is located is ext4.

3. Database parameter filesystemio_options=SETALL (set to improve IO performance)

4. Database version from 10g to 12c

How to fix it?

1. Temporarily, you can bypass the BUG by modifying the database parameters

Filesystemio_options=none or

Filesystemio_options=ASYNCH or

Filesystemio_options=DIRECTIO

2. Further, it is suggested that the defects of Linux operating system should be repaired as soon as possible.

For Redhat 5

Fixed in kernel-2.6.18-238.el5-RHEL5.6 Errata RHSA-2011-0017 or later

For Redhat 6

Fixed in kernel-2.6.32-71 or later kernel version

For more information, please refer to My Oracle Support, document number 1487957.1:

ORA-1578 ORA-353 ORA-19599 Corrupt blocks with zeros when filesystemio_options=SETALL on ext4 filesystem using Linux (Doc ID 1487957.1)

Little y has dealt with this type of case several times, so let's take a look at the most recent CASE.

Related case sharing

Xiao y is not a person who knows how to live. Fault handling, performance tuning and other work occupy Xiao y's whole life, and he spends the rest of his time sleeping (what a boring person). Xiao y also fantasized about going out the door and making more friends. But little y is not good at talking, and helping others solve problems is a typical way for little y to make friends.

Recently, I saw an article named "Oracle" published by jeanron Yang Jianrong's official account on Wechat. The first problem is the problem that dataGuard always reports bad blocks in the database. The error is as follows

For this problem, jeanron has analyzed various scenarios, done more than a dozen tests before and after, basically excluded, rebuilt many times, the problem still can not be solved.

By the time I finished reading this article, combined with the case I had dealt with in the past, Xiao y could basically conclude:

Unfortunately for Jeanron, he met the Bug we mentioned at the beginning of the article!

Although I don't know jeanron well, helping people and making friends is something Xiao y is happy to do now.

So Xiao y sent a private letter to him, telling him that he might have encountered the Bug of the operating system, and asked him to do the following check. Fortunately, Xiao y guessed right again.

1. Check the operating system version

Check the result, meet the trigger condition of bug Redhat 5.3

2. Check the kernel version:

Check the result. The Bug of Linux will be triggered below kernel-2.6.18-238.el5.

The Kernel version is 2.6.18-194, which meets the Bug trigger condition.

3. Check the directory where the database files are stored:

Check the results. The database files are stored in the / home directory, which is the ext4 file system and meets the Bug trigger condition.

4. Check the filesystemio_options parameters:

Check the result that the database parameter filesystemio_options is SETALL, that is, both asynchronous IO and DIRECT IO, are supported to meet the Bug trigger condition.

5. Conclusions and results

As you can see, all the trigger conditions have been met, so you can confirm that the Linux BUG mentioned in the beginning has been hit.

After adjusting the filesystemio_options=NONE, jeanron confirms that the problem is finally resolved.

Xiao y is very happy, in addition to the sense of achievement brought by solving the problem.

Your own experience can help clients, help friends, and make friends.

Isn't that what Xiao y is pursuing?

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 210

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report