Which command displays a message when the router is accessed

There are 5 fundamental Cisco commands that every Cisco network administrator should know. These are useful commands that can be implemented on a Cisco router to quickly gather important information and save changes. Consider adding these commands to your Cisco commands cheat sheet so you can reference them when you’re working on your Cisco router.

If you are new to Cisco networking, these are great commands to memorize. If you’re an experienced administrator, you may enjoy a refresher on a few of these commands.

We’ll start the list at #5 and move to #1.

IOS command #5: Show interfaces

It’s important to know what type of interfaces are on your router, important statistics about those interfaces and whether they are up or down. The show interfaces command is a very verbose command that provides a lot of output. You may have to pick through that output to find what you are looking for; just about everything to do with interfaces is shown in the output from this command, for example interface type, speed, IP address, and errors on the interface. This command can be used in both User EXEC and Privileged EXEC mode.

This command can be abbreviated as sh int.

IOS command #4: Copy running-config startup-config

Once you make changes to the router’s configuration, it’s important to remember to save those changes. This command copies the active running config in RAM that you have modified to the startup config in flash memory. By copying the configuration into flash, it  will be saved when the router is powered off and restarted. This command can only be used in Privileged EXEC mode.

A shortcut for this command is wr (which is short for write memory).

IOS command #3: Show IP route

Routers learn about networks, either statically or dynamically, and save the best path to those networks in their routing table. Once you know that your interfaces are up and you have saved your configuration, you want to verify that your router has convergence, which means that your router has accurate information about network reachability. The show IP route command displays every known connected and destination network, the method used to learn about these networks, the next-hop IP address and the local interface used to get to each known destination network. This command can be used in both User-EXEC and Privileged EXEC mode.

This command can be abbreviated sh ip ro.

IOS command #2: Show IP interface brief

We mentioned that the show interfaces command gives you a lot of useful information about all your router’s interfaces. Sometimes you want precise, specific information to answer the questions: Is the interface up? What are the IP addresses assigned to the interfaces? The show IP interface brief command gives you the answers to these questions and is the best summary of the status, protocol and IP addresses of your interfaces. This command can be used in both User EXEC and Privileged EXEC mode.

This command can be abbreviated sh ip int brie.

And the #1 most important command that every Cisco network administrator should know is...

IOS command #1: Show running-config

Probably the most useful of all the Cisco show commands is show running-config. With this command, you get to see the router's entire active configuration. Every command you have typed. Every default command applied. All this great information is available with a single IOS command. It’s that simple. You get to see the IP addresses, interfaces, passwords (that are in clear text), routing protocols and other settings. This command can only be used in Privileged EXEC mode.

This command can be abbreviated sh run or wr t.

Summary

Using the Cisco IOS is all about knowing what command to type to access the information you need and make the changes you need to make. The 5 Cisco router commands shown in this article are just a few of the thousands of possible Cisco IOS commands, however, this Cisco commands list contains some of the most useful commands that every Cisco network administrator should know.

Configure Banner in Cisco devices

A banner is a message presented to a user who is using the Cisco switch. Based on the type of banner you configured for use, the message will be shown to users of Cisco switch. Cisco IOS routers support a number of banners, such as:

  • MOTD banner: When users connect to the router, the "Message Of The Day (MOTD)" banner is presented.
  • Login banner: The login banner is displayed right before the authentication prompt.
  • Exec banner: The Exec banner appears before the user sees the exec prompt.
  • Incoming banner: These banners are displayed for users who connect through reverse telnet.

This article is about how to configure banner on multiple Cisco devices simultaneously in Network Configuration Manager application using configlets. If you don't have NCM installed, please click here to download and install the application.

Steps to configure banner through CLI.

  1. Login to the device using SSH / TELNET and go to enable mode.

  2. Go into the config mode.
    Router#configure terminal
    Enter configuration commands, one per line. End with CNTL/Z.
    Router(config)#

  3. Use below command to configure banner for required banner types (motd / login / exec)
    Router(config)#banner motd #Unauthorized access to this device is prohibited!#

  4. Exit config mode
    Router(config)#exit
    Router#

  5. Copy the running configuration into startup configuration using the below command
    Router#write memory
    Building configuration... [OK]
    Router#

Corresponding configlet can be created in NCM application as shown in below screenshot. 

Which command displays a message when the router is accessed

Also you can click the below button to download the Configlet as XML and import it into NCM application using file import option.

Configlet NameConfigure Banner Cisco
Description This configlet is used to configure banner on cisco devices with required banner types.
Execution Mode Advanced script execution mode
Configlet Content

<command>config t</command>
<command prompt='$NO_RESPONSE' timeout='5'>banner
$BANNER_TYPE $DELIMITING_CHAR</command>
<command prompt='$NO_RESPONSE' timeout='5'>$BANNER_LINE_1</command>
<command prompt='$NO_RESPONSE' timeout='5'>$BANNER_LINE_2</command>
<command prompt='$NO_RESPONSE' timeout='5'>$BANNER_LINE_3</command>
<command>$DELIMITING_CHAR</command>
<command>exit</command>
<command>write memory</command>

What command displays the contents of the routing table?

You can display the routing table's contents with the netstat -nr command. The -r option tells netstat to display the routing table, and the -n option tells netstat to display the table in numeric form.

What is the command is used to display the interfaces of the routers?

Use the show interfaces EXEC command to display statistics for all interfaces configured on the router or access server.

Which command is used for router?

The following commands are used to gather information on a Cisco IOS Software-based router when attempting to learn basic information about a router, or possibly troubleshooting protocol-independent problems: show version. show running-config. ... .