Pcornel
Browse topics
Options
Recent
Favorites
Automation · Technical reference

commit · NETCONF

Direct answer

commit is the NETCONF operation that applies the candidate datastore to running. Confirmed commit applies it with an automatic rollback unless confirmed within a timeout.

When to use this

Use this when applying candidate config with commit.

First 30 seconds

1. commit applies candidate to running.

2. Confirmed commit rolls back if not confirmed (protects against lockout).

3. Confirm after verification.

4. cancel-commit to abort.

5. Log commits.

Operational verification

candidate → commit confirmed → verify → confirm

Context & applicabilityCommon mistakes · platform/version boundaries
Platform / version applicability
NETCONF / YANG datastore automation
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.

PlatformNETCONF / YANG datastore automation · 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 applying candidate config with commit.
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

The negative fixture should deliberately exercise risks such as capability mismatch, namespace drift, wrong datastore, lock contention, partial edit semantics and assuming <ok/> shows final device behavior, choosing the cases most relevant to candidate-to-running commit semantics, confirmed-commit where supported, error handling and read-back from running after completion.

Step 2 Common mistakes Narrow the fault
  • Not using confirmed commit for risky changes.
Step 3 Where it fails Narrow the fault

Failure analysis for NETCONF → commit should follow the path through the components: client model → SSH/TLS transport → NETCONF RPC → datastore validation/lock → commit/apply → datastore read-back.

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
  • commit copies candidate to running.
  • Confirmed commit auto-reverts unless confirmed.
  • Confirm within the timeout.
Key checks
  • <commit> after candidate edits — apply
  • <commit confirmed timeout> then confirming commit — safety
  • <cancel-commit> — abort
ReferenceWhy it matters1 section · depth on demand

In depth

<commit> copies the candidate datastore to running, activating all staged changes at once. With <confirmed/>, the commit is temporary: unless a second commit confirms it within the timeout, the device rolls back automatically. That protects against changes that cut off management access.

m.commit(confirmed=True, timeout="300")   # active, auto-rollback in 5 min
if post_checks_ok(dev):
    m.commit()                             # make permanent
else:
    m.cancel_commit()                      # roll back now (if supported)

If the commit fails validation, nothing changes and the error explains which element is invalid. Discard the candidate (<discard-changes>) after a failed attempt so stale changes do not leak into the next commit.

ReferenceImportant terms & boundaries1 section · depth on demand
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 docNETCONF / YANG datastore automation current

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

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

Deep reference

Healthy vs suspicious evidence

Output interpretation

Capture at minimum device, session, message-id, datastore, module/revision, target path, rpc-error/error-tag/error-path, commit result and read-back values. For candidate-to-running commit semantics, confirmed-commit where supported, error handling and read-back from running after completion, prefer typed fields and stable IDs over human presentation text.

Confirmation

Confirm action

Continue?