This document provides configuration commands and descriptions for a Cisco switch. It covers commands for enabling privileged EXEC mode, configuring interfaces, VLANs, IP settings, SSH, port security, QoS, and other switch settings. Example commands include enable, configure terminal, interface, switchport, ip, crypto key generate, and show commands for viewing configurations and status. The document is a comprehensive reference for switch configuration and management.
Copyright:
Attribution Non-Commercial (BY-NC)
Available Formats
Download as DOC, PDF, TXT or read online from Scribd
This document provides configuration commands and descriptions for a Cisco switch. It covers commands for enabling privileged EXEC mode, configuring interfaces, VLANs, IP settings, SSH, port security, QoS, and other switch settings. Example commands include enable, configure terminal, interface, switchport, ip, crypto key generate, and show commands for viewing configurations and status. The document is a comprehensive reference for switch configuration and management.
This document provides configuration commands and descriptions for a Cisco switch. It covers commands for enabling privileged EXEC mode, configuring interfaces, VLANs, IP settings, SSH, port security, QoS, and other switch settings. Example commands include enable, configure terminal, interface, switchport, ip, crypto key generate, and show commands for viewing configurations and status. The document is a comprehensive reference for switch configuration and management.
Copyright:
Attribution Non-Commercial (BY-NC)
Available Formats
Download as DOC, PDF, TXT or read online from Scribd
This document provides configuration commands and descriptions for a Cisco switch. It covers commands for enabling privileged EXEC mode, configuring interfaces, VLANs, IP settings, SSH, port security, QoS, and other switch settings. Example commands include enable, configure terminal, interface, switchport, ip, crypto key generate, and show commands for viewing configurations and status. The document is a comprehensive reference for switch configuration and management.
Copyright:
Attribution Non-Commercial (BY-NC)
Available Formats
Download as DOC, PDF, TXT or read online from Scribd
Download as doc, pdf, or txt
You are on page 1of 3
Command Syntax Description
Switch> enable Switch from user EXEC to privileged
EXEC mode Password:password Enter password Switch# # signifies privileged EXEC mode Switch#disable Switch from privileged EXEC to user EXEC mode Switch#configure terminal Switch from privileged EXEC mode to global configuration mode Switch(config)# (Config) signifies global configuration mode Switch(config)#interface fastethernet 0/1 Switch from global configuration mode to interface configuration mode for fast ethernet interface 0/1 Switch(config-if)# (config-if)# signifies interface configuration mode Switch#show history View recently entered EXEC commands Switch#terminal history Enable terminal history. This command can be run from either user or privileged EXEC mode Switch# terminal history size 50 Enable terminal history. This command can be run from either user or privileged EXEC mode Switch# terminal no history size Resets the terminal history size to the default value of 10 command lines Switch# terminal no history Disables terminal history S1(config)#interface vlan 99 Enter the interface configuration mode for the VLAN 99 interface S1(config-if)#ip address 172.17.99.11 Configure the interface IP address 255.255.255.0 S1(config-if)#no shutdown Enable the interface S1(config-if)#end Return to privileged EXEC mode S1(config-if)#switchport mode access Define the VLAN membership mode for the port S1(config-if)#switchport acces vlan 99 Assign the port to a VLAN S1#copy running-config startup-config Save the running configuration to the switch start-up configuration S1(config)#ip default-gateway Configures the default gateway on the 172.17.99.1 switch S1#show running-config S1#show ip interface brief Verify port operation and status S1(config-if)#duplex auto Configure the interface duplex mode to enable AUTO duplex configuration. S1(config-if)#speed auto Configure the interface duplex speed and enable AUTO speed configuration. S1(config)#ip http authentication enable Configure the HTTP server interface for the enable type of authentication. The other options are. enable - Enable password, which is the default method of HTTP server user authentication, is used. local - Local user database, as defined on the Cisco router or access server, is used. tacacs - TACACS server is used S1(config)#ip http server Enabled the HTTP server S1#show interfaces [interface-id] Displays interface status and configuration for a single or all interfaces available on the switch S1#show startup-config Displays contents of startup configuration S1#show running-config Displays current operating configuration S1#show flash: Displays information about flash: file system S1#show version Displays system hardware and software status S1#show history Display the session command history S1#show ip {interface | http | arp} Displays IP information. The interface option displays IP interface status and configuration. The http option displays HTTP information about device manager running on the switch. The arp option displays the IP ARP table S1#show mac-address-table Displays the MAC forwarding table S1#reload Have the Cisco IOS perform restart the switch. S1#erase nvram Erase configuration files stored in NVRAM S1(config)#line con 0 Switch from global configuration mode to line configuration mode for console 0 S1(config-line)#password cisco Set cisco as the password for the console 0 line on the switch S1(config-line)#login Set the console line to require the password to be entered before access is granted S1(config)#line vty 0 4 Switch from global configuration mode to line configuration mode for vty lines 0 - 4 S1(config)#enable password password Configures the enable password to enter privileged EXEC mode S1(config)#enable secret password Configures the enable secret password to enter privileged EXEC mode S1(config)# service password-encryption system passwords are stored in an encrypted form S1(config)#banner login "Authorized Configure a login banner Personnel Only!" S1(config)#banner motd "Device Configure a MOTD login banner maintenance will be occurring on Friday!" S1(config-line)#transport input telnet re-enable the Telnet protocol on a Cisco 2960 switch S1(config)#ip domain-name Configure a host domain for your switch mydomain.com S1(config)#crypto key generate rsa Enable the SSH server for local and remote authentication on the switch and generate an RSA key pair S1(config)#ip ssh version 2 Configure the switch to run SSHv1 or SSHv2 S1(config-line)#transport input SSH prevent non-SSH connections S1(config-if)#switchport port-security Enable port security on the interface S1(config-if)#switchport port-security Set the maximum number of secure maximum 50 addresses to 50 S1(config-if)#switchport port-security Enable sticky learning mac-address sticky S1(config-if)#mls qos trust qos ensures that voice traffic is identified as priority traffic S1(config-if)#switchport voice vlan 150 identifies VLAN 150 as the voice VLAN S1(config-if)#switchport mode trunk Define the F0/1 interface as an IEEE 802.1Q trunk S1(config-if)#switchport trunk native Configure the VLAN 99 to be the native vlan 99 VLAN S1(config)#vlan vlan id Create a VLAN. Vlan id is the VLAN number that is to be created. Switches to VLAN configuration mode for VLAN vlan id S1(config-vlan)#name vlan name Specify a unique VLAN name to identify the VLAN