DBAs should know about RAID cards _ MySQL

Source: Internet
Author: User
DBAs should know the RAID card knowledge bitsCN.com

For special applications such as databases, IOphotoshop/target = _ blank class = infotextkey> PS often becomes a bottleneck. there are not many effective methods to break through this bottleneck. in terms of software, I mainly focus on read/write splitting and vertical splitting, partition Table technology, cluster. The hardware is mainly raid and SSD.

Usually software and hardware are optimized at the same time. compared with the test, the hardware uses raid more often. Today, we will share the hardware raid knowledge.

  

What is raid?

Raid can provide data backup technology, expand storage space, and improve storage performance. I will not repeat the theoretical foundations of raid 0, raid 1, raid 0 + 1, raid 1 + 0, and raid 5. There are many such theories on google.

For database applications, we usually choose RAID 1 + 0. He is similar to raid5 in terms of disk space cost and security, but is superior to raid5 in terms of performance (IOphotoshop/target = _ blank class = infotextkey> PS, we generally use raid1 + 0.

Now let's start with the topic: raid Hardware Knowledge. of course, we just discuss the performance and security of raid hardware from the perspective of applications.

Cache

Cache is essential for a high-end RAID. Generally, the DDR2 memory particles used by RAID cards are almost the same as our memory. The adaptec cache is called DRAM, and DDR3 will certainly keep up with the development of hardware technology.

When it comes to caching technology, we must talk about two cache modes.

Write through system write requests are directly written to the hard disk, which is highly secure and has low performance.

Write back System write requests are first stored in the cache, and then unified back to the hard disk according to the time. because the cache write speed is much higher than the disk, this method can greatly improve the performance.

BBWC

In order to mine for better RAID write performance, Ele. me DBAs certainly want to enable the write back function to let our database fly. However, there was a very serious security problem at this time, that is, data loss caused by sudden power outages (the RAID card was previously mentioned to use a RAM storage device and data loss caused by power outages, however, the system layer has considered that the data has been written to the hard disk, so the system layer cannot provide any protection measures.) data loss is certainly unacceptable for DBAs. What should we do?

For this problem, BBWC-Battery-Backed Write Cache occurs. the core of BBWC is the BBU battery backup unit, which is a lithium battery. it is in the charging status when the system is started up. in case of power failure, the cache will be provided with the current required for refreshing, keep data intact until the data is written back to the disk at next boot. Some BBU and RAID cards have memory in one module, while some RAID cards connect to one battery through one connection line.

Disadvantages of BBWC:

1. Electromagnetic replacement and maintenance are required every 1-2 years. administrators may easily forget this issue. if the computer room is not far away from the computer room, the cost will be high.

2. the replacement of the electromagnetic field requires shutdown, and the machine must be dismounted and disassembled.

3. because the battery is also a fault point, the administrator needs to spend more time concerned about the work of the electromagnetic field.

4. the battery can provide a maximum of 72 hours of power supply. initialization takes several hours to charge.

5. environmentally friendly battery

FBWC

FBWC-Flash-Based Write Cache is introduced in view of the disadvantages of BBWC.

The principle of FBWC is to use the power stored in a group of "super capacitors" in a short period of time (about 1 minute) when a power outage occurs outside the system ), back up the cached data to the large-capacity FLASH memory on the raid card, knowing that the data will be written back to the hard disk after the next boot.

  FBWC and BBWCThe goal is almost the same, but the implementation methods are different.

Advantages of FBWC:

1. no maintenance is required. this will solve the problem for administrators.

2. data can be stored in flash for many years

3. the system can be started.

4. Environmental Protection

BitsCN.com

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.