Course contents

Unit 12: Production capstonesLesson 12.6 (2 of 2 in this unit)59 of 63 in the Advanced Cisco SD-WAN course

Fault injection, validation and cutover report

Break the course lab five ways, measure each failure and turn the results into a validation table and a cutover report.

Advanced · 25 min read

You'll learn to record a baseline, inject five faults into the course lab one at a time, measure the effect of each, and write the results as a validation table and cutover report.

Technical definition

Fault injection means causing a failure on purpose, in a controlled way, to see what the design does. It turns a belief such as "if the MPLS link fails, traffic moves to the Internet" into a measurement. The test is useful only when you know the expected result before you start and write down what you saw.

The goal

A design that has not been broken on purpose is a design nobody has measured. This lab uses the network built in the first SD-WAN course: three controllers on the Internet transport, HUB-01, BR-01 and BR-02 as edges, an mpls and a biz-internet colour, and BR-02 on the Internet only. You will cause five failures, one at a time, write down what happens, and finish with the two documents a real cutover needs: a validation table and a report.

Diagram
The course lab: controllers, two transports and three edges
The course lab: controllers, two transports and three edges
The course lab: controllers, two transports and three edgesThe Manager, the Controller CTRL-01 and the Validator VAL-01 sit at the top and are reachable over the Internet transport. HUB-01 and BR-01 connect to both an MPLS transport coloured mpls and an Internet transport coloured biz-internet. BR-02 connects to the Internet transport only.Manager10.255.0.10CTRL-0110.255.0.11VAL-0110.255.0.12Internet (biz-internet)MPLS (mpls)HUB-0110.255.1.1BR-0110.255.2.1BR-0210.255.2.2Dashed: control connections to the controllers. Solid: transport links at each edge.

On small screens, swipe sideways or focus the diagram and use the arrow keys.

Every device that must reach the controllers needs a path over a transport. BR-02 has only one, so it is the site where a single failure removes all tunnels.
Diagram
Five stages of the lab
Five stages of the lab

Baseline, test plan, inject, restore, report.

  1. Baselinerecord normal
  2. Planpredict eachresult
  3. Injectone fault,measure it
  4. Restoreconfirm thebaseline
  5. Reporttable andfindings
Do not inject a second fault before the first is restored and the baseline is confirmed.

Stage 1: record the baseline

You cannot say a number is wrong unless you know what it should be. Before you break anything, record what normal looks like, on every edge, so that each test has something to compare against. In the lab's starting state, with no topology policy, the expected tunnel count is three BFD sessions at HUB-01, three at BR-01 and two at BR-02, because BR-02 has only the Internet transport and so no mpls tunnel.

Diagram
Baseline to record on each edge
Baseline to record on each edge
ItemCommandExpected in the lab
Control connectionsshow sdwan control connectionsUp to the Manager, Controller and Validator that this edge reaches; write down the count you see
OMP routesshow sdwan omp routesEach LAN prefix chosen, installed and resolved
BFD sessionsshow sdwan bfd sessionsHUB-01 3, BR-01 3, BR-02 2, all up
Reachabilityping vrf 10 to each LAN100 percent
Transition countersshow sdwan bfd sessionsNote the current numbers
Measured qualityshow sdwan app-route statsLoss, latency and jitter for each tunnel; fault 5 is compared with these
Keep the baseline in the same evidence log as the tests.

Stage 2: the test plan

The plan is a table with one row per fault. Fill in the "expected" column before you inject anything. The five faults cover the layers from the root-cause framework: an underlay link, a transport shared with the controllers, the Controller, the Manager and a degraded path.

Diagram
Fault injection plan
Fault injection plan
FaultHow to injectExpected resultEvidence
1 Hub mpls link downShut the mpls interface on HUB-01mpls tunnel to BR-01 drops; traffic moves to biz-internet; BR-02 unaffectedBFD sessions, ping loss count
2 BR-01 Internet link downShut the biz-internet interface on BR-01BR-01 loses controller reach; mpls tunnel to the hub stays up; BR-02 cannot be reached directlyControl connections, BFD, ping to BR-02
3 Controller offlineStop CTRL-01Edges lose their OMP peer; existing traffic continues; no new route changesControl connections, OMP summary, traffic
4 Manager offlineStop the ManagerData plane unaffected; no configuration pushes or monitoringTraffic check, Manager reachability
5 Degraded Internet pathAdd loss and delay on the underlay (start with 5 percent loss)Measured loss and latency rise on biz-internet tunnels; BFD stays up at this loss; traffic moves only if a policy existsapp-route stats, transition counters, ping loss
Expected results are predictions. A wrong prediction is a finding, not a failed test.

Stage 3: inject and measure

Take the faults in order. For each, start a paced ping from a LAN host at the source site, inject the fault, wait for the network to settle, then restore and count the lost replies. Use a host and not the edge router: a router sends the next probe as soon as the last one is answered, so on a healthy path its 100 probes finish in a moment and measure nothing. A Linux or Windows host sends one probe a second by default, so each lost reply is roughly one second of outage.

Example output written for this lesson, simplified; real output has more fields and a different layout
host-a$ ping -i 1 -c 100 192.168.10.1
64 bytes from 192.168.10.1: icmp_seq=67 ttl=62 time=94.1 ms
64 bytes from 192.168.10.1: icmp_seq=68 ttl=62 time=93.8 ms
64 bytes from 192.168.10.1: icmp_seq=79 ttl=62 time=118.2 ms
64 bytes from 192.168.10.1: icmp_seq=80 ttl=62 time=117.6 ms
--- 192.168.10.1 ping statistics ---
100 packets transmitted, 90 received, 10% packet loss, time 99107ms
The sequence numbers jump from 68 to 79, so probes 69 to 78 were lost: ten probes, about ten seconds, during fault 1. The round-trip time is higher afterwards because traffic now crosses the other transport. The lost-probe count goes into the report as the measured failover time for this path, with the BFD timers that were in use.

Ten lost probes can be read against the detection time. The edge declares a tunnel down only when the hello interval multiplied by the multiplier has passed with no answer, so the detection time is a floor under the outage.

Diagram
Lost pings and detection time
Lost pings and detection time
BFD multiplierDetection time (1 s hello)Probes lost at 1 per secondProbes lost at 5 per second
33 sabout 3about 15
55 sabout 5about 25
77 sabout 7about 35
1010 sabout 10about 50
Computed as hello interval times multiplier, then times the probe rate. The one-second hello is an assumption; defaults differ by release. Moving traffic to another tunnel adds time on top.

With a multiplier of 7, seven of the ten lost probes are detection. The other three are the time to move traffic to the biz-internet tunnel, a figure from the imagined run and not a promise for any release. A count of 7 would mean failover was detection alone. A count of 30 would mean something besides BFD was waiting, such as a policy or a route update, and the layers in the root-cause framework say where to look next.

Fault 5 needs a way to damage the underlay. If your lab routers sit behind a Linux node that acts as the Internet, use its traffic control tool to add delay and loss on the interface toward the edges.

sudo tc qdisc add dev eth1 root netem delay 100ms loss 5% sudo tc qdisc del dev eth1 root

On the Linux underlay node. The first command adds 100 ms of delay and 5 percent loss on eth1; the second removes it. Replace eth1 with the interface that faces the edges.

Predict the result before injecting it. Five percent random loss does not take a BFD session down, because a session is declared down only when every probe in the detection window is lost, which is seven in a row with a multiplier of 7. The table shows how fast that chance grows with the loss rate.

Diagram
How often random loss takes a BFD session down
How often random loss takes a BFD session down
Random lossChance 7 probes in a row are lostTimes down per hourMean time between
5 percent1 in 1.3 billion0.000003about 43 years
20 percent1 in 78,0000.04about 27 hours
30 percent1 in 4,6000.55about 1.8 hours
50 percent1 in 12814about 4 minutes
70 percent1 in 1289about 40 seconds
Computed for a one-second hello and a multiplier of 7, assuming each probe is lost independently; the 30, 50 and 70 percent rows were also checked by simulation. Real loss comes in bursts, so a real path can flap at lower averages. The table ignores the time a session needs to come back up.

So the fault with 5 percent loss tests measurement and policy, not liveness. To see the sessions flap, raise the loss to 50 percent or more. The ping also needs care: 100 probes at 5 percent random loss lose 5 on average, and any count from 1 to 10 is normal (the 95 percent range of the binomial), so repeat the run before calling a difference a finding.

Example output written for this lesson, simplified; real output has more fields and a different layout
BR-01#show sdwan app-route stats
TUNNEL (remote)                   LOSS  LATENCY  JITTER
mpls to HUB-01 mpls               0     46       7
biz-internet to HUB-01 biz-inet   5     158      12
biz-internet to BR-02 biz-inet    5     162      14
After fault 5 the two biz-internet tunnels show about 5 percent loss and about 100 ms more latency than the baseline, and the mpls tunnel is unchanged. That is the expected pattern: the damage is on one transport, so only the tunnels that cross it change. The BFD transition counters stay at their baseline values. With no SLA class applied, traffic keeps using the degraded path, which is itself a finding for the report.
Diagram
What fault 2 teaches
What fault 2 teaches

With the Internet link down, BR-01 keeps its mpls tunnel to the hub but loses the controllers and the path to BR-02.

Still worksmpls tunnel to hubtraffic to hub LAN
Lostcontroller reachdirect path to BR-02
A branch that reaches the controllers over one transport is frozen when that transport fails.

Stage 4: restore and confirm

After each fault, undo exactly what you did, wait for the sessions to return, and repeat the baseline checks. Do not start the next injection until every number matches the baseline. If a number does not return, you have found either a mistake in the restore or a real slow-recovery behaviour. Either is worth recording.

Stage 5: the validation table and the cutover report

The validation table is the plan with two columns added: what happened, and pass or fail. A test passes when the observed result matches the prediction. A test where the design behaves differently from the prediction is recorded as a finding, even if the behaviour is acceptable.

Diagram
Validation table, filled in
Validation table, filled in
FaultObserved in the example runResult
1 Hub mpls down10 of 100 probes lost; round-trip time rose; BR-02 unchangedPass
2 BR-01 Internet downControl connections 0; mpls BFD up; ping to BR-02 failedPass; finding: control rides one transport
3 Controller offline0 of 300 probes lost in 5 minutes; OMP peers downPass; finding: single Controller
4 Manager offline0 probes lost; no template push possiblePass
5 Degraded pathLoss 5, latency about 100 ms higher; BFD unchanged; no path changePass; finding: nothing steers around it
Example results from one imagined run, written for this lesson and not captured from a device. Your numbers will differ; the layout is what to copy.
Diagram
A cutover report, section by section
A cutover report, section by section
SectionWhat it holds
ScopeSites, transports and applications covered by the cutover
BaselineThe numbers recorded in stage 1
TestsThe validation table with observed results and measured failover times
FindingsWhere behaviour differed from the prediction, or a design gap was found
Open risksSingle points of failure and who owns each decision
RollbackThe steps and the time needed to return to the previous network
Sign-offWho approved the cutover and when
A report that lists open risks honestly is more useful than one that reports only passes.

In this lab the findings write themselves. Fault 2 shows that BR-01 depends on one transport for control, and fault 3 shows that a single Controller is a single point of failure for any change. Neither is a bug. Both are design facts that a cutover approver should read before signing, and the Course's controller high availability and dual-edge lessons describe the fixes.

Learn more: SD-WAN Root-Cause FrameworkController High Availability

Test yourself

Predict · scenario 1

Why fill in the expected-result column before injecting a fault?

Predict · scenario 2

CTRL-01 is stopped and the only Controller is offline. What is the expected effect on traffic already flowing between edges?

Predict · scenario 3

During fault 1, ten pings are lost at one per second. What does the report record?

Predict · scenario 4

Running ping repeat 100 on the edge router finishes in a moment on a healthy path. Why is it a poor failover timer?

Predict · scenario 5

With a 1-second hello and a multiplier of 7, 5 percent random loss is added to the biz-internet underlay. What is the expected BFD result?

Predict · scenario 6

Ten probes are lost during fault 1 and the detection time is 7 seconds. How is the result best read?

FAQ

Why write the expected result before the test?
If you write it afterwards, you will explain whatever happened. A prediction written first can be wrong, and a wrong prediction is the most useful result of a test because it shows a belief about the design that was not true.
Why change only one thing at a time?
With two faults at once you cannot tell which one caused an effect, and the restore step becomes uncertain. Restore each fault and confirm the baseline before the next injection.
Why use a host for the ping and not the edge router?
A router sends the next probe as soon as the last one is answered, so on a healthy path 100 probes finish in a moment and say nothing about time. A Linux or Windows host sends one probe a second by default, so each lost reply is about one second of outage.
Will 5 percent packet loss take a BFD session down?
No, not at that rate. A session is declared down only when every probe in the detection window is lost, which is seven in a row with a multiplier of 7. At 5 percent random loss that is roughly one chance in 1.3 billion per window, so the loss shows in the measured quality figures and the session stays up.
How long should a fault stay in place?
Long enough for the effect to settle: at least several times the detection time, and until two checks in a row show the same counters. With a detection time of 7 seconds, 30 to 60 seconds is a reasonable wait before measuring.
Is this safe on a production network?
No. These faults are for the lab. Before a production cutover, run the same plan in the lab, then agree a smaller, approved set of checks for the live network.