Vyatta Network OS Documentation

Learn how to install, configure and operate the Vyatta NOS, which helps drive our virtual networking & physical platforms portfolio.

commit-confirm <minutes>

Commits and saves the configuration as specified with the commit command. The commit-confirm command rolls back the configuration to the last saved configuration if a confirmation is not provided within the given timeout period.

commit-confirm minutes [ comment comment ]
minutes
The time, in minutes, to wait for the confirmation to be provided.
comment comment
Specifies a comment to appear in the revision history for the configuration file. The format is a character string enclosed in double quotation marks.

Configuration mode

Use this command to set the system to require confirmation of a configuration commit.

This operation is useful when making configuration changes over a remote connection that could cause you to be unable to reconnect to the system, for example, accidentally changing the IP address of the management port.

A reboot during the commit-confirm timeout window results in the restoration of the previous configuration.

After making a configuration change, enter the commit-confirm command, specifying the confirmation interval. Commit the change. If the commit is completed, without incident, confirm the commit by entering the command confirm. If you do not confirm, the changes are rolled back.

If the new commit-confirmed configuration causes a crash before the confirmation window expires, the system reboots and rolls back to avoid an endless cycle of rebooting.

If you attempt to use the GRUB configuration recovery option when rebooting during the commit-confirm timeout window is active, a message to wait for the rollback to be completed is displayed.

If you enter commit, commit-confirm, or rollback commands during the commit-confirm timeout, the current commit that is pending confirmation is implicitly confirmed. For example, rollback 1 takes you back to the immediately preceding commit (before the original commit-confirm), and rollback 0 recommits the current configuration.

The following example shows how to save commit-confirm changes.

vyatta@R1# set interfaces loopback lo description "updated description"
[edit]
vyatta@R1# commit-confirm 2 comment "Updated loopback interface description"

commit will rollback to previous version in 2 minutes unless you enter 'confirm'

If you enter confirm within the timeout period of 2 minutes, the system configuration corresponds to the following configuration:

vyatta@R1# run show system commit
0   2017-01-06 10:20:14 by Vyatta
    Updated loopback interface description
1   2017-01-06 09:50:15 by Vyatta
    Change loopback interface address
2   2017-01-06 09:48:45 by Vyatta
    Set loopback interface address
3   2017-01-06 09:48:20 by Vyatta
    Update loopback interface description
...

If you do not enter confirm within the timeout period of 2 minutes, the system configuration rolls back to the previous version as illustrated here:

vyatta@R1# run show system commit
0   2017-01-06 10:22:15 by configd
    Rollback to previous version.
1   2017-01-06 10:20:14 by Vyatta
    Updated loopback interface description
2   2017-01-06 09:50:15 by Vyatta
    Change loopback interface address
3   2017-01-06 09:48:45 by Vyatta
    Set loopback interface address
4   2017-01-06 09:48:20 by Vyatta
    Update loopback interface description