Rebuild a whole service from backup onto a fresh server, using only the runbook
Task
Write a restore runbook for the web service from the load-balancing lab, then use it -- and only it -- to rebuild the service onto a newly created VM from backups alone, as if the original server had been destroyed. Time the rebuild, log every gap where the runbook was not enough, and fix the runbook afterwards.
Steps
- Write
lab/rebuild/runbook.md: prerequisites, where the backups are, numbered steps to install, restore and configure, how to repoint DNS, and a final verification step. - Power lin-b off. Start a timer and record
startinlab/rebuild/log.csvwith headertime,event. - Follow the runbook exactly on lin-rebuild. Each time you need something the runbook does not give you, log a
gapevent with a description and keep going. - When the site answers correctly at its DNS name with a valid certificate, record
verifiedin the log, and savecurl -sIof it tolab/rebuild/verify.txt. - Update the runbook to close every gap, and record in
lab/rebuild/result.txtthe total minutes and the number of gaps found.
Verify
These checks run in a POSIX shell: Terminal on macOS or Linux, and on Windows Git Bash (it comes with Git for Windows) or WSL. A stock Windows PowerShell or Command Prompt has no awk or grep, so there the first line fails.
grep -Ec '^[0-9]+[.]' lab/rebuild/runbook.md
grep -Eic 'verify|verif' lab/rebuild/runbook.md
awk -F, '$2 ~ /^gap/ {g++} END {print g+0" gap(s) logged"}' lab/rebuild/log.csv
grep -Ec '^HTTP/[0-9.]+ 200' lab/rebuild/verify.txt
grep -Ec '[0-9]+' lab/rebuild/result.txt
The runbook has numbered steps ending in verification, the rebuilt service answered 200, and the log records the gaps you hit. A first run with no gaps is rare and usually means the author filled them from memory without noticing -- the test is meant to find exactly those.
Notes
This is a parallel test in the lesson's terms: the recovery was real, but the original stayed intact and switched off rather than destroyed, so the test risked nothing. A full interruption test would have used the rebuilt server for real traffic.
This is an independent study companion for CompTIA Server+ SK0-005 and is not produced by or endorsed by CompTIA.