Kamis, 29 April 2010

Part II: Cisco IOS Tips and Tricks

Timestamping Messages

When the router displays log or debug messages, it defaults to showing you how long the router had been up when the event occurred. Many times, it is more helpful instead to know the date and time when the event occurred. The command for this is service timestamps [log | debug] datetime localtime in global configuration mode. If you use this mode of logging, you should set the clock and date as shown in the next section.

Example:
Router(config)#^Z
Router#
00:39:40: %SYS-5-CONFIG_I: Configured from console by console

Router(config)#service timestamps log datetime localtime
Router(config)#^Z
Mar 2 15:47:04: %SYS-5-CONFIG_I: Configured from console by console

Setting the Clock and Time Zone

You can set the clock on the router with the privileged mode command: clock set . When issuing this command, you must use the actual name of the month, not its number.
You may also want to set the time zone and daylight savings time adjustments. This is done in global configuration mode. The commands are: clock timezone , and clock summer-time recurring.

Example:

Router#clock set 3:42:00 2 MARCH 2004

Router#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#clock timezone EST –5
Router(config)#clock summer-time EDT recurring
Router#show clock
16:02:18.331 EST Tue Mar 2 2004

Displaying an Interface Config

Do you ever have times when all you want to see is the configuration for just one interface? But if you display the whole running configuration, you have to press the spacebar several times to get down to the one specific interface you want to see. Well, the “show run” command can be modified in several different ways (see later section). To quickly display only the configuration for a specific interface, use that interface designation as the modifier.

Example:
Router#show run interface s8
Building configuration...

Current configuration : 96 bytes

!
interface Serial8
bandwidth 115
ip address 10.0.0.9 255.255.255.252
clock rate 115200
end

Erasing an Interface Config


When you need to change the configuration of an interface, you typically have to remove the unwanted parts of the existing configuration line by line by putting a “no” in front of each line. If you have a lot of changes, or if you need to completely redo the configuration, it’s faster to just reset the interface to its original, default configuration. This removes all existing commands and shuts down the interface. Use the command default interface .

Example:
interface Serial1/0
no ip address
encapsulation frame-relay
clock rate 800000
frame-relay intf-type dce
frame-relay route 102 interface Serial2 201
frame-relay route 103 interface Serial3 301

Router(config)#default interface s1
Building configuration...

Interface Serial1 set to default configuration
*Feb 28 19:04:56: %LINK-3-UPDOWN: Interface Serial1, changed state
to down

Router#show run interface s1/0
interface Serial1
no ip address
end

Tidak ada komentar:

Posting Komentar

 
Home | Gallery | Tutorials | Freebies | About Us | Contact Us

Copyright © 2010 exam ccna |Designed by Templatemo |Converted to blogger by BloggerThemes.Net

Usage Rights

DesignBlog BloggerTheme comes under a Creative Commons License.This template is free of charge to create a personal blog.You can make changes to the templates to suit your needs.But You must keep the footer links Intact.