In order to configure a switch, here are some basic steps. In this configuration, there is no attempt to setup VLANS, or Routing Protocols, or Trunk links in this configuration.
Step [1]
First erase any configuration that is on the switch.
(switch)# write erase
Step [2]
You can reboot the switch using:
(switch)# reload
Step [3]
Now you may want to set the switch name with this command:
(switch)# Cisco-Catalyst-Switch
Step [4]
You can set the enable password to enter the switch:
(switch)# enable password MyEnablePassword
Step [5]
You can set the enable secret, an encrypted password:
(switch)# enable secret MyEnableSecretPassword
Step [6]
Set the console login password to control the console login
(switch)# line con 0
(switch)# password MySwitchConsolePassword
(switch)# logging synchronous
(switch)# login
Step [7]
Set the telnet login line, for remote switch administration
(switch)# line vty 0 4
(switch)# password TelnetLoginPassword
(switch)# login
Step [8]
Passwords can be hidden:
(switch)# service password-encryption
Step [9]
Save the switch configuration:
(switch)# write
Or
(switch)# copy run start
Step [10]
Set up the clock:
(switch)# clock set 12:00:00 Month Day Year
Step [11]
Set the default gateway:
(switch)# ip default-gateway x.x.x.x