Use it as the gate around every automated change — and when a change "succeeded" but the network is not as intended.
Configuration Validation · Network Automation
Configuration validation checks that a configuration is right: before a change, that the candidate is valid and does what is intended; after it, that the device actually holds that configuration and the network behaves as expected.
1. Validate before and after: syntax, semantics (Batfish), operational state (routing, neighbors).
2. Fail the pipeline on issues.
3. Compare pre/post snapshots.
4. Automate rollback triggers.
5. Store results.
config → static analysis → deploy → state comparison
Context & applicabilityCommon mistakes · platform/version boundaries
Operational reference
Fast context before you go deeper.
show archive config differences nvram:startup-config system:running-configShow Commands
Read-only and diagnostic commands for confirming state, narrowing a fault and interpreting the current boundary.
show archive config differences nvram:startup-config system:running-configShowRead-only/validation observation for configuration differences between startup and running state.
Use when: Use as the prior manifest-approved bounded observation/validation surface for this exact Topic.
Quick note: Restores exact/ ownership only; this authored guidance is not observed production Evidence.
Cisco IOS / IOS XE · configurationshow archiveShowLists the configuration files saved in the IOS configuration archive and which one is the most recent.
Use when: You plan a rollback with configure replace, or want to see if automatic config archiving works.
Quick note: The archive is filled by "archive" with "path" and "write-memory" or "time-period". The files can be compared with show archive config differences.
Cisco IOS / IOS XE · configuration · verifiesshow archive log config allShowLists the configuration commands logged by the config change logger, with session, user and line.
Use when: You need to know who changed what on the device, and in which session.
Quick note: Requires "archive", "log config", "logging enable". Add "hidekeys" so passwords are not stored in the log. The log is lost at reload unless persistence is configured.
Cisco IOS / IOS XE · configuration · verifiesVerification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Operational evidence path Verify boundary
candidate/live config → parser/schema → rule/policy set → semantic/topology checks → validation result/exceptions → deployment/read-back → network acceptance
Healthy evidence: input revision, validator version and rule set are explicit, failures are explainable and live acceptance corroborates relevant post-change checks.
Step 2 Command read-back and what it shows Verify boundary
show archive config differences nvram:startup-config system:running-config is the bounded verification surface selected for Network Automation → Configuration Validation. A known-good result is candidate is valid for the target platform, native read-back/diff contains only the approved delta, affected prerequisites are healthy, and post-change verification criteria are defined before execution. Treat validation reports parser/semantic errors, unexpected device delta, unsupported feature or a clean text comparison that conflicts with platform-native state as broken/suspicious. show archive config differences shows a platform-specific configuration delta view on the selected device, but it does not show the candidate is authorized or that resulting protocols/applications will be healthy.
Step 3 Common mistakes Verify boundary
- Validating syntax but not intent.
Step 4 Failure modes and next checks Narrow the fault
Suspicious evidence: a generic pass is treated as complete safety while rule coverage, context or runtime dependencies are unknown.
Step 5 Observation-driven branch and next-check logic Narrow the fault
For a failing Network Automation → Configuration Validation case, freeze scope first: target/object, desired revision or request, and failure time. Inspect show archive config differences nvram:startup-config system:running-config. Branch on evidence rather than labels: if candidate cannot be parsed or rendered, stop before device comparison; if candidate parses but native diff contains unexpected lines, correct intent/source data; if diff is expected, perform bounded platform/state checks for affected features before approving deployment.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
Validate in two layers: configuration (is the intended text in the running configuration?) and state (are neighbours up, routes present, interfaces up?). A tool that reports success only knows the commands were accepted. Compare against state captured before the change.
- Batfish analysis (batfish/pybatfish) — pre-deployment validation
- Syntax check on device (candidate validate) — device-side
- Pre/post state comparison (pyATS/Genie) — behaviour
ReferenceWhat it is1 section · depth on demand
Core model
Separate parse/schema validity, policy compliance, semantic intent, contextual dependencies and live operational acceptance; each validator shows only its defined rule set.
ReferenceHow it works1 section · depth on demand
How it works
In Network Automation → Configuration Validation, effective state is split across candidate configuration intent, device running state, platform parser/semantic constraints and the exact delta that would result from applying the candidate. Network validation should compare intended candidate state with live device state and, where supported, use platform-native parsing or replace/diff facilities to expose what will actually change before mutation. Device model/software, privilege, feature licensing, transaction semantics and hidden/default configuration are separate things to check. This matters because a text diff can miss parser/default behavior, while a native diff that is clean can still omit downstream protocol or service consequences.
ReferenceImportant terms & boundaries2 sections · depth on demand
What this shows and what it does not
Validation shows only the configured rule set against the evaluated input/context; it cannot show omitted rules, dynamic dependencies or full network behavior.
In depth
Configuration validation checks generated or proposed configuration before it reaches devices: syntax, policy rules and expected behaviour. It catches errors while they are still just text.
| Validation level | Example tools |
|---|---|
| Data/schema | JSON Schema for source data |
| Rendering | Template unit tests |
| Policy | "All interfaces have descriptions", "no telnet" |
| Behaviour modelling | Batfish: reachability, ACL impact |
| Device-side | NETCONF validate, commit check |
from pybatfish.client.session import Session
bf = Session(host="batfish"); bf.init_snapshot("snapshots/new")
print(bf.q.undefinedReferences().answer().frame())
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in Network Automation > Configuration Validation. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://developer.cisco.com/site/networking/ · confidence 94%Terms & aliases
Hover a linked term for a quick definition; click it to open its glossary entry. Aliases are other names that find this Topic in search.
Quick lookup tables
Configuration Validation Network Automation proof-boundary map
Fast intent/scope, management-operation, device-state and network-acceptance boundaries for Configuration Validation.
| Boundary | Healthy evidence | Suspicious evidence |
|---|---|---|
| Intent / scope | Source revision and exact targets are explicit | Stale inventory, hidden selector or wrong variables change scope |
| Management operation | Transport/model/payload and per-device response are traceable | Auth/capability/parser differences hide partial or wrong execution |
| Device state | Effective and persistent state are read back | Accepted config/API result is mistaken for convergence |
| Network proof | Original control/data-plane or service test passes | Automation summary substitutes for actual network acceptance |