Preparing the files for automatic configuration
The device can use a script file or configuration file for automatic configuration.
For devices to use configuration files for automatic configuration, you must edit and save the configuration files to the file server as described in "Configuration files." If you do not configure the DHCP server to assign configuration file names, you must also create a host name file on the TFTP server.
For devices to use script files for automatic configuration, you must edit and save the script files to the file server as described in "Script files."
Host name file
The host name file contains host name-IP address mappings and must be named network.cfg.
All mapping entries in the host name file must use the ip host host-name ip-address format. Each mapping entry must reside on a separate line. For example:
ip host host1 101.101.101.101 ip host host2 101.101.101.102 ip host client1 101.101.101.103 ip host client2 101.101.101.104
Configuration files
To prepare configuration files:
For devices that require different configurations, perform the following tasks:
Determine the name for each device's configuration file.
The configuration file names must use the extension .cfg. For simple file name identification, use configuration file names that do not contain spaces.
Use the file names to save the configuration files for the devices to the file server.
For devices that share all or some configurations, save the common configurations to a .cfg file on the file server.
If a TFTP file server is used, you can save a default configuration file named device.cfg on the server. This file contains only common configurations that the devices use to start up. This file is assigned to a device only when the device does not have other configuration files to use.
During the automatic configuration process, a device first tries to obtain a configuration file dedicated for it. If no dedicated configuration file is found, the device tries to obtain the common configuration file. If no common configuration file is found when a TFTP file server is used, the device obtains and uses the default configuration file.
Script files
Script files can be used for automatic software upgrade and automatic configuration. The device supports Python scripts (.py files) and Tcl scripts (.tcl files). For more information about Python and Tcl scripts, see "Using Python" and "Using Tcl."
To prepare script files:
For devices that share all or some configurations, edit a script file that contains the common configurations.
For the other devices, edit a separate script file for each of them.