Cheatography
https://cheatography.com
This is a Cisco IOS CLI Cheat Sheet for Cisco CCNA 1
Basic Device Configuration
Enter Privieleged Exec mode |
Switch> enable |
Leave Privieleged Exec mode |
Switch# disable |
Enter Global Configuration mode |
Switch# configure terminal |
Configuring a Device Name (Hostname) |
Switch(config)# hostname NAME |
Configuring a Console Port (Console) |
Switch(config)# line console 0 |
Configuring a Console Password (Console) |
Switch(config-line)# password PASSWORD |
Activating password checking on the Console Port |
Switch(config-line)# login |
Activating Username/Password checking on the Console Port |
Switch(config-line)# login local |
Creating a timeout on the Console Port |
Switch(config-line)# exec-timeout MINUTES SECONDS |
Backup one level |
Switch(config-line)# exit |
Backup one level |
Switch(config)# exit |
Backup all levels |
Switch# CTRL + Z or CTRL + C |
The Show Commands to Know!
Shows information about the switch and its interfaces, RAM, NVRAM, flash, IOS, etc |
Switch# show version |
Shows the current configuration file stored in DRAM. |
Switch# show running-config |
Shows the configuration file stored in NVRAM which is used when the device boots. |
Switch# show startup-config |
Shows an overview of all interfaces, their physical status, protocol status and ip address if assigned. |
Switch# show ip interface brief |
Shows any Descriptions you've configured on your individual interfaces. |
Switch# show interfaces description |
Shows the status of all interfaces like connected or not, speed, duplex, trunk or access VLAN. |
Switch# show interfaces status |
Awesome Shortcuts
Create shortcuts for long commands |
Router(config)# alias exec SHIP show ip interface brief |
Configure a Banner Message that shows "everywhere" |
Router(config)# banner motd $ THIS IS MY MESSAGE $ |
Encrypt all plain-text passwords stored on the devic |
Router(config)# service password-encryption |
Stop those "pop-up" messages from cutting through your CLI |
Router(config)# logging synchronous |
Save your configuration |
Router# wr or write or copy run star |
Some Fun "Studies"
LearnCisco (Configuring a Cisco Router) |
|
Lock down your Cisco Router (from the NSA?) |
|
|
|
Configuring a Switch Management Interface
Access a specific switch VLAN interface SVI (common VLAN 1) |
Switch(config)# interface VLAN # |
Configure a reachable IP address and Subnet Mask |
Switch(config-if )# ip address ADDRESS MASK |
Activate the Switch management interface |
Switch(config-if )# no shut |
Exit the switch VLAN interface (SVI) |
Switch(config-if )# exit |
Configure a default gateway for the switch to send upstream traffic out of the local LAN |
Switch(config)# ip default-gateway IP-ADDRESS-OF-UPSTREAM-ROUTER |
Configuring a Router Network Interface
Locate your Router interfaces (learn their designations) |
Router# show ip interface brief |
Access Global Configuration mode |
Router# configure terminal |
Access a specific Router interface |
Router(config)# interface gi0/0/0 |
Configure a reachable IP address and Subnet Mask |
Router(config-if)# ip address ADDRESS MASK |
Activate the Router interface |
Router(config-if )# no shut |
Configuring SSH for Remote Management
Configure the device hostname |
Switch(config)# hostname NAME |
Configure the Doman Name the device will operate on |
Switch(config)# ip domain-name EXAMPLE.COM |
Configure a username and password for remote management |
Switch(config)# username admin password cisco |
Generate encryption keys to "obfuscate" the management traffic |
Switch(config)# crypto key generate rsa |
Configure a minimum of 1024 bits for encryption security |
How many bits in the modulus [512]: 1024 |
Define the SSH version to use (older versions have exploits/vulnerabilities) |
Switch(config)# ip ssh version 2 |
Access the VTY lines (used for Telnet and SSH) |
Switch(config)# line vty 0 4 |
Activate SSH on the VTY lines |
Switch(config-line)# transport input ssh |
Require a username and password combo |
Switch(config-line)# login local |
Save your configuration |
Switch# wr |
|
Created By
Metadata
Comments
No comments yet. Add yours below!
Add a Comment
Related Cheat Sheets