Very Basic Cisco Router or switch Configuration Commands


How to Configure a Router Hostname

To configure a name for router, use hostname command from Global Configuration mode.

Router>enable
Router#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname f5skills.com.R1
f5skills.com.R1(config)#exit
f5skills.com.R1#

How to Configure a MOTD Banner for Router

Users will be presented with a MOTD (Message of the DAY) banner every time they attempt a connection via the console port, auxiliary port, or a telnet session to router. Use the following commands to configure a MOTD message. Here the “#” character is known as a delimiting character. The banner message should be sorrounded by delimiting character and the message should not contain the delimiting character.

f5skills.com.R1>enable
f5skills.com.R1#configure terminal
f5skills.com.R1(config)#banner motd #
***************************************************************
                     PROPERTY OF F5SKILLS.COM
        Access is restricted to authorized users only.
Unauthorized access is a violation of state and federal,
civil and criminal laws.

***************************************************************

#
f5skills.com.R1(config)#exit
f5skills.com.R1#

How to enable DNS lookup

To configure a DNS server for your router, follow these steps.

f5skills.com.R1>enable
f5skills.com.R1#configure terminal
f5skills.com.R1(config)#ip name-server 10.100.156.10
f5skills.com.R1(config)#exit
f5skills.com.R1#

How to turn off the automatic name resolution
The router is set by default to try to resolve any word that is not a command to a DNS server at address limited broadcast IP Address 255.255.255.255. We can turn off this by using the following command.

f5skills.com.R1>enable
f5skills.com.R1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
f5skills.com.R1(config)#no ip domain-lookup
f5skills.com.R1(config)#exit
f5skills.com.R1#

How to assign a Local Name to an IP address

Following command assigns a host name to an IP address. Once this is completed, we can use the configured host name for telnet or ping.

f5skills.com.R1>enable
f5skills.com.R1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
f5skills.com.R1(config)#ip host PC1 10.100.156.10
f5skills.com.R1(config)#exit
f5skills.com.R1#

How to Turn on synchronous logging

If the router sends a message to the console while you’re entering a command, by default the router will interrupt your work to show the message.

If you want the information sent to console not interrupt the command you are typing, turn on synchronous logging.

f5skills.com.R1>enable
f5skills.com.R1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
f5skills.com.R1(config)#line console 0
f5skills.com.R1(config-line)#logging synchronous
f5skills.com.R1(config-line)#exit
f5skills.com.R1(config)#exit
f5skills.com.R1#

How to configure an inactivity time-out for automatic log-off

Sets time limit when console automatically logs off. Set to 0 0 (minutes seconds) means console never logs off.

f5skills.com.R1>enable
f5skills.com.R1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
f5skills.com.R1(config)#line console 0
f5skills.com.R1(config-line)#exec-timeout 3 0
f5skills.com.R1(config-line)#exit
f5skills.com.R1(config)#exit
f5skills.com.R1#

5 thoughts on “Very Basic Cisco Router or switch Configuration Commands

  • December 4, 2018 at 06:07
    Permalink

    The core of your writing whilst sounding agreeable in the beginning, did not really work well with me personally after some time. Someplace within the sentences you were able to make me a believer but just for a very short while. I however have got a problem with your leaps in logic and you would do well to help fill in those breaks. When you actually can accomplish that, I will definitely be amazed.

    Reply
  • December 6, 2018 at 04:50
    Permalink

    Thanks in favor of sharing such a nice thought,
    post is fastidious, thats why i have read it completely

    Reply
  • December 10, 2018 at 00:08
    Permalink

    It’s going to be ending of mine day, but before ending I am reading this impressive piece of writing to increase my experience.

    Reply
  • January 4, 2019 at 05:28
    Permalink

    Superb site you have here but I was wanting to know if you knew of any message boards that cover the same topics discussed in this article?
    I’d really love to be a part of community where I can get opinions from other knowledgeable individuals that
    share the same interest. If you have any suggestions, please
    let me know. Many thanks!

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *