Cisco IOS Commands - paulmac57/Network_Analyzer GitHub Wiki
The Test environment consists of 2 x Cisco Catalyst 2950 switches and 2 x Cisco 2600 Routers. They have been connected as shown in Figure 13.
The initial Configuration of the routers and switches require a Serial Telnet configuration in order to assign an IP Address to the Network port after which further configuration can be carried out via a Telnet or SSH connection. Therefore, the first programming requirement will be to open a serial port, connect to the router/switch and get the current device information (See Appendix E Flow Control 1).
An example of the Cisco commands required to do this are: -
Enable : - Moves User from user mode to privileged mode.
Show IP Interface Brief : - Provides list of Interfaces and summary configuration
The Show IP Interface brief command will return the relevant interfaces which can be displayed and configured. The text returned from this command will then be CLI scraped to offer the network engineer a choice of which interface to configure.
The user will then be able to make changes as required via the GUI interface. Once changes have been made the following commands will be sent to the network device (See Appendix E Flow Control 2): -
Configure Terminal : - Moves to Global Configuration mode.
Interface e0/0 : - Moves to interface Ethernet 0/0
IP add 192.168.2.254 255.255.255.0 : - Configure Interface with IP address and Mask
Do Copy Run Start : - Saves Configuration
Once the interface has been chosen the network engineer will be able to configure the IP address and then save the configuration. These commands will configure the switch/router sufficiently to allow further configuration to take place via a Telnet or SSH session.
If the network has already previously been setup, then the network engineer will be able to choose from the offset whether to connect via the serial or network port.
Once logged in further commands to interrogate the network infrastructure as a whole can then be sent such as: -
Show CDP Neighbors : - Investigates what devices are connected to the interfaces.
Show CDP Neighbors Detail : - Provides more detail about a remote device on the network.