Pcornel
Browse topics
Options
Recent
Favorites
Automation · Technical reference

YANG · Cisco Automation

Direct answer

YANG is a data modelling language that defines the structure of device configuration and state. Cisco supports native and OpenConfig models, used through NETCONF, RESTCONF and gNMI.

When to use this

Use this when using YANG models with Cisco devices.

First 30 seconds

1. YANG on Cisco: native models (most complete), OpenConfig, IETF.

2. Explore with YANG Suite.

3. Model versions per IOS XE release.

4. Test payloads in lab.

5. Document paths used.

Operational verification

YANG model → payload → device

Context & applicabilityCommon mistakes · platform/version boundaries
Platform / version applicability
YANG 1.1 data modeling
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

PlatformYANG 1.1 data modeling · Automation implementations are tool and platform specific. Use the adjacent Domain for the technology being automated and this Domain for automation behavior.
Scope / prerequisiteUse this when using YANG models with Cisco devices.
What next?3 suggested next steps
Evidence1
On this pageJump to a specific section
Operational workflow

Verification & Troubleshooting

Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.

3 steps Observe → verify → isolate → change minimally → repeat the original test.
ObservedRecord what the original test actually shows

Capture the concrete output, symptom, packet, log or counter before changing anything.

Step 1 Verification path Verify boundary

Record device ID/management endpoint, platform/version, YANG model/revision or CLI operation, request/run ID; inspect the runtime/control-plane result; then query the selected Cisco device configuration/operational state and forwarding behavior where relevant through an independent read path and compare it with the versioned intent. The negative fixture should deliberately exercise risks such as platform syntax/model drift, privilege/auth mismatch, partial config, parser success without feature activation, asynchronous convergence and controller cache differing from device state, choosing the cases most relevant to YANG module/schema identity, revision/namespace, constraints and how modeled data is exposed through NETCONF/RESTCONF implementations.

Step 2 Common mistakes Narrow the fault
  • Using native models where OpenConfig is needed across vendors (or the reverse).
Step 3 Where it fails Narrow the fault

Failure analysis for Cisco Automation → YANG should follow the path through the components: inventory/controller → transport/API/CLI → device parser/YANG datastore → control-plane state → forwarding/operational read-back. Before retrying a mutating operation, read current target state using the stable identity device ID/management endpoint, platform/version, YANG model/revision or CLI operation, request/run ID; if state is unknown, stop broad retries.

Evidence references

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.

observation · 1
Key points
  • Native and OpenConfig models.
  • Used by NETCONF, RESTCONF and gNMI.
  • Check model support per release.
Key checks
  • show netconf-yang datastores — datastores
  • YANG Suite / pyang exploration — models
  • Cisco-IOS-XE-native vs openconfig — model choice
ReferenceWhy it matters1 section · depth on demand

In depth

On Cisco platforms, YANG models come in three families: Cisco native models (e.g. Cisco-IOS-XE-native) covering almost all CLI features, OpenConfig models for multi-vendor work, and IETF models for basics. Operational data uses -oper models.

NeedModel to look at
Full IOS XE feature configCisco-IOS-XE-native and feature sub-modules
Interface stateCisco-IOS-XE-interfaces-oper or openconfig-interfaces
Vendor-neutral configopenconfig-*

The models for each release are published in the YangModels GitHub repository (vendor/cisco/xe/<release>); match the model version to the device's software release.

ReferenceImportant terms & boundaries1 section · depth on demand

Mechanics

Cisco Automation → YANG is owned at runtime by the automation client/controller communicating with Cisco devices through supported APIs, YANG models or CLI. Its durable intent is versioned automation with device inventory, platform/model capability expectations and bounded configuration intent; the stable identity contract is device ID/management endpoint, platform/version, YANG model/revision or CLI operation, request/run ID. Follow the chain of components inventory/controller → transport/API/CLI → device parser/YANG datastore → control-plane state → forwarding/operational read-back and record which layer currently owns truth. The linked authority for bounded mechanics is RFC 7950 — The YANG 1.1 Data Modeling Language; documentation support is separate from observed lab/production Evidence.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor docYANG 1.1 data modeling current

Authoritative/upstream documentation reviewed for bounded claims in Cisco Automation > YANG. Documentation verification only; this is not observed lab or production Evidence.

Basis: https://www.rfc-editor.org/rfc/rfc7950 · confidence 94%
Depth when you need it

Deep reference

Healthy vs suspicious evidence

Output interpretation

For YANG module/schema identity, revision/namespace, constraints and how modeled data is exposed through NETCONF/RESTCONF implementations, prefer typed fields and stable IDs over human presentation text.

Confirmation

Confirm action

Continue?