The CrowdStrike outage of 2024
medium 30 minOn July 19, 2024 a content update for the CrowdStrike Falcon sensor asked a kernel driver to read a 21st input from a list of 20.
See it run
Replay the failure, then the repaired design, one step at a time.
Operations
Replay the failure
The path of one rule on July 19, 2024, as the root cause analysis describes it.
Step 1 of 8
A new rule
An engineer writes two template instances for named pipes. One has a real value in field 21.
Step 1: A new rule
rule = new_rule()validator.check(rule, fields=21) # trusts the definitioncloud.publish(rule, to="everyone") # no rings# on each machine, at the next pipe event:value = inputs[20] # only 0..19 existcompare(value, rule.field21)- Limits
- Nothing
- Costs
- 8.5 million devices, estimate
Follow the number 21. It is written in the definition and in the validator, but not in the code that supplies the values.
In the real world
The same the crowdstrike outage of 2024 doing real jobs. Pick one and step through it.
A million machines, our example numbers.
Step 1 of 2
Publish
The rule goes to 100% at once.
Step 1: Publish
Common mistakes
The bugs interviewers watch for, with the fix beside each.
One push for data
criticalData decides what the code does. Without rings a bad file reaches everyone.
Wrongpublish(rule, to="everyone")Rightfor ring in rings: publish(rule, to=ring) if not healthy(ring): rollback(); breakA validator with the same assumption
criticalIt agreed with the definition. The definition was wrong.
Wrongassert len(rule) == DEFINED # 21Rightassert used_fields(rule) <= SUPPLIED # 20Tests that use only wildcards
majorA wildcard never reads the field, so the field is not tested.
Wrongrule = [ANY] * 21Rightfor i in range(21): test([ANY] * i + ["x"] + [ANY] * (20 - i))Rollback that needs the network
majorA machine that crashes at start may never download the fix.
Wrongon_boot: load(newest)Righton_boot: load(previous if failed_starts >= 2 else newest)
Interview tips
How to explain it
- 21 fields defined, 20 inputs supplied.
- A wildcard hid it until July 19.
- Kernel read error, blue screen, boot loop.
Reach, read, return
- Reach: rings and bake time.
- Read: check count and index.
- Return: a way back without the network.
Numbers worth knowing
- 78 minutes from release to revert.
- 8.5 million devices, Microsoft's estimate.
- About 99% back by July 29.
Do not say
- The file was corrupt.
- The driver was updated.
- One test would not have mattered.