The Backup Configuration File or log of the switch is useful for troubleshooting or if the device accidentally gets reset. This contains manual copies of files used for protection against system shutdown or for the maintenance of a specific operating state. For instance, you can copy and save the Mirror Configuration, Startup Configuration, or Running Configuration to a Backup file. You can use this file to update or restore the switch back to its functional state.
The Backup Configuration File can be saved on the Internal Flash memory or a USB device attached on your switch, a Trivial File Transfer Protocol (TFTP) server, a Secure Copy (SCP) server, or on your computer. This article will guide you on how to download or back up a system configuration file through the Command Line Interface (CLI) of the switch using any of the following methods:
Note: To learn how to download or back up configuration files on your Sx300 or Sx500 switch through the web-based utility, click here.
Step 1. Log in to the switch console. The default username and password is cisco/cisco. If you have configured a new username or password, enter the credentials instead.
Note: To learn how to access an SMB switch CLI through SSH or Telnet, click here.
Note: The commands may vary depending on the exact model of your switch. In this example, the SG300-28 switch is accessed through Telnet.
Step 2. To back up a configuration file to a specific destination, enter the following:
The parameters are:
- tftp:// — Source URL (tftp://ip-address/filename) for a file on a TFTP network server from which to download.
- scp:// — Source URL (scp://[username:password@]host/filename) for a file on an SCP server from which to download using SSH client. Before you proceed with the SCP method, make sure that SSH server authentication is enabled and the corresponding settings have been configured. For instructions on how to configure SSH authentication settings on your switch through the CLI, click here.
Guidelines:
Use the copy running-config dst-url command to copy the current configuration file to a network server such as TFTP or SCP.
Use the copy startup-config dst-url command to copy the startup configuration file to a network server.
TFTP:
Note: In this example, the running configuration file in plaintext form is saved to the TFTP server with IP address 192.168.100.139.
SCP:
Note: In this example, the running configuration file in plaintext form is saved to the SCP server with IP address 192.168.100.139 and credentials cisco and cisco12345 as the username and password, respectively.
You should now have successfully backed up the configuration files from your switch to a network server through the CLI.
Step 1. Log in to the switch console. The default username and password is cisco/cisco. If you have configured a new username or password, enter the credentials instead.
Note: The commands may vary depending on the exact model of your switch. In this example, the SG300-28 switch is accessed through Telnet.
Step 2. To copy a configuration file from a specific source, enter the following:
SG350X#copy [src-url] [running-config | startup-config]
The parameters are:
- tftp:// — Source URL (tftp://ip-address/filename) for a file on a TFTP network server from which to download.
- scp:// — Source URL (scp://[username:password@]host/filename) for a file on an SCP server from which to download using SSH client.
Guidelines:
TFTP:
Note: In this example, the backed up running configuration file named running-config.txt from a TFTP server with IP address 192.168.100.139 is downloaded as the startup configuration file of the switch.
SCP:
Note: In this example, the backed up running configuration file named config.txt from an SCP server with IP address 192.168.100.139 is downloaded as the startup configuration file of the switch. The credentials used are cisco and cisco12345 as the username and password.
Step 3. Press Y on your keyboard to overwrite the existing configuration file.
TFTP:
SCP:
You should now have successfully downloaded the configuration file into the switch through the CLI.
Revision | Publish Date | Comments |
---|---|---|
1.0 |
12-Dec-2018 |
Initial Release |