Pcornel
Automation · Network Automation

NETCONF

Cheat sheet · https://pcornel.dk/topic.php?topic=5592

Back to the Topic

Answer

NETCONF in Network Automation is the model-driven management interface used to retrieve and edit YANG-modeled configuration and state over a capability-negotiated session.

Remember

  • NETCONF session established ≠ requested capability supported.
  • RPC <ok/> ≠ end-to-end network behavior correct.
  • Candidate edited ≠ running configuration changed until commit semantics complete.
  • YANG-valid configuration ≠ operationally safe configuration.

First checks

  • ssh -p 830 <user>@<dev> -s netconf — NETCONF subsystem
  • python3 -c 'import ncclient' — ncclient library
  • Capabilities exchange (hello) — supported models

Verify in this order

client → SSH 830 → hello/capabilities → RPCs

Where it usually breaks

NETCONF protocol success proves the management transaction boundary, not that modeled configuration is semantically correct or traffic works.

Input/desired state → request accepted → job/task terminal status → target object read-back → effective runtime state → original workload → regression/rollback readiness.

NETCONF Network Automation proof-boundary map

BoundaryHealthy evidenceSuspicious evidence
Intent / scopeSource revision and exact targets are explicitStale inventory, hidden selector or wrong variables change scope
Management operationTransport/model/payload and per-device response are traceableAuth/capability/parser differences hide partial or wrong execution
Device stateEffective and persistent state are read backAccepted config/API result is mistaken for convergence
Network proofOriginal control/data-plane or service test passesAutomation summary substitutes for actual network acceptance

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=5592

Confirmation

Confirm action

Continue?