What's a "battery relearn" on a LSI MegaRaid?

20,457

Usually battery relearning refers to draining a battery in order to determine how long it holds a useful charge.

In the case of a battery-backed write cache, this may be just to determine whether the battery is still good enough to trust your data to. Any useful write-caching solution must do this.

It's unfortunate to have a hardware RAID solution that disables the write cache due to battery-related issues. But it is worse to suffer the massive corruption of losing all the data in your write cache. Filesystems (and databases) are not designed to handle corruption of this type at all, and can fail catastrophically (not just losing recent data).

This is probably less relevant on "enterprise" class hardware due to mirroring of write cache between redundant controllers with separate batteries. So each one can be tested independently.

Share:
20,457

Related videos on Youtube

scobi
Author by

scobi

Updated on September 17, 2022

Comments

  • scobi
    scobi almost 2 years

    Our file server just started mailing us about how its battery backup is draining and it's switching from WB to WT mode and so on.

    I looked through its logs and found that it is configured to automatically do this periodically. It's called "battery relearning".

    What is this for? How often will it decide it needs to do this automatically?

    I searched the LSI docs and all I could find was the different status codes for the different relearning states. Not really helpful.

  • rackandboneman
    rackandboneman about 12 years
    "unfortunate to have a hardware RAID solution that disables the write cache" with LSI you can have it your way anyway, you can select the behaviour at least from the BIOS. "Always write back" is available for applications that will crash from the loss of write speed (heavily loaded web servers or hypervisors for example). Needs monitoring if you do so, of course.
  • George Erhard
    George Erhard over 7 years
    At least yours is actually testing the battery charge. I've a metric ton of aging Sun x6140's that simply 'expire' the cache battery packs after 3 years, regardless of their charge/discharge state. It'd not be too bad if it were one datacenter, we could just order batteries by the gross and be done with it. But ours are scattered all across the country!
  • ddm-j
    ddm-j over 3 years
    Also, the immense feeling of relief when you get an email that a battery went bad, and you open the server and find a bloated cushion in there that you can carefully remove before it burns.