# ECC Memory and Hot Swapping

> Why servers use ECC memory that fixes its own flipped bits. Which parts can be swapped while the server keeps running.

**Course:** [Servers and Racks](https://learn.benibix.com/learn/infrastructure-servers)  
**Time:** 10 min

**After this lesson you can:**

- Explain what ECC memory catches
- Name parts that can be hot swapped
- Say why a spare must be ready first

## How a server keeps going when a part slips

Servers use two tricks that desktops rarely have. ECC memory finds and fixes small errors in memory on its own. Hot swapping lets you pull out a dead part and slide in a new one while the server keeps running. Both exist so that a server can run for years without stopping.

Now and then, one bit in memory flips by itself, from 0 to 1 or back. A large study of one company's servers found that about a third of them saw at least one memory error a year. In normal memory, the wrong value is passed on. A program may crash, or save bad data with no warning.

ECC stands for error-correcting code. The memory stores 8 extra check bits for every 64 bits of data. When it reads the data back, it checks the two against each other. It fixes any single flipped bit on the spot, and it raises an alarm if two bits flip at once.

Hot swapping means changing a part while the power is on. Drives, power supplies and fans are often built for it. They sit in trays at the front or back and slide out without tools. A small light often shows which drive has failed.

Hot swapping only works when a spare is already doing the job. A drive can be pulled because the data is also on another drive. A power supply can be pulled because a second one is carrying the load. Pull the only one, and the server stops.

Memory and the main chip are rarely swapped while a normal server runs. To change them, you shut the server down. That is one reason big services run many servers. One can stop for repair while the others carry on.

A common mistake is to pull the wrong drive. In a row of eight, the dead one and the healthy one look the same. Pulling the healthy one when its partner has already failed can lose all the data. Check the light and the drive number twice before you touch the tray.

![A rack server seen from the front and the back. The front shows a row of drive bays, one drive half pulled out while the server is on. The back shows two power supplies plugged into two separate power lines, network sockets and one separate socket marked BMC. Inside, memory sticks are marked ECC.](https://learn.benibix.com/diagrams/inf3-server-parts.svg)

### Example: A drive fails on a Sunday

A shop's server holds its data on two mirrored drives. On Sunday night, one drive fails and its light turns red. The website keeps working on the other drive.

On Monday, a technician slides out the red drive and slides in a new one. The server copies the data across in 3 hours, and the site never goes down.

**Words in this lesson:** [Error-Correcting Code Memory (ECC Memory)](https://learn.benibix.com/term/infrastructure/ecc-memory), [Hot Swapping](https://learn.benibix.com/term/infrastructure/hot-swapping)

**Question:** When can you safely hot swap a part in a server?

**Answer:** When a second part is already doing the same job. Hot swapping works because a spare carries the load while the dead part is out. Pull a part with no spare, and the server stops.

---

Source: https://learn.benibix.com/learn/infrastructure-servers/ecc-memory-and-hot-swapping
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-19
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
