- Index
- Using the Command-Line Interface
- Preface
- Catalyst 3750-X and 3560-X Switch Cisco IOS Commands - aaa accounting through reserved-only
- Catalyst 3750-X and 3560-X Switch Cisco IOS Commands - rmon collection through show vtp
- Catalyst 3750-X and 3560-X Switch Cisco IOS Commands - shutdown through vtp
- Catalyst 3750-X and 3560-X Switch Bootloader Commands
- Catalyst 3750-X and 3560-X Switch Debug Commands
- Catalyst 3750-X and 3560-X Switch Show Platform Commands
- Acknowledgments for Open-Source Software
Catalyst 3750-X and 3560-X Switch Boot Loader Commands
This appendix describes the boot loader commands on the Catalyst 3750-X and 3560-X switch. Unless otherwise noted, the term switch refers to a standalone switch and to a switch stack.
During normal boot loader operation, you are not presented with the boot loader command-line prompt. You gain access to the boot loader command line if the switch is set to manually boot, if an error occurs during power-on self test (POST) DRAM testing, or if an error occurs while loading the operating system (a corrupted Cisco IOS image). You can also access the boot loader if you have lost or forgotten the switch password.
Note The default switch configuration allows an end user with physical access to the switch to recover from a lost password by interrupting the boot process while the switch is powering up and then entering a new password. The password recovery disable feature allows the system administrator to protect access to the switch password by disabling part of this functionality and allowing the user to interrupt the boot process only by agreeing to set the system back to the default configuration. With password recovery disabled, the user can still interrupt the boot process and change the password, but the configuration file (config.text) and the VLAN database file (vlan.dat) are deleted. For more information, see the software configuration guide for this release.
You can access the boot loader through a switch console connection at 9600 b/s. Unplug the switch power cord, and press the switch Mode button while reconnecting the power cord. You can release the Mode button a second or two after the LED above port 1X goes off. You should then see the boot loader Switch: prompt. The boot loader performs low-level CPU initialization, performs POST, and loads a default operating system image into memory.
arp
Use the arp boot loader command to display the contents the Address Resolution Protocol (ARP) table.
Syntax Description
(Optional) Show the ARP table or the mapping for a specific IP address. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Examples
This example shows how to display the ARP table:
boot
Use the boot boot loader command to load and boot an executable image and to enter the command-line interface.
boot [ -post | -n | -p | flag ] filesystem:/file-url...
Syntax Description
Defaults
The switch attempts to automatically boot the system by using information in the BOOT environment variable. If this variable is not set, the switch attempts to load and execute the first executable image it can by performing a recursive, depth-first search throughout the flash file system. In a depth-first search of a directory, each encountered subdirectory is completely searched before continuing the search in the original directory.
Command Modes
Command History
|
|
---|---|
Usage Guidelines
When you enter the boot command without any arguments, the switch attempts to automatically boot the system by using the information in the BOOT environment variable, if any. If you supply an image name for the file-url variable, the boot command attempts to boot the specified image.
When you set boot loader boot command options, they are executed immediately and apply only to the current boot loader session. These settings are not saved for the next boot operation.
Examples
This example shows how to boot the switch using the new-image.bin image:
switch:
boot flash:/new-images/new-image.bin
After entering this command, you are prompted to start the setup program.
Related Commands
|
|
---|---|
Sets the BOOT environment variable to boot a specific image when the BOOT keyword is appended to the command. |
cat
Use the cat boot loader command to display the contents of one or more files.
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
|
Path (directory) and name of the files to display. Separate each filename with a space. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Filenames and directory names are case sensitive.
If you specify a list of files, the contents of each file appears sequentially.
Examples
This example shows how to display the contents of an image file. An example of an image file is c3750e-universal-mz.122-53.SE2:
info_end:
Related Commands
|
|
---|---|
copy
Use the copy boot loader command to copy a file from a source to a destination.
copy [ -b block-size ] filesystem :/ source-file-url filesystem :/ destination-file-url
Syntax Description
(Optional) This option is used only for internal development and testing. |
|
Alias for a flash file system. Use flash: for the system board flash device. |
|
Defaults
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Filenames and directory names are case sensitive.
Directory names are limited to 45 characters between the slashes (/); the name cannot contain control characters, spaces, deletes, slashes, quotes, semicolons, or colons.
Filenames are limited to 45 characters; the name cannot contain control characters, spaces, deletes, slashes, quotes, semicolons, or colons.
If you are copying a file to a new directory, the directory must already exist.
Examples
This example show how to copy a file at the root:
You can verify that the file was copied by entering the dir filesystem : boot loader command.
Related Commands
|
|
---|---|
delete
Use the delete boot loader command to delete one or more files from the specified file system.
delete filesystem :/ file-url...
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
|
Path (directory) and filename to delete. Separate each filename with a space. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Filenames and directory names are case sensitive.
The switch prompts you for confirmation before deleting each file.
Examples
This example shows how to delete two files:
You can verify that the files were deleted by entering the dir flash: boot loader command.
Related Commands
|
|
---|---|
dir
Use the dir boot loader command to display a list of files and directories on the specified file system.
Syntax Description
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Examples
This example shows how to display the files in flash memory:
Table A-1 describes the fields in the display.
|
|
---|---|
Related Commands
|
|
---|---|
flash_init
Use the flash_init boot loader command to initialize the flash file system.
Syntax Description
Defaults
The flash file system is automatically initialized during normal system operation.
Command Modes
Command History
|
|
---|---|
Usage Guidelines
During the normal boot process, the flash file system is automatically initialized.
Use this command to manually initialize the flash file system. For example, you use this command during the recovery procedure for a lost or forgotten password.
format
Use the format boot loader command to format the specified file system and destroy all data in that file system.
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
fsck
Use the fsck boot loader command to check the file system for consistency.
fsck [ -test | -f ] filesystem :
Syntax Description
Defaults
Command Modes
Command History
|
|
---|---|
Usage Guidelines
To stop an in-progress file system consistency check, disconnect the switch power and then reconnect the power.
Examples
This example shows how to perform an extensive file system check on flash memory:
help
Use the help boot loader command to display the available commands.
Syntax Description
Command Modes
Command History
|
|
---|---|
Usage Guidelines
You can also use the question mark (?) to display a list of available boot loader commands.
memory
Use the memory boot loader command to display memory heap utilization information.
Syntax Description
Command Modes
Command History
|
|
---|---|
Examples
This example shows how to display memory heap utilization information:
Table A-2 describes the fields in the display.
mgmt_clr
Use the mgmt_clr boot loader command to clear the Ethernet management port statistics.
Syntax Description
Command Modes
Command History
|
|
---|---|
Examples
This example shows how to clear the Ethernet management port statistics:
switch:
mgmt_clr
mgmt_init
Use the mgmt_init boot loader command to initialize the Ethernet management port.
Syntax Description
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Use the mgmt_init command only during debugging of the Ethernet management port.
Examples
This example shows how to initialize the Ethernet management port:
switch:
mgmt_init
mgmt_show
Use the mgmt_show boot loader command to display the Ethernet management port statistics.
Syntax Description
Command Modes
Command History
|
|
---|---|
Examples
This example shows how to display the Ethernet management port statistics:
mkdir
Use the mkdir boot loader command to create one or more new directories on the specified file system.
mkdir filesystem :/ directory-url...
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
|
Name of the directories to create. Separate each directory name with a space. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Directory names are case sensitive.
Directory names are limited to 45 characters between the slashes (/); the name cannot contain control characters, spaces, deletes, slashes, quotes, semicolons, or colons.
Examples
This example shows how to make a directory called Saved_Configs:
This example shows how to make two directories:
You can verify that the directory was created by entering the dir filesystem : boot loader command.
Related Commands
|
|
---|---|
Displays a list of files and directories on the specified file system. |
|
Removes one or more directories from the specified file system. |
more
Use the more boot loader command to display the contents of one or more files.
more filesystem :/ file-url...
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
|
Path (directory) and name of the files to display. Separate each filename with a space. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Filenames and directory names are case sensitive.
If you specify a list of files, the contents of each file appears sequentially.
Examples
This example shows how to display the contents of a file. An example of an image file is c3750e-universal-mz.122-53.SE2:
info_end:
Related Commands
|
|
---|---|
rename
Use the rename boot loader command to rename a file.
rename filesystem :/ source-file-url filesystem :/ destination-file-url
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
|
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Filenames and directory names are case sensitive.
Directory names are limited to 45 characters between the slashes (/); the name cannot contain control characters, spaces, deletes, slashes, quotes, semicolons, or colons.
Filenames are limited to 45 characters; the name cannot contain control characters, spaces, deletes, slashes, quotes, semicolons, or colons.
Examples
This example shows a file named config.text being renamed to config1.text :
You can verify that the file was renamed by entering the dir filesystem : boot loader command.
Related Commands
|
|
---|---|
reset
Use the reset boot loader command to perform a hard reset on the system. A hard reset is similar to power-cycling the switch, clearing the processor, registers, and memory.
Syntax Description
Command Modes
Command History
|
|
---|---|
Examples
This example shows how to reset the system:
Related Commands
|
|
---|---|
Loads and boots an executable image and enters the command-line interface. |
rmdir
Use the rmdir boot loader command to remove one or more empty directories from the specified file system.
rmdir filesystem :/ directory-url...
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
|
Path (directory) and name of the empty directories to remove. Separate each directory name with a space. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Directory names are case sensitive and limited to 45 characters between the slashes (/); the name cannot contain control characters, spaces, deletes, slashes, quotes, semicolons, or colons.
Before removing a directory, you must first delete all the files in the directory.
The switch prompts you for confirmation before deleting each directory.
Examples
This example shows how to remove a directory:
You can verify that the directory was deleted by entering the dir filesystem : boot loader command.
Related Commands
|
|
---|---|
Displays a list of files and directories on the specified file system. |
|
Creates one or more new directories on the specified file system. |
set
Use the set boot loader command to set or display environment variables, which can be used to control the boot loader or any other software running on the switch.
Syntax Description
Defaults
The environment variables have these default values:
ENABLE_BREAK: No (Off or 0) (the automatic boot process cannot be interrupted by pressing the Break key on the console).
HELPER: No default value (helper files are not automatically loaded).
HELPER_CONFIG_FILE: No default value (no helper configuration file is specified).
Note Environment variables that have values are stored in the flash file system in various files. The format of these files is that each line contains an environment variable name and an equal sign followed by the value of the variable. A variable has no value if it is not listed in this file; it has a value if it is listed in the file even if the value is a null string. A variable that is set to a null string (for example, “ ”) is a variable with a value. Many environment variables are predefined and have default values.
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Environment variables are case sensitive and must be entered as documented.
Environment variables that have values are stored in flash memory outside of the flash file system.
Under normal circumstances, it is not necessary to alter the setting of the environment variables.
The MANUAL_BOOT environment variable can also be set by using the boot manual global configuration command.
The BOOT environment variable can also be set by using the boot system filesystem :/ file-url global configuration command.
The ENABLE_BREAK environment variable can also be set by using the boot enable-break global configuration command.
The HELPER environment variable can also be set by using the boot helper filesystem :/ file-url global configuration command.
The CONFIG_FILE environment variable can also be set by using the boot config-file flash:/ file-url global configuration command.
The HELPER_CONFIG_FILE environment variable can also be set by using the boot helper-config-file filesystem :/ file-url global configuration command.
For Catalyst 3750-X switches, the SWITCH_NUMBER environment variable can also be set by using the switch current-stack-member-number renumber new-stack-member-number global configuration command.
For Catalyst 3560-X switches, the SWITCH_PRIORITY environment variable can also be set by using the switch stack-member-number priority priority-number global configuration command.
The boot loader prompt string (PS1) can be up to 120 printable characters except the equal sign (=).
Examples
This example shows how to change the boot loader prompt:
You can verify your setting by using the set boot loader command.
Related Commands
|
|
---|---|
Resets one or more environment variables to its previous setting. |
type
Use the type boot loader command to display the contents of one or more files.
type filesystem :/ file-url...
Syntax Description
Alias for a flash file system. Use flash: for the system board flash device. |
|
Path (directory) and name of the files to display. Separate each filename with a space. |
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Filenames and directory names are case sensitive.
If you specify a list of files, the contents of each file appears sequentially.
Examples
This example shows how to display the contents of a file. An example of an image file is c3750e-universal-mz.122-53.SE2:
info_end:
Related Commands
|
|
---|---|
unset
Use the unset boot loader command to reset one or more environment variables.
Syntax Description
Command Modes
Command History
|
|
---|---|
Usage Guidelines
Under normal circumstances, it is not necessary to alter the setting of the environment variables.
The MANUAL_BOOT environment variable can also be reset by using the no boot manual global configuration command.
The BOOT environment variable can also be reset by using the no boot system global configuration command.
The ENABLE_BREAK environment variable can also be reset by using the no boot enable-break global configuration command.
The HELPER environment variable can also be reset by using the no boot helper global configuration command.
The CONFIG_FILE environment variable can also be reset by using the no boot config-file global configuration command.
The HELPER_CONFIG_FILE environment variable can also be reset by using the no boot helper-config-file global configuration command.
Examples
This example shows how to reset the prompt string to its previous setting:
Related Commands
|
|
---|---|
version
Use the version boot loader command to display the boot loader version.
Syntax Description
Command Modes
Command History
|
|
---|---|
Examples
This example shows how to display the boot loader version on a switch: