Courseiva
Junos OS FundamentalshardMultiple SelectObjective-mapped

Junos Commit and Rollback Operations: Understanding Commands and Examples

Which THREE of the following statements are true regarding Junos OS commit operations?

Quick Answer

The answer is that the 'commit confirmed' command automatically rolls back if not confirmed within the timeout. This is correct because Junos OS uses a two-phase commit model where a confirmed commit activates the candidate configuration for a specified period, typically 10 minutes by default, and if the administrator does not issue a 'commit' command to make it permanent, the system automatically reverts to the previous active configuration. On the JNCIA-Junos exam, this concept tests your understanding of safe configuration practices and the rollback mechanism, often appearing as a trap where candidates confuse 'commit check'—which only validates syntax without activation—with 'commit confirmed'. A common memory tip is to think of the confirmed commit as a "safety net": you jump with a timeout, and if you don't pull the ripcord (confirm), the net (rollback) catches you automatically.

⚠ Common exam trap

It's easy for candidates to confuse 'rollback' with reverting to the current active configuration, when in fact 'rollback 0' refers to the current active configuration, and any other number refers to a previous committed configuration.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

The 'commit check' command validates the candidate configuration without activating it.

The 'commit check' command validates the candidate configuration for syntax and semantic errors without activating it. This allows an administrator to verify changes before making them active, preventing potential misconfigurations from disrupting network operations.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • The 'commit check' command validates the candidate configuration without activating it.

    Why this is correct

    It checks syntax and semantics without applying.

  • The commit command activates the candidate configuration.

    Why this is correct

    This is the primary purpose of commit.

  • The 'commit confirmed' command automatically rolls back if not confirmed within the timeout.

    Why this is correct

    This is the behavior of commit confirmed.

  • You can run multiple commit scripts during a single commit operation.

    Why it's wrong here

    Only one commit script can be active at a time.

  • The rollback command reverts to the current active configuration.

    Why it's wrong here

    Rollback reverts to a previously committed configuration, not the current one.

About these practice questions

One of 156 original JN0-106 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Same concept, more angles

3 more ways this is tested on JN0-106

These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.

Variation 1. Which TWO statements correctly describe the function of the 'commit' command in Junos OS? (Choose two.)

easy
  • A.It validates the candidate configuration for syntax errors.
  • B.It schedules the configuration to be applied at a later time.
  • C.It discards the candidate configuration after saving.
  • D.It saves the candidate configuration to the active configuration.
  • E.It automatically reboots the device to apply the changes.

Why A: The 'commit' command in Junos OS first validates the candidate configuration for syntax errors before applying it. If syntax errors are found, the commit fails and the candidate configuration is not applied, ensuring the device does not enter an inconsistent state. This validation step is a core part of Junos's transactional configuration model, where changes are staged in a candidate configuration and then committed atomically.

Variation 2. A Junos device has multiple configuration files saved. Which command shows the available rollback configurations?

medium
  • A.show system configuration
  • B.show system rollback
  • C.show configuration | display rollback
  • D.show system commit

Why D: The 'show system commit' command displays a list of all committed configuration revisions, including their commit IDs and timestamps, which are used to roll back to a previous configuration. The rollback feature in Junos relies on these stored commit files, and the command explicitly shows the available rollback points.

Variation 3. A technician is troubleshooting a device that has an inconsistent configuration. They need to revert to the configuration that was committed exactly two commits ago. Which command sequence accomplishes this?

medium
  • A.rollback 2
  • B.rollback 2 followed by commit
  • C.commit confirmed 2
  • D.rollback 3

Why B: The `rollback 2` command reverts the candidate configuration to the state it was in two commits ago, but the change is not applied until a `commit` is issued. This two-step sequence (rollback followed by commit) is required to make the reverted configuration active. Without the commit, the device continues running the current active configuration.

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This JN0-106 practice question is part of Courseiva's free Juniper Networks certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the JN0-106 exam.