upload configuration

upload configuration [hostname | ipaddress] filename {vr vr-name} {block-size block_size}

Description

Uploads the current configuration in ASCII format to a TFTP server on your network.

Syntax Description

hostname

Specifies the hostname of the TFTP server where you want to download the configuration file. You must have DNS enabled.

ipaddress

Specifies the IP address of the TFTP server where you want to download the configuration file.

filename

Specifies a user-defined name for the configuration file. You must use the .xsf file extension when naming an ASCII-formatted configuration file.

vr-name

Specifies the name of the virtual router. By default the switch uses VR-Mgmt for this command.

NOTE: User-created VRs are supported only on the platforms listed for this feature in the Switch Engine 32.2 Feature License Requirements document.

block_size Specifies the data block size, excluding TFTP header. Data block size ranges from 24-65000 bytes.

Default

Uploads the current configuration in ASCII format immediately to a TFTP server.

The default value of block-size is 1400 bytes.

Usage Guidelines

Specify the ipaddress or hostname parameters to upload the current, active configuration file from the switch to a TFTP server on the network. Use of the hostname parameter requires that DNS be enabled.

The uploaded ASCII file retains the CLI format. This allows you to do the following:
  • Modify the configuration using a text editor, and later download a copy of the file to the same switch or to one or more different switches.
  • Send a copy of the configuration file to Extreme Networks Technical Support for problem-solving purposes.

This command is not applicable to XML-based configurations. Those files use the .cfg file extension.

If you want to view your configuration in ASCII format, use the .xsf file extension (known as the XOS script file) when you save the configuration file on the switch. This saves the XML-based configuration in an ASCII format readable by a text editor.

If you successfully upload the active configuration to the network TFTP server, the switch displays a message similar to the following:

 Uploading meg_upload_config1.xsf to 10.10.10.10 ... done! 

If the switch displays a timeout error message similar to the following:

 failed! Error: timeout 

Make sure you entered the correct host name or IP address of the TFTP server

If the switch displays an unreachable network error similar to the following:

 failed! Error: Network is unreachable 

Make sure you entered the correct virtual router. By default the switch uses VR-Mgmt for this command.

Summary of Steps

The following summary only describes the CLI involved to transfer the configuration and load it on the switch; it is assumed that you know how to modify the configuration file with a text editor. As previously described, to use these commands, use the .xsf file extension. These steps are not applicable to configurations that use the .cfg file extension.

To work with an ASCII-formatted configuration file, complete the following tasks:

The following describes the steps in more detail.

Uploading the ASCII Configuration File To a TFTP Server

To upload the current switch configuration as an ASCII-based file to the TFTP server, use the upload configuration command and save the configuration with the .xsf file extension.

For example, to transfer the current switch configuration as an ASCII-based file named meg_upload_config1.xsf to the TFTP server with an IP address of 10.10.10.10, do the following:

upload configuration 10.10.10.10 meg_upload_config1.xsf

If you successfully upload the configuration to the TFTP server, the switch displays a message similar to the following:

Uploading meg_upload_config1.xsf to 10.10.10.10 ... done!

Downloading the ASCII Configuration File to the Switch

To download the configuration from the TFTP server to the switch, use the tftp command. For example, to retrieve the configuration file named meg-upload_config1.xsf from a TFTP server with an IP address of 10.10.10.10, you can use one of the following commands:

tftp 10.10.10.10 -g -r meg_upload_config1.xsf
tftp get 10.10.10.10 meg_upload_config1.xsf

If you successfully download the configuration to the switch, the switch displays a message similar to the following:

 Downloading meg_upload_config1.xsf to switch... done! 

Verifying that the ASCII Configuration File is on the Switch

To confirm that the ASCII configuration file is on the switch, use the ls command. The file with an .xsf extension is the ASCII configuration.

The following sample output contains an ASCII configuration file:

-rw-r--r--    1 root     0           98362 Nov  2 13:53 Nov022005.cfg
-rw-r--r--    1 root     0          117136 Dec 12 12:56 epicenter.cfg
-rw-r--r--    1 root     0              68 Oct 26 11:17 mcastgroup.pol
-rw-r--r--    1 root     0           21203 Dec 13 15:40 meg_upload_config1.xsf
-rw-r--r--    1 root     0          119521 Dec  6 14:35 primary.cfg
-rw-r--r--    1 root     0           96931 Nov 11 11:01 primary_11_11_05.cfg
-rw-r--r--    1 root     0           92692 Jul 19 16:42 secondary.cfg

Loading the ASCII Configuration File

After downloading the configuration file, you must load the new configuration on the switch. To load and restore the ASCII configuration file, use the load script filename {arg1} {arg2} ... {arg9} command. After issuing this command, the ASCII configuration quickly scrolls across the screen.

The following is an example of the type of information displayed when loading the ASCII configuration file:

script.meg_upload_config1.xsf.389 # enable snmp access
script.meg_upload_config1.xsf.390 # enable snmp traps
script.meg_upload_config1.xsf.391 # configure mstp region purple
script.meg_upload_config1.xsf.392 # configure mstp revision 3
script.meg_upload_config1.xsf.393 # configure mstp format 0
script.meg_upload_config1.xsf.394 # create stpd s0

Instead of entering each command individually, the script runs and loads the CLI on the switch.

Saving the Configuration

After you load the configuration, save it to the configuration database for use by the switch. This allows the switch to reapply the configuration after a switch reboot. To save the configuration, use the save configuration {primary | secondary | existing-config | new-config } command.

When you save the configuration file, the switch automatically adds the .cfg file extension to the filename. This saves the ASCII configuration as an XML-based configuration file.

You can use any name for the configuration. For example, after loading the file meg_upload_config1.xsf, you need to save it to the switch. To save the configuration as configuration1.cfg, do the following:

save configuration configuration1

Host Name and Remote IP Address Character Restrictions

This section provides information about the characters supported by the switch for host names and remote IP addresses.

When specifying a host name or remote IP address, the switch permits only the following characters:
  • Alphabetical letters, upper case and lower case (A-Z, a-z)
  • Numerals (0-9)
  • Period ( . )
  • Dash ( - ) Permitted only for host names
  • Underscore ( _ ) Permitted only for host names
  • Colon ( : )

When naming or configuring an IP address for your network server, remember the requirements listed above.

Remote Filename Character Restrictions

This section provides information about the characters supported by the switch for remote filenames.

When specifying a remote filename, the switch permits only the following characters:
  • Alphabetical letters, upper case and lower case (A-Z, a-z)
  • Numerals (0-9)
  • Period ( . )
  • Dash ( - )
  • Underscore ( _ )
  • Slash ( / ) Permitted only for remote files

When naming a remote file, remember the requirements previously described.

Example

The following command uploads the current switch configuration as an ASCII-based file named configbackup.xsf to the TFTP server with an IP address of 10.10.10.10:

upload configuration 10.10.10.10 configbackup.xsf

If you successfully upload the configuration to the TFTP server, the switch displays a message similar to the following:

Uploading configbackup.xsf to 10.10.10.10 ... done!

History

This command was first available in ExtremeXOS 11.4.

Block size support was added in ExtremeXOS 15.7.1.

Platform Availability

This command is available on ExtremeSwitching 5320, 5420, 5520, and 5720 series switches.