Monday, September 15, 2008

Configuring Cisco router interfaces&Global Configuration (Config)

Global Configuration (Config)

(Friday, February 15, 2008)

To configure any feature of the router, you must enter configuration mode. This is the first sub-mode of the parent mode. In the parent mode, you issue the command config.

Router#config
Router(config)#

As demonstrated above, the prompt changes to indicate the mode that you are now in.

In connfiguration mode you can set options that apply system-wide, also refered to as "global configurations." For instance, it is a good idea to name your router so that you can easily identify it. You do this in configuration mode with the hostname command.

Router(config)#hostname ExampleName
ExampleName(config)#

As demonstrated above, when you set the name of the host with the hostname command, the prompt immediately changes by replacing Router with ExampleName. (Note: It is a good idea to name your routers with an organized naming scheme.)

Another useful command issued from config mode is the command to designate the DNS server to be used by the router:

ExampleName(config)#ip name-server aa.bb.cc.dd
ExampleName(config)#ctrl-Z
ExampleName#

This is also where you set the password for privileged mode.

ExampleName(config)#enable secret examplepassword
ExampleName(config)#ctrl-Z
ExampleName#

Until you hit ctrl-Z (or type exit until you reach parent mode) your command has not been put into affect. You can enter config mode, issue several different commands, then hit ctrl-Z to activate them all. Each time you hit ctrl-Z you return to parent mode and the prompt:

ExampleName#

Here you use show commands to verify the results of the commands you issued in config mode. To verify the results of the ip name-server command, issue the command show host.

Posted in Labels: 0 comments Posted by shfind at 10:12 PM

Configuring Cisco router interfaces

(Wednesday, February 6, 2008)

"Media type" refers to the type of media that the port is an interface for, such as Ethernet, Token Ring, FDDI, serial, etc. Slot numbers are only applicable for routers that provide slots into which you can install modules. These modules contain several ports for a given media. The 7200 series is an example. These modules are even hot-swapable. You can remove a module from a slot and replace it with a different module, without interrupting service provided by the other modules installed in the router. These slots are numbered on the router.

Port number refers to the port in reference to the other ports in that module. Numbering is left-to-right, and all numbering starts at 0, not at one.

For example, a Cisco 7206 is a 7200 series router with six slots. To refer to an interface that is the third port of an Ethernet module installed in the sixth slot, it would be interface ethernet 6/2. Therefor, to display the configuration of that interface you use the command:

ExampleName#show interface ethernet 6/2

If your router does not have slots, like a 1600, then the interface name consists only of:

media type port#

For example:

ExampleName#show interface serial 0

Here is an example of configuring a serial port with an IP address:

ExampleName#config
ExampleName(config)#interface serial 1/1
ExampleName(config-if)#ip address 192.168.155.2 255.255.255.0
ExampleName(config-if)#no shutdown
ExampleName(config-if)#ctrl-Z
ExampleName#

Then to verify configuration:

ExampleName#show interface serial 1/1

Note the no shutdown command. An interface may be correctly configured and physically connected, yet be "administratively down." In this state it will not function. The command for causing an interface to be administratively down is shutdown.

ExampleName(config)#interface serial 1/1
ExampleName(config-if)#shutdown
ExampleName(config-if)#ctrl-Z
ExampleName#show interface serial 1/1

In the Cisco IOS, the way to reverse or delete the results of any command is to simply put no infront of it. For instance, if we wanted to unassign the IP address we had assigned to interface serial 1/1:

ExampleName(config)#interface serail 1/1
ExampleName(config-if)#no ip address 192.168.155.2 255.255.255.0
ExampleName(config-if)ctrl-Z
ExampleName#show interface serial 1/1

Configuring most interfaces for LAN connections might consist only of assigning a network layer address and making sure the interface is not administratively shutdown. It is usually not necessary to stipulate data-link layer encapsulation. Note that it is often necessary to stipulate the appropriate data-link layer encapsulation for WAN connections, such as frame-relay and ATM. Serial interfaces default to using HDLC. A discussion of data-link protocols is outside the scope of this document. You will need to look up the IOS command encapsulation for more details.

ROUTER COMMANDS

ROUTER COMMANDS

Usermode Commands

1. disconnect, hapus sesi telnet dan logout
2. enable, masuk ke privilegemode
3. ping
4. traceroute

Privilegemode Commands

1. clear arp-cache, hapus cache arp
2. configure terminal, masuk ke global configuration mode
3. copy running-config startup-config, simpan konfigurasi sekarang
4. copy startup-config running-config, load konfigurasi yang tersimpan
5. debug ip packet, debug paket dari tcp/ip
6. disable, kembali ke privilegemode dari global configuration mode
7. disconnect
8. erase startup-config, hapus file konfigurasi dari router
9. logout, keluar dari privilegemode
10. ping
11. reload, load kembali startup-config
12. resume , konek kembali setelah diskonek
13. show access-list, memperlihatkan semua access-list dari semua protokol pada router
14. show banner, memperlihatkan banner
15. show cdp, memperlihatkan status CDP router
16. show cdp interface, memperlihatkan interface CDP
17. show cdp neighbor
18. show cdp traffic
19. show clock
20. show flash, memperlihatkan IOS image dan file yang tersimpan di flash memory
21. show frame-relay lmi, memperlihatkan statistik detail LMI
22. show frame-relay map
23. show frame-relay pvc
24. show history, memperlihatkan semua perintah yang telah di eksekusi
25. show hosts, memperlihatkan static host yang disimpan
26. show interfaces, memperlihatkan interface yang dimiliki (semua) secara detail
27. show interfaces ethernet 0
28. show interfaces serial 0
29. show interfaces loopback 0
30. show ip arp
31. show ip eigrp neighbors
32. show ip eigrp neighbors detail
33. show ip eigrp topology
34. show ip eigrp traffic, memperlihatkan traffic statistik dari protokol eigrp
35. show ip interface
36. show ip interface brief, verify konfigurasi ip
37. show ip ospf database
38. show ip ospf interface
39. show ip ospf neighbor detail
40. show ip route, memperlihatkan konfigurasi routing
41. show protocols, memperlihatkan protokol routing yang telah dikonfigurasi dan sedang berjalan
42. show running-config, memperlihatkan konfigurasi global yang sedang berjalan
43. show sessions, memperlihatkan sesi yang ada sekarang
44. show startup-config, memperlihatkan konfigurasi yang tersimpan pada flash
45. show version, memperlihatkan informasi hardware dan firmware
46. telnet
47. traceroute
48. vlan database, mengakses vlan database atau masuk ke konfigurasi VTP
49. write erase
50. write memory
51. write terminal

Global configuration mode Commands

1. access-list {permit|deny}
2. access-list {permit|deny}
3. access-list {permit|deny}
4. access-list {permit|deny}
5. banner motd
6. cdp advertise-v2
7. cdp holdtime , mengubah nilai holdtime cdp
8. cdp run
9. cdp timer , mengubah nilai cdp timer
10. config-register
11. dialer-list protocol ip permit
12. enable password , set password untuk masuk ke mode privilege
13. enable secret , set enkripsi untuk password yang disimpan
14. end, kembali ke mode privilege
15. hostname , set nama host
16. interface ethernet 0, masuk ke subconfiguration interface ethernet 0
17. interface fastethernet 0, masuk ke subconfiguration interface fastethernet 0
18. interface serial 0, masuk ke subconfiguration interface serial 0
19. interface vlan , masuk ke subconfiguration vlan
20. ip default-gateway , set default gateway
21. ip default-network
22. ip host , set static hostname lain
23. ip name-server , set DNS router
24. ip route {next-hop-ip-addr|interface-type}
25. ip route 0.0.0.0 0.0.0.0 , set defaut gateway / static route
26. ip route , set static route
27. ip routing
28. ipx routing
29. isdn switch-type
30. line aux
31. line console 0, masuk ke konfigurasi console nomer 0
32. line vty 0 4, masuk ke konfigurasi vty untuk 5 buah vty
33. no banner motd, menghapus banner
34. no ip routing, menghapus ip routing
35. no router igrp, menghapus konfigurasi route igrp
36. no router ospf, menghapus konfigurasi route ospf
37. no router rip, menghapus konfigurasi route rip
38. no vlan , menghapus vlan nomer ke sekian
39. router eigrp , masuk ke konfigurasi routing menggunakan eigrp
40. router ospf , masuk ke konfigurasi routing menggunakan ospf
41. router rip, masuk ke konfigurasi routing menggunakan rip
42. snmp-server enable traps vtp
43. username password , set username dan passwordnya

Interface subconfiguration mode Commands

1. bandwidth , set bandwidth yang akan dilalui interface ini dalam kilobits
2. cdp enable
3. clock rate , set clock rate dalam bits/s
4. compress stac in

Line subconfiguration mode Commands

1. exec-timeout [detik], pilihan detik opsional
2. login synchronous
3. password , set passwordnya

Subinterface subconfiguration mode Commands

1. description , set deskripsi dari subinterface

IP Routing Protocol subconfiguration mode Commands

1. network , set ip network