Pcornel
Automation

NETCONF

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

Back to the Topic

Answer

NETCONF and RESTCONF expose YANG-modeled configuration and operational data through structured, machine-oriented interfaces.

Remember

  • NETCONF commonly uses SSH/TCP 830 and XML RPCs
  • RESTCONF uses HTTPS, HTTP methods and JSON/XML representations
  • Capability/model discovery precedes path or payload construction
  • Running, candidate and startup semantics depend on server capabilities
  • Transport success does not prove authorization, valid YANG paths or transaction success.

First checks

  • python3 -c 'from ncclient import manager' — library
  • ssh -p 830 <u>@<dev> -s netconf — subsystem
  • Device capabilities list — features

Commands

netconf-yang
Enable NETCONF over SSH (port 830) with YANG models.
show netconf-yang sessions
Display active NETCONF sessions.

Verify in this order

client → SSH 830 → hello → RPCs → datastores

Where it usually breaks

HTTP 200 or NETCONF session-up does not prove the intended datastore mutation or operational effect.

Automation/controller success is not target-state proof; target config/state is not effective-runtime proof; effective state is not workload proof.

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

Confirmation

Confirm action

Continue?