Tips and Tricks

Tips and Tricks

Configuring logging on Cisco devices

One of the best ways to understand why Cisco ASA or Cisco router are not passing traffic as needed and exactly what part of configuration is incorrect is to check the event log file. Problem is, the logging of events is turned off by default, and the command sh log will not give you meaningful output, unless you configure logging on your Cisco device.

In order to turn on logging of events, you have to execute the following commands

This configuration will allow you to capture all possible events occurring in the device's RAM, while limiting the log file to 128 Kbit. This should be sufficient for analyzing approximately the last 5 to 30 minutes of events, depending on how heavy is the traffic load on your device.

You can see the captured data with the command sh log

Read more →
Tips and Tricks

Cisco configuration modes

User mode >

As soon as you gain access to the device terminal, you enter user mode, which is indicated by a > prompt.

Privileges are barely enough to view the OS version and the device serial number (command sh ver).

Privileged mode #

For advanced configuration, you have to switch to a priviliged mode. Execute enable and type the password for this mode, if needed. On success, the prompt will change to #.

Here, you can execute commands to view current configuration (sh run) or poll device interfaces (sh ip inter brief for network switches and routers or sh inter ip brief for Cisco ASA).

Read more →
Tips and Tricks

Configuring SSH on Cisco IOS

Once you start working with Cisco routers, you may wonder how you set up a SSH connection to a router. Five easy steps to do it are below.
We'll take a Cisco 881 router. Steps to set up a connection to a different router (1841, 2800, 3825, etc.) or a switch (2900, 3500, 4800, etc.) are pretty much the same, though interface configuration can be a little different. (Setting up a SSH connection to Cisco ASA firewalls is described in the article "Cisco ASA basic Internet access")
So, we have on hand

The task is to configure a secure connection to the Cisco router via SSH and provide a means of secure remote control.

Step 0. Configuring an interface

The router should have one interface, the one that is going to be used for remote control, enabled. In our case, it'll be a LAN Fastethernet 0 interface.

Read more →
Tips and Tricks

Connecting to Cisco devices

In order to start working with Cisco equipment, you first need to configure it by connecting to its CLI through the console. Let us take a look at a situation in which you have an administrator workstation and console or rollover cables available somewhere close to the equipment that you want to configure.

1) Configuring Cisco equipment with the use of a console cable

In order to configure Cisco equipment through consoling into its' CLI, you need to use the blue cable that is shipped with each Cisco device. This cable has to be connected to the COM port of the administrator's workstation on one end, and the console port of the Cisco device on the other (the interface is marked with "CONSOLE" or "CON" lettering)

Modern PCs and laptops often don't have the COM port installed. In this case, you will have to purchase a USB to COM (RS232) adapter.
I recommend using the free and simple terminal emulator Putty in order to console into your equipment (Download from the official site). After downloading it, just run the program (it does not require installation) and change the default "SSH" connection type to "Serial" in the dialog box that opens (see the screenshot below). Click "Open" to start your console session.

Read more →