Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Configuration Files Overview

You use configuration files to configure devices and to streamline device configuration tasks. A configuration file stores the complete configuration of a device. Keep in mind these distinctions between configuration files:

  • The active (running) configuration is the operational file of the device. These files control device behavior.

  • The candidate configuration is the working copy that stores configuration updates. These are the files that you use to automatic device configuration.

Configuration Files Overview

A configuration file stores the complete configuration of a network device. The current configuration of a device is called the active configuration. You can alter this current configuration, and you can also return to a previous configuration or to a rescue configuration.

The 50 most recently committed configuration files on a device are saved so that you can return to a previous configuration. The configuration files are named as follows:

  • juniper.conf.gz—The current active configuration

  • juniper.conf.1.gz to juniper.conf.49.gz—Rollback configurations

To make changes to the configuration file, you must use configuration mode in the CLI. When making changes to a configuration file, you are viewing and changing the candidate configuration file. The candidate configuration enables you to make configuration changes without causing operational changes to the active configuration or causing potential damage to your current network operations. After you commit the changes you made to the candidate configuration, the system updates the active configuration.

Configuration File Terms

Table 1: Configuration File Terms

Term

Definition

active configuration

Current committed configuration of a device.

candidate configuration

Working copy of the configuration that enables users to make configurational changes without causing any operational changes until this copy is committed.

configuration group

Group of configuration statements that the rest of the configuration can inherit.

commit a configuration

The act of checking a configuration for proper syntax, activating it, and marking as the current configuration file running on the device.

configuration hierarchy

A hierarchy of statements comprising the system configuration. The two types of statements are container and leaf: Container statements contain other statements. Leaf statements do not contain other statements. All the container and leaf statements together form the configuration hierarchy.

default configuration

The initial values set for each configuration parameter when a device is shipped.

rescue configuration

Well-known configuration that recovers a device from a configuration that denies management access. Through the CLI, you set a current committed configuration to be the rescue configuration.

roll back a configuration

The act of returning to a previously committed configuration.

Device Configuration Storage Overview

When you edit a Juniper Networks device configuration, you work in a copy of the current configuration to create a candidate configuration. The changes that you make to the candidate configuration are visible in the CLI immediately. Therefore, if multiple users are editing the configuration at the same time, all users can see all changes.

You commit your changes to cause a candidate configuration to take effect. At this point, the candidate file is checked for proper syntax, activated, and marked as the current, operational software configuration file. If multiple users are editing the configuration simultaneously, all changes made by all the users take effect when you commit the candidate configuration.

In addition to saving the current configuration, the CLI saves the current operational version and the previous 49 versions of committed configurations. The most recently committed configuration is version 0, which is the current operational version. This current operational version is the default configuration that the system returns to if you roll back to a previous configuration. The oldest saved configuration is version 49.

By default, the current configuration and three previous versions of the committed configuration are saved on the device CompactFlash card. The currently operational device configuration is stored in the file juniper.conf.gz, and the last three committed configurations are stored in the files juniper.conf.1.gz, juniper.conf.2.gz, and conf.3.gz. These four files are stored on the device’s CompactFlash card in the directory /config.

The remaining 46 previous versions of committed configurations, the files juniper.conf.4 through juniper.conf.49, are stored in the directory /var/db/config on the hard disk.