raid6_recov_2data(9)
πΈ raid6_recov_2data(9) πΈ
okay bestie, so this is a page straight outta the Kernel API Manual and it's genuinely iconic β it's the little function that could when two of your data disks ghost you at the same time ππ no cap, this is the recovery glow-up you didn't know you needed.
β¨ NAME β¨
raid6_recov_2data β recover two missing data disks π«Ά (yes, two. two entire disks. main character energy fr fr)
β¨ SYNOPSIS β¨
void raid6_recov_2data (int disks , size_t bytes , int faila , int failb
, void **ptrs );
like, look at that signature. obsessed. π₯
β¨ ARGUMENTS β¨
disksβ the number of "disks" we're operating on, and yes that count includes the parity ones π (it's giving "everyone's invited to the party")bytesβ how long each vector is, in bytes πfailaβ index of the first failed data disk πfailbβ index of the second failed data disk ππptrsβ adisks-sized array of memory pointers π¦
β¨ DESCRIPTION β¨
so here's the vibe: this bad boy rebuilds bytes worth of missing data into ptrs[faila] and ptrs[failb], pulling from the data still chilling in the remaining disks and from the two parities pointed to by the other indices between 0 and disks - 1 in ptrs. π
disks counts both the data disks and the two parities β don't forget that part, it's lowkey important π
and bestie, listen: faila must be smaller than failb. that's not a suggestion, that's the law π (well, it's the spec. same thing.)
π¨ the memory pointed to by each pointer inptrsmust be page aligned and is limited toPAGE_SIZE. no exceptions, no "but just this once". this is a hard vibe check and if you fail it, bad things happen. periodt. π β¨
β¨ SEE ALSO β¨
- Kernel file
./lib/raid/raid6/algos.c raid6_gen_syndrome(9)raid6_xor_syndrome(9)raid6_recov_datap(9)
go read those too, they're the friend group and they all ate ππ
and that's the whole page, bestie!! this one lives in ./lib/raid/raid6 and it was blessed upon us in October 2026 β truly a moment π§ββοΈπ so go forth, recover those two disks, and slay β¨ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms