Sale

วันอังคารที่ 10 พฤษภาคม พ.ศ. 2554

Cisco Router Configuration Training :: Cisco Hardware เบื้องต้น

Cisco Router Configuration Training
Cisco Hardware เบื้องต้น
High-end router
เป็น Router รุ่นที่สามารถทำการเปลี่ยนโมดูลได้ทันที โดยไม่ต้องเปิดฝาครอบ ส่วนใหญ่จะใช้ในสำนักงานใหญ่ ได้แก่
o cisco 12000, 7500, 7200, 7000 series
Access Product
เป็น Router ที่มักจะนำไปติดตั้งที่สำนักงานสาขา โดยการเลือกใช้ Interface จะต้องมีการระบุล่วงหน้า เนื่องจากการเปลี่ยนโมดูลมีความยุ่งยากมากกว่าแบบแรก จำนวนอินเตอร์เฟสโมดูลที่มีอยู่ในแต่ละรุ่นจะแตกต่างกันออกไป และบางรุ่นจะมีข้อจำกัดที่แตกต่างกันออกไป เช่น สามารถใช้งาน Data เพียงอย่างเดียว หรือสามารถใช้ได้ทั้ง Voice และ data และการนำเอา Router รุ่นต่างกันมาใช้งานร่วมกันจะต้องพิจารณาคุณสมบัติต่าง ๆ ให้เหมาะสมจึงจะสามารถนำมาใช้งานร่วมกันได้ สำหรับ Router ที่เป็น Access product ได้แก่
o cisco 4000, 3800, 3600, 2600, 2500,1600 series

การพิจารณาเลือกใช้ Cisco router product
1. พิจารณาจาก Scale ของ Router features ที่ต้อง
2. การ Port density/variety ที่ต้อง
3. การ Capacity และ Performance
4. Common user interface


หลักการพื้นฐานของ Router
· Router ทำง· านที่ระดับ OSI Layer 3 คือ Network Layer
· การทำง· านพื้นฐานในกระบวน Startup คือ การค้นหาและตรวจสอบ hardware, การค้นหาและโหลด Cisco IOS software image สุดท้ายคือการค้นหาและจัดการตาม Device configurations
· Router เป็นการทำง· านตาม Software function บาง· ครั้ง· อาจจะไม่ต้อง· ใช้ hardware (อาจจะติดตั้ง· หรือสั่ง· ง· านภายใน Server หรือ Host station)
· Router ทำการอ่านแพ็คเก็ตเพื่อดู Network address และเก็บข้อมูลไว้ใน Routing table ที่มี port ปลายทาง· (Destination port)และพารามิเตอร์บาง· อย่าง·
· Router มีการทำง· านที่ขึ้นอยู่กับโปรโตคอล (Protocol dependent) แต่ไม่ขึ้นอยู่กับสื่อกลาง· (Media independent)
· Router สามารถทำระบบป้อง· กันความปลอดภัย และการกลั่นกรอง· Traffic ได้
· ตำแหน่ง· ของ· Router จะอยู่ใน Distribution layer เสมอใน network design model
· Router มี WAN หรือ Serial interface เพื่อรอง· รับการเชื่อมต่อในระยะทาง· ไกล ๆ (Remote site connection)



การทำงานของ Router
· Router จะเริ่มทำง· านโดยจะไม่มี Network address ภายใน Routing table เลย
· เมื่อ Router ทำกระบวนการ Bootup process สำเร็จแล้ว Router จะทำการเรียนรู้ Network address โดยอาศัย Configuration fileและไม่สามารถเรียนรู้ได้โดยตัวของ· มันเอง·
· Network administrator สามารถที่จะป้อน Configuration file เพื่อให้ Router ทำง· านตามต้อง· การได้ในช่วง· ที่ทำการ Startup และ initial (Startup and initialized)
· Router สามารถทำการกลั่นกรอง· (filtering) traffic หรือแพ็คเก็ตได้ โดยการใช้ Access Control List (ACL) algorithm
· โดยค่า Default แล้ว Cisco router สามารถใช้ IP routing protocol และสามารถอ่าน MAC address เมื่อมันมีการเชื่อมต่อกับ LAN segment
· Router สามารถทำการ Mapping ค่า IP address และ MAC address โดยการใช้ ARP protocol

กระบวนการเริ่มต้นของ Router
กระบวนการ Cisco Device Startup
· ค้นหาและตรวจสอบ Hardware ของ· อุปกรณ์
· ค้นหาและโหลด Cisco IOS software image
· ค้นหาและสั่ง· ง· านตาม device configurations
กระบวนการ Router Power on/Bootup sequence
· Power on self test (POST)
· โหลดและ run bootstrap code
· ค้นหา IOS software
· ตรวจสอบ configuration register
· คัดลอก config ไปใส่ไว้ใน NVRAM
· เข้าถึง· ไฟล์แรกใน Flash
· พยายามทำ net boot
· RXBOOT
· ROMMON
· โหลด IOS software
· ค้นหา configuration
· โหลด configuration
· Run
Internal Configuration Components
ในตัวของ Router จะมี Internal Configuration Components อยู่ ได้แก่
· RAM/DRAM - ใช้ในการเก็บ Routing table, ARP cache, Fast switching cache, Packet buffering (share Ram) และ Packet hold queues นอกจากนี้ RAM ยัง· แบ่ง· ออกเป็น Temporary memory และ Running memory ซึ่ง· ใช้สำหรับ Router’s configuration file ซึ่ง· ใช้ในกรณีที่ Router เปิดอยู่ ข้อมูลที่อยู่ใน RAM ข้อมูลจะสูญ· หายไปเมื่อปิดเครื่อง· หรือ Restart เครื่อง·
· NVRAM – Nonvolatile RAM ใช้ในการเก็บ Router’s backup configuration file ข้อมูลใน NVRAM จะยัง· คง· อยู่ถึง· แม้ว่าจะปิดเครื่อง· หรือ Restart เครื่อง· ก็ตาม
· Flash – Erasable, re-programmable โดย ROM Flash memory จะทำหน้าที่เก็บ Operating system image และ microcode การมี Flash memory จะช่วยให้เราสามารถทำการ Update software ได้โดยไม่ต้อง· ทำการถอดหรือเปลี่ยน Chips ที่อยู่บน Processor ข้อมูลใน Flash จะยัง· คง· อยู่ถึง· แม้ว่าจะปิดเครื่อง· หรือ Restart เครื่อง· ก็ตาม IOS สามารถนำมาเก็บไว้ใน Flash memory
· ROM – จะประกอบด้วย Power-on diagnostics, Bootstrap program และ Operating program มีหน้าที่ในการ Bootstrap, POST, เก็บ mini IOS และทำหน้าที่ ROM monitor ในการ Upgrade software สามารถทำได้โดยการถอดและเปลี่ยน Ships บน CPU
· Interfaces – เป็นโมดูลที่ใช้ในการเชื่อมต่อเครือข่ายเข้าด้วยกันโดยส่ง· packet เข้าหรือออกจาก Router ซึ่ง· Interface อาจจะอยู่บน Motherboard หรืออยู่เป็น Interface module แยกต่าง· หากก็ได้
RAM สำหรับ Working Storage
RAM เป็น working storage area สำหรับ Router เมื่อทำการเปิดเครื่อง Bootstrap program จะถูกสั่งงานจาก RAM โปรแกรมบูทสแตรปนี้จะทำการทดสอบบางประการ หลังจากนั้นก็จะทำการ load โปรแกรม Cisco IOS software เข้าไปใน Memory โดยที่ Command executive หรือ EXEC ก็เป็นส่วนหนึ่งของ Cisco IOS software โดย EXEC ทำการรับและปฏิบัติตามคำสั่งที่เราป้อนเข้าไปใน Router
Router ยังคงทำการเก็บ Active configuration file และ tables ของ Network map และ Routing address list ภายใน Configuration file จะมีอักขระรหัส ASCII และสามารถแสดงได้ผ่านทางRemote terminal หรือ console terminal เพื่อความปลอดภัยไฟล์นี้จะถูกเก็บไว้ใน NVRAM โดย saved file นี้จะถูก access และ loaded เข้าไปใน Main memory ทุกครั้งที่ router initializes ภายใน Configuration file ยังมี global, process และ interface statements ซึ่งมีผลโดยตรงกับการทำงานของ Router และ interface ports ของมัน
Operating system image อยู่ในรูปแบบของเลขฐานสอง (binary executable form) เรียบร้อยแล้ว และไม่สามารถแสดงได้บนจอ terminal โดย image นี้จะถูกสั่งงานจาก Main RAM และ loaded จาก input source อันใด อันหนึ่ง Operating software ถูกจัดการในรูปแบบของ “Routines” ซึ่งจัดการทำงานที่เกี่ยวข้องกับโปรโตคอลที่แตกต่างกันไป, การเคลื่อนย้ายข้อมูล, การจัดการ tables และ Buffers, Routing updates และการปฏิบัติงานตาม User command
การตรวจสอบ Current configuration register value
ทำได้โดยการใช้คำสั่ง show versions ดังนี้
Router # show versions
สังเกตข้อมูลผลลัพธ์ที่ปรากฏจะแสดงถึง Configuration register ว่ามีค่าเท่าไร เช่น 0x2102
การทำการกำหนด Configuration register values
Router # configure terminal
Router (config) # sconfig-register 0x2102 สังเกตค่า 0x2 หมายถึง พิจารณาให้ทำการ boot โดย NVRAM (และค่านี้จะเป็นค่า Default ถ้า Router มี Flash) ค่าอื่น ๆ มีดังนี้
0x0 ใช้ ROM monitor mode ทำ Manual boot โดยการใช้ b command
0x1 ทำการ Boot อัตโนมัติจาก ROM
0x2 ถึง 0xF พิจารณาให้ทำการ boot โดย NVRAM
[กด Ctrl-Z]
Router # reload
วิธีการโหลด IOS จาก Flash
การตรวจสอบสามารถใช้คำสั่ง Show flash ดังนี้
Router # show flash
สังเกตข้อมูลผลลัพธ์ที่ปรากฏจะแสดงชื่อไฟล์ และขนาด รวมทั้งขนาดข้อมูลใน Flash
การโหลด Configuration
โดยปกติจะโหลด execute config จากNVRAM และถ้าไม่มี config ในNVRAM จะเข้าสู่โหมด setup mode
คำสั่งที่ใช้ในการแสดง Configuration
Router # show running-config คำสั่งนี้ใช้แสดง Current configuration ใน RAM
Router # show startup-config คำสั่งนี้ใช้แสดง Saved configuration ใน NVRAM
วิธีการ backup configuration & IOS files
คำสั่งที่ใช้มีดังนี้
Router # copy <source> <destination>
Source หรือ destination อาจจะเป็น
o Running-configuration
o Startup-configuration
o Tftp
o Flash
o หรือพิมพ์ help เมื่อต้องo การข้อมูลเพิ่มเติม
คำสั่งนี้ใช้ในการทำการสำรองไฟล์จากต้นทาง ไปยังสถานที่จัดเก็บไฟล์ปลายทาง
ตัวอย่าง
Router # copy run start (เป็นการคัดลอก running configuration ไปยัง Start-up configuration หรือหมายถึงการคัดลอก Configuration ปัจจุบันไปยัง NVRAM)
Router # copy start run (เป็นการคัดลอก startup configuration ไปยัง running configuration หรือหมายถึงการคัดลอก Startup Configuration ใน NVRAM ไปยังRAM)
Router # write [memory]
Router # copy runing-config tftp (เป็นการคัดลอก running configuration ไปเก็บไว้ใน tftp server)
Router # copy tftp runing-config (เป็นการคัดลอกไฟล์ configuration จาก tftp server ไปยัง RAM)
Router # copy startup-config tftp (เป็นการคัดลอก startup configuration ไปเก็บไว้ใน tftp server)
Router # copy tftp startup-config (เป็นการคัดลอกไฟล์ configuration จาก tftp server ไปยัง NVRAM)
การเตรียมการสำรอง Network Backup Image
· ตรวจสอบการ access เข้ายัง· server
· ตรวจสอบเนื้อที่ว่าง· บน Server
· ตรวจสอบ file naming convention
· สร้าง· ไฟล์บน Server ถ้าจำเป็น
การตรวจสอบ memory และ image filenames
ใช้คำสั่ง show flash
Router # show flash (จะแสดงชื่อ IOS file image และขนาดที่ใช้ใน flash)
การสร้าง Software Image backup
Router # copy flash tftp (เป็นการคัดลอกข้อมูลใน flash ไปเก็บไว้ใน tftp server)
การ Upgrade image จาก tftp server
Router # copy tftp flash (เป็นการคัดลอกไฟล์ IOS image จาก tftp server ไปยัง Flash)
วิธีการกำหนด Configuration สำหรับ Router
การกำหนด Configuration สามารถทำได้จากแหล่งหลายๆ แหล่งดังต่อไปนี้
· ในการติดตั้ง· ครั้ง· แรกเราสามารถกำหนด Configure ได้จาก console terminal โดยการต่อสายโดยตรง· เข้ากับ Console port
· เราสามารถทำการต่อผ่านโมเด็มโดยใช้ Auxiliary port
· เมื่อต่อ Router เข้าเป็นเครือข่ายเรียบร้อยแล้ว เราสามารถทำการ Configure ได้จาก Virtual terminals 0 ถึง· 4
นอกจากนี้ไฟล์ Configuration ยังสามารถทำการ downloaded Configure ได้จาก TFTP server ในเครือข่าย
ในการกำหนด Configuration ของ CISCO Router สามารถทำได้ผ่านทาง Router console หรือ terminal รวมทั้งสามารถทำการ Configuration ได้โดยการใช้ Remote access โดย Cisco Internetwork Operating System (Cisco IOS) software จะมีตัวแปลคำสั่ง (Command interpreter) ที่เรียกว่า EXEC โดย EXEC ทำการแปลคำสั่งทีละคำสั่งที่เราพิมพ์เข้าไปและปฏิบัติตามคำสั่งเหล่านั้น เราจะต้องทำการ Log in เข้าไปใน Router ก่อนจึงจะสามารถใช้ EXEC command ได้
วิธีการเข้าไป Set up router ผ่านทาง Console connection
การเตรียมการ
1. เครื่อง PC ที่มีตัวแปลง RJ-45 to DB-9 หรือ RJ-45 to DB-25 adapter
2. การ Setting COM port ดังต่อไปนี้ : 9600 bps, 8 data bits, no parity, 1 stop bit, no flow control
วิธีการ Log in
เราสามารถทำการ Login เข้าไปใน Router ได้ โดยโหมดต่าง ๆ ที่สามารถเข้าได้มีดังต่อไปนี้
· User EXEC mode :
เป็นโหมดเริ่มแรกในการ Log in เข้าสู่ Router โดยคำสั่งที่สามารถใช้ได้ในโหมดนี้เป็น EXEC commands ที่เป็น Subset ย่อยๆ ของ EXEC commands ที่มีอยู่ในโหมด Privileged mode โดยคำสั่งส่วนใหญ่ที่มีอยู่จะใช้เพียงเพื่อดูข้อมูลต่างๆ ใน Router หรือตรวจสอบสถานะ (Status) การทำงานโดยไม่สามารถทำการแก้ไขหรือเปลี่ยนแปลง Router configuration settingsได้ โดยมี User mode Prompt ดังนี้
Router > (สังเกตเครื่องหมายจะเป็น >)
· Privileged EXEC mode หรือ Enable Mode :
เป็นโหมดที่สามารถใช้ EXEC commands ได้ทุกคำสั่ง โดยมี EXEC prompt เป็นเครื่องหมาย Pound (#) วิธีการเข้าสู่โหมดนี้สามารถทำได้โดยพิมพ์คำสั่งจาก User EXEC mode ดังนี้
Router > enable (หรือพิมพ์ย่อ ๆ ว่า ena ก็ได้)
Password : ใส่ Password ตามที่เคยกำหนดไว้
หลังจากกด Enter จะปรากฏ Privileged-mode prompt ดังนี้
Router # (สังเกตเครื่องหมายจะเป็น #)
ในโหมดนี้จะมีโหมดย่อย ๆ อยู่ 2 mode คือ
o Global Configuration mode :
การเข้าสู่โหมดนี้สามารถทำได้โดยพิมพ์คำสั่งจาก Privileged-mode prompt ดังนี้
Router # configure (หรือพิมพ์ย่อ ๆ ว่า conf ก็ได้)
หลังจากกด Enter จะปรากฏ Global configuration mode prompt ดังนี้
Router (config) #
o Other Configuration mode :
การเข้าสู่โหมดนี้ทำได้โดยพิมพ์คำสั่งจาก Global configuration mode prompt ดังนี้
Router (config) # interface <type><slot#/port#>
หลังจากกด Enter จะปรากฏ Global configuration mode prompt ดังนี้
Router (config-mode) # คำว่า mode ใน prompt อาจจะแสดงเป็น if หรือคำอื่น ๆ ตามคำสั่งที่ใส่เข้าไปในตอนแรก
· SETUP mode :
เป็น System dialog mode เพื่อทำการกำหนด Configuration เป็นโหมดที่ช่วยให้ผู้ใช้งาน Router เป็นครั้งแรก สามารถสร้างConfiguration พื้นฐานได้อย่างง่ายดาย
· RXBOOT mode :
ใช้สำหรับการกู้คืน Password หรือซ่อมแซมบางคำสั่งที่ผิดพลาด หรือสำหรับการดูแลระบบ หรือกรณีที่ระบบปฏิบัติการ ถูกลบออกไปจาก Flash
· ROMMON mode :
ใช้สำหรับการตรวจดูข้อมูลใน ROM เป็นโหมดที่ใช้ในกรณีที่เราลืม Password ที่จะเข้าในโหมดอื่น ๆ
วิธีการ Log out
ในการ Log out ออกจาก Router สามารถทำได้โดยการพิมพ์คำสั่ง exit
User-Mode Command List
หากเราต้องการให้แสดงคำสั่งที่มีใช้ในแต่ละโหมดสามารถทำได้โดยใช้คำสั่ง help หรือพิมพ์เครื่องหมายคำถาม (?) ที่ User modes prompt หรือ Privileged mode prompt
สังเกตว่า หากมีคำว่า - - More - - แสดงขึ้นที่ด้านล่างของจอแสดงผล แสดงว่ายังมีหน้าจอที่ต้องการแสดงผลต่อไปซึ่งจะมีข้อมูลตามมาอีก เราสามารถดูหน้าจอถัดไปได้โดยการกด Space bar หรือหากต้องการดูบรรทัดถัดไปกด Enter key การกดปุ่มใด ๆ เป็นการกลับเข้าไปสู่เครื่องหมาย Prompt
จอแสดงผลเอาท์พุทจะเปลี่ยนแปลงไปตามระดับ Cisco IOS software level และ Router configuration
คำสั่งต่างๆ ที่มีอยู่ใน User mode มีดังต่อไปนี้
Router > ? (หรือพิมพ์คำว่า help)
Exec commands :
access-enable สร้าง Access list entry ชั่วคราว
atmsig ปฏิบัติการตามคำสั่ง ATM Signaling Commands
cd เปลี่ยนอุปกรณ์ปัจจุบัน
clear Reset functions
connect ทำการเปิด Terminal connection
dir แสดงรายการไฟล์ของอุปกรณ์ที่กำหนดให้
disable ปิดการใช้งานคำสั่ง Privileged commands ออกจาก Privileged mode
disconnect ยกเลิกการเชื่อมต่อโครงข่ายที่มีอยู่
enable เปิดใช้คำสั่ง Privileged commands เข้าสู่ Privileged mode
exit ออกจาก EXEC
help ระบบขอความช่วยเหลือแบบเร่งด่วน
lat เปิด lat connection
lock ทำการ Lock terminal
login Log in เป็นแบบ particular user
logout ออกจาก EXEC
mrinfo ร้องขอข้อมูลของอุปกรณ์ข้างเคียงจาก multicast router
mstat แสดง statistics หลังจากทำ multiple multicast traceroutes
mtrace trace reverse multicast path จากปลายทางไปยังต้นทาง
name-connection แสดงชื่อการเชื่อมต่อโครงข่ายที่มีอยู่
pad เปิด pad connection
ping ส่ง echo message
ppp เริ่ม IETF Point-To-Point Protocol (PPP)
pwd แสดง current device
resume resume การเชื่อมต่อโครงข่ายที่ active อยู่
rlogin เปิด rlogin connection
show แสดง running system information
slip เริ่ม Serial-line IP(SLIP)
systat แสดงข้อมูลเกี่ยวกับ Terminal lines
telnet เปิด telnet connection
terminal กำหนด terminal line parameters
tn3270 เปิด tn3270 connection
traceroute Trace route ไปยังปลายทาง
tunnel เปิด Tunnel connection
where แสดง active connections
x3 set x.3 parameters on PAD
xremote Enter XRemote mode
Privileged-Mode Command List
ในการเข้าสู่ Privileged mode ให้พิมพ์คำสั่ง enable หรือใช้คำสั่งย่อว่า ena จากนั้นให้ใส่ password (หากมีการกำหนดไว้) และพิมพ์เครื่องหมายคำถามที่ Privileged mode prompt เพื่อแสดงคำสั่ง EXEC commands ต่างๆ ที่สามารถใช้งานได้
คำสั่งต่างๆ ที่มีอยู่ใน Privileged mode มีดังต่อไปนี้
Router > enable (หรือพิมพ์คำว่า ena)
Password:
Router # ?
Exec commands:
access-enable สร้าง Access list entry ชั่วคราว
access-template สร้าง Access list entry ชั่วคราว
appn ส่งคำสั่งไปยัง APPN subsystem
atmsig ปฏิบัติการตามคำสั่ง ATM Signaling Commands
bfe ใช้สำหรับ manual emergency modes setting
calendar จัดการเกี่ยวกับhardware calendar
cd เปลี่ยนอุปกรณ์ปัจจุบัน
clear Reset functions
clock จัดการเกี่ยวกับ System clock
cmt เริ่มหรือหยุด FDDI Connection Management functions
configure เข้าสู่ configuration mode
connect ทำการเปิด Terminal connection
copy คัดลอก configuration หรือ image data
debug เข้าสู่ debugging functions
delete ลบไฟล์
dir แสดงไฟล์บนอุปกรณ์ที่เลือก
disable ปิดคำสั่ง Privileged commands
disconnect ยกเลิกการเชื่อมต่อโครงข่ายที่มีอยู่
enable เปิดใช้คำสั่ง Privileged commands เข้าสู่ Privileged mode
exit ออกจาก EXEC
help ระบบขอความช่วยเหลือ
lat เปิด lat connection
lock ทำการ Lock terminal
login Log in เป็นแบบ particular user
logout ออกจาก EXEC
mrinfo ร้องขอข้อมูลของอุปกรณ์ข้างเคียงจาก multicast router
mstat แสดง statistics หลังจากทำ multiple multicast traceroutes
mtrace trace reverse multicast path จากปลายทางไปยังต้นทาง
name-connection แสดงชื่อการเชื่อมต่อโครงข่ายที่มีอยู่
pad เปิด pad connection
ping ส่ง echo message
ppp เริ่ม IETF Point-To-Point Protocol (PPP)
pwd แสดง current device
resume resume การเชื่อมต่อโครงข่ายที่ active อยู่
rlogin เปิด rlogin connection
show แสดง running system information
slip เริ่ม Serial-line IP(SLIP)
systat แสดงข้อมูลเกี่ยวกับ Terminal lines
telnet เปิด telnet connection
terminal กำหนด terminal line parameters
tn3270 เปิด tn3270 connection
traceroute Trace route ไปยังปลายทาง
tunnel เปิด Tunnel connection
where แสดง active connections
x3 set x.3 parameters on PAD
xremote Enter XRemote mode
Tip เพิ่มเติม
o ในการพิมพ์คำสั่งo หากส่วนใดที่พิมพ์ผิดไวยากรณ์จะปรากฏเครื่องo หมาย (^) แสดงo ตรงo ตำแหน่งo ที่ผิดพลาด หากเราต้องo การเรียกคำสั่งo ที่พิมพ์ไปก่อนหน้านี้แล้วให้กดปุ่ม <Ctrl><P>
o การใช้ help (?) มี 2 รูปแบบคือ
word help พิมพ์ติดกับคำสั่งที่ต้องการ
command help พิมพ์หลังจากคำสั่งที่ต้องการโดยเว้นวรรคหนึ่งครั้ง
การใช้ Editing Commands
โดยปกติแล้ว editing mode จะถูก Enable อยู่แล้ว แต่เราสามารถทำการ Disable ได้โดย Software ด้วยการเขียน scripts โดยปุ่มกดต่าง ๆ ที่ใช้ใน Command line ได้แก่
o ปุ่ม <Ctrl><A> เลื่อนไปที่จุดเริ่มต้นของo Command line
o ปุ่ม <Ctrl><E> เลื่อนไปที่จุดสุดท้ายของo Command line
o ปุ่ม <Esc><B> เลื่อนกลับไปหนึ่งo คำ
o ปุ่ม <Esc><F> เลื่อนไปหน้าหนึ่งo คำ
o ปุ่ม <Ctrl><F> เลื่อนไปหน้าหนึ่งo อักขระ
o ปุ่ม <Ctrl><B> เลื่อนกลับไปหนึ่งo อักขระ
o ปุ่ม <Ctrl><D> ลบออกหนึ่งo อักขระ
o ปุ่ม <Ctrl><P> หรือปุ่มลูกศรชี้ขึ้น ใช้ในการเรียกซ้ำคำสั่งo ล่าสุด
o ปุ่ม <Ctrl><N> หรือปุ่มลูกศรชี้ลงo ใช้ในการเรียกซ้ำคำสั่งo ที่ผ่านมา
o ปุ่ม <Tab> ใช้แสดงo คำสั่งo เต็มของo คำสั่งo ที่เราคีย์เข้าไป
o ปุ่ม <Ctrl><Z> ใช้ในการออกจาก Configuration mode
ปุ่มต่าง ๆ เหล่านี้ใช้ในการเลื่อนไปยังจุดที่ต้องการเพื่อทำการแก้ไขหรือเปลี่ยนแปลงข้อความหรือคำสั่งให้ถูกต้อง โดยในโหมดนี้จะมี เครื่องหมาย dollar sign ($) แสดงอยู่
ในกรณีที่ต้องการออกจาก Mode นี้ ทำได้โดยการกดปุ่ม <Ctrl><C>
คำสั่งที่ใช้ในการตรวจสอบว่าเคยใช้คำสั่งอะไรไปบ้างแล้วคือ
Router>show history (แสดงข้อมูลใน Command buffer)
คำสั่งพื้นฐานในการเริ่มต้นใช้งาน Router
Router > enable (เข้าสู่ Privilege mode)
Password : <string> (พิมพ์ password)
Router # terminal ip netmask-format <option> ใช้ในการกำหนดรูปแบบของ Netmask สำหรับ current session สามารถกำหนดได้เป็น bitcount, decimal หรือ hexadecimal
Router (config) # configure terminal (หรือใช้คำสั่งย่อเป็น conf term เป็นคำสั่งที่จะเข้าสู่การ Configure Router)
Router (config) # hostname <name> (ใช้สำหรับการกำหนดชื่อของ Router)
ตัวอย่าง
Router# conf term
Router (config) # hostname Somposh
Somposh (config) # (สังเกตว่าชื่อของ Router จะเปลี่ยนจากคำว่า Router เป็น Somposh)
Router (config) # enable secret <name> (ใช้สำหรับการกำหนด secret password)
Router (config) # enable password <name> (ใช้สำหรับการกำหนด password ก่อนจะเข้าสู่ Privileged mode)
Router (config) # line vty <start> <stop> (ใช้สำหรับการกำหนด virtual terminal สำหรับการ telnet)
Router (config-line) # login (ใช้ในการ Login ไปยังอุปกรณ์ตัวอื่นผ่านทาง Virtual terminal)
Router (config-line) # password <string> (ใช้ในการกำหนด Virtual terminal password )
Router (config-line) # loging synchronous
Router (config-line) # exec-timeout <min> <sec> ใช้ในการกำหนด exec-timeoutในกรณีที่ระบุเป็น 0 0 จะทำให้ Console นั้น connect อยู่ตลอดเวลา
Router (config-line) # ip netmask-format <option> ใช้ในการกำหนดรูปแบบของ Netmask ของ line ที่ระบุ สามารถกำหนดได้เป็น bitcount, decimal หรือ hexadecimal
Router (config-line) # service password-encryption
Router (config) # banner motd <char>
Router (config) # interface <type> <slot#/port#> คำสั่งนี้ใช้ในการทำการ configure interface ที่ต้องการ
o <type> ที่สามารถระบุได้แก่ serial, ethernet, token ring, fddi, hssi, loopback, dialer, null, async, atm, bri และ tunnel
ตัวอย่าง
Router (config) # interface serial 0 คำสั่งนี้ใช้ในการทำการ configure Serial interface 0
Router (config-if) # description <string> คำสั่งนี้ใช้สำหรับใส่ Description เพิ่มเติม
Router (config-if) # bandwidth <kbps> คำสังนี้ใช้ในการกำหนด Bandwidth ของอินเตอร์เฟสที่ใช้งาน
Router (config-if) # clock rate <sbit/sec> คำสั่งนี้ใช้ในการกำหนด clock rate ของอินเตอร์เฟส ซึ่งจะสัมพันธ์กับค่า bandwidth
Router (config-if) # media-type <type>
Router (config-if) # [no] shutdown คำสั่งนี้ใช้ในการกำหนดใช้งานหรอไม่ใช้งานอินเตอร์เฟส
Router (config-if) # ip address <ip> <mask> คำสั่งนี้ใช้ในการกำหนด ip address ของอินเตอร์เฟส
Router (config) # ip host <name> <address> คำสั่งนี้ใช้ในการกำหนด ip host name ของอินเตอร์เฟส
Router (config) # snmp-server <ip_address> ระบุ host ที่กำหนดให้เป็น snmp server
Router (config) # ip subnet-zero
Router (config) # ip classless
Router (config) # [no] ip domain-lookup
Router (config) # ip name-server <ip#1><ip#2>…..<ip#6>
Router (config) # end
Router (config) # exit
Router #
คำสั่งที่ใช้ในการแสดงสถานะของ Router (Router Status Commands)
คำสั่งพื้นฐานที่ใช้สำหรับการมอนิเตอร์และแก้ไขปัญหา
คำสั่งที่ใช้สำหรับการค้นหา Address และแก้ไขปัญหา (Address Verifying and troubleshooting)
Address virifying :
Router # ping [standard | extended] (ใช้สำหรับการทดสอบ IP address ที่ต้องการว่ามีการทำงานตามปกติหรือไม่ หรือมีอยู่ในเครือข่ายหรือไม่)
Router # trace [standard | extended] (ใช้สำหรับแสดงเส้นทางที่ข้อมูลวิ่งผ่านไปยัง IP address ที่ต้องการ)
Router # telnet <destination> (ใช้สำหรับการเชื่อมต่อไปใช้งานเครื่องอื่นในเครือข่าย)
Router # connect <destination>
Troubleshooting :
Router # [no] debug <?>
Router # show debug
Router # show interface <type> <slot#/port#>
Router # show running-configuration
Router # show user
Router # show session
Router # <Ctrl-Shift-6> x
Router # resume <session#>
Router # disconnect
Router # clear line <line#>
คำสั่งสำหรับการมอนิเตอร์และการแสดงผล (Monitoring and Displaying Commands)
Router # show ? (ใช้ดูว่าคำสั่ง Show สามารถแสดงผลให้เห็นอย่างไรบ้าง)
Router # show running-configuration (ใช้ดูว่า running configuration ที่ทำงานอยู่ ซึ่งเก็บอยู่ใน RAM มีอะไรบ้าง หรือใช้แสดงข้อมูลใน Active configuration file)
Router # show starutup-configuration (ใช้ดูว่า Start up configuration ที่ที่เก็บอยู่ใน ROM มีอะไรบ้าง หรือใช้แสดงข้อมูลใน Backup configuration file)
Router # show cdp <?> คำสั่งนี้ใช้ในการแสดงถึงอุปกรณ์ข้างเคียงที่มาต่อกับ Router โดยอาศัย Cisco Discovery Protocol (CDP) รวมทั้งข้อมูลต่าง ๆ ที่ได้มาจาก Cisco Discovery Protocol (CDP)
ตัวอย่าง
Router # show cdp neighbors คำสั่งนี้ใช้ในการแสดงถึงอุปกรณ์ข้างเคียงที่มาต่อกับ Router โดยอาศัย Cisco Discovery Protocol (CDP) โดยแสดงเพียงชื่ออุปกรณ์และ Port ID เท่านั้น
Router # show cdp entry คำสั่งนี้ใช้ในการแสดงถึงอุปกรณ์ข้างเคียงที่มาต่อกับ Router โดยอาศัย Cisco Discovery Protocol (CDP) โดยจะแสดงรายละเอียดเกี่ยวกับ Interface ที่มาเชื่อมต่อรวมทั้ง IP ของอินเตอร์เฟสนั้นๆ
Router # show cdp traffic คำสั่งนี้ใช้ในการแสดงถึงปริมาณของข้อมูล CDP ที่รับเข้าและส่งออกจาก Router รวมทั้งการตรวจสอบ Error ของ CDP ด้วย
Router # show cdp interface คำสั่งนี้ใช้ในการแสดงถึงสถานะของอินเตอร์เฟส วิธีการ Encapsulate
Router # show version (ใช้แสดง Configuration ของ System hardware, Software version ชื่อและที่สถานที่เก็บ Configuration file รวมทั้ง Boot images)
Router # show process cpu (ใช้แสดงข้อมูลเกี่ยวกับ Active processes ของ CPU)
Router # show process memory (ใช้แสดงข้อมูลเกี่ยวกับ Active processes ของ Memory)
Router # show stack (ใช้ในการ Monitors stack ที่ใช้ใน Processes routine และ interrupt routine และแสดงสาเหตุที่ทำให้ระบบ Reboot ในรอบที่ผ่านมา)
Router # show buffer (ใช้ในการแสดงสถิติของ Buffer pools บน Network server)
Router # show memory (ใช้แสดงสถิติเกี่ยวกับ router’s memory รวมทั้งสถิติของ Memory ที่ว่างอยู่)
Router # show flash (ใช้แสดงข้อมูลเกี่ยวกับอุปกรณ์ Flash memory)
Router # show hosts (ใช้แสดงข้อมูลเกี่ยวกับ Host)
Router # show protocol (ใช้แสดง configured protocol โดยแสดงสถานะของโปรโตคอลในระดับ 3 (Network layer protocol) เช่น IP, IPX, DECnet และ AppleTalk)
Router # show interface <type> <slot#/port#> (ใช้แสดงสถิติสำหรับอินเตอร์เฟสต่าง ๆ ทั้งหมดที่ถูก Configure ในRouter)
Router # show line
Router # show ip route [protocol] (ใช้ในการบ่งบอกถึงเส้นทางที่อยู่ใน Routing table ภายในเครือข่ายที่เป็นเป้าหมาย)
การทดสอบการทำงานขั้นพื้นฐาน
ในการทดสอบการทำงานขั้นพื้นฐานนั้นสามารถตรวจสอบได้ตามลำดับของ ISO/OSI layer โดยการทดสอบแต่ละอย่างจะสามารถระบุชี้ชัดในการทำงานภายในเครือข่ายตามลำดับชั้นที่ระบุไว้ใน OSI model
การทดสอบในระดับ Application layer โดยการใช้คำสั่ง telnet
สามารถ Access ไปยัง Remote router ได้หรือไม่?
เราจะเริ่มทดสอบการทำงานโดยการพุ่งประเด็นไปที่ระดับบนสุดของ OSI model คือ Application layer
Telnet application จะมีการสร้าง virtual terminal ซึ่ง Administrators สามารถใช้การทำงานของ Telnet ในการเชื่อมต่อกับ Host เครื่องอื่น ๆ ที่มีการใช้งาน TCP/IP การทดสอบทำเพื่อให้ทราบว่าเราสามารถทำการ Remote access ไปยัง Remote router ที่เราต้องการได้
ถ้าเราสามารถทำการ Remotely access ไปยัง Router อื่นๆ ได้โดยใช้ Telnet นั่นก็หมายความว่า อย่างน้อยที่สุดเราก็ทราบว่า TCP/IP application หนึ่ง สามารถใช้งานได้ใน Remote router การเชื่อมต่อด้วย Telnet ที่ประสบความสำเร็จ บ่งแสดงให้เห็นว่า Upper-layer Application ทำงานได้อย่างถูกต้อง
ถ้าหากเราสามารถ Telnet ไปยัง Router หนึ่งได้ แต่ไม่สามารถ Telnet ไปยัง Router อื่นได้ ก็หมายความว่า Telnet failure เกิดขึ้นเนื่องมาจากปัญหาในเรื่องของการระบุ address, การระบุชื่อ, หรือ Access permission ซึ่งปัญหาต่าง ๆ เหล่านี้สามารถเกิดขึ้นได้ใน Router ที่ Fail นั้น ๆ
ตัวอย่าง
Router # telnet 10.2.2.1 ทำการ Telnet ไปยัง IP wan port ที่ต้องการ
Router # show sessions ใช้ในการตรวจสอบ Sessions
Router # show user ใช้ในการตรวจสอบ user ที่เข้ามาในแต่ละ Sessions
วิธีการพัก Telnet Session ดำเนินการได้ดังนี้
Router # <Ctrl-Shift-6> x
Router # show session (ดูว่ามี Session ใดต่ออยู่บ้าง)
Router # resume 1 (หมายเลขที่ระบุ คือ หมายเลข Session ที่ต้องการพักการใช้งาน)
Router #
วิธีการปิด Telnet Session ดำเนินการได้ดังนี้
Router # disconnect คำสั่งนี้ใช้ในการ ปิด Current session ที่เปิดโดยตัวเราเอง
Router # clear line <line#> คำสั่งนี้ใช้ในการ ปิด session ที่เปิดโดย remote device
การทดสอบโดยการใช้คำสั่ง ping
สามารถส่ง Protocol packets ไปถึงปลายทางหรือไม่?
ในการตรวจสอบการเชื่อมต่อ มี Network protocols หลาย ๆ โปรโตคอลที่รองรับ echo protocol ซึ่งใช้ในการทดสอบเพื่อการตัดสินใจว่า protocol packet สามารถส่งไปได้ถึงเป้าหมายที่ต้องการ
คำสั่ง ping ส่ง Datagram แบบพิเศษ ไปยัง host ปลายทาง และรอ Reply datagram จาก Host นั้น ผลจาก Echo protocol นี้ สามารถช่วยให้เรา หาค่าของความน่าเชื่อถือของพาทถึงโฮส (Path to host reliability), เวลาหน่วงของพาท (Path Delays) รวมทั้งแสดงว่า host ทำงานหรือไม่
ในการใช้งานคำสั่ง Ping ใน Router, เครื่องหมายตกใจ (!) แสดงถึง Successful echo แต่ละชุด ถ้าเราได้รับสัญลักษณ์เป็นจุด ๆ หนึ่ง (.) หรือมากกว่า ที่จอแสดงผล หมายความว่า การรอ datagram echo ที่ส่งมาจาก ping target ใช้เวลานานกว่าเวลาที่กำหนด (Time out) ซึ่งก็หมายความว่าอาจจะเกิดปัญหาในระหว่างทางที่ datagram นั้นวิ่งผ่าน
คำสั่ง ping สามารถใช้ในการตรวจสอบการเชื่อมต่อเครือข่ายในโครงข่าย AppleTalk, CLNS, IP, Novell IPX, Apollo, VINES, DEC net หรือ XNS
ตัวอย่าง
Router # ping 10.1.1.10 ทำการ pingไปยัง IP ที่ต้องการ โดยการส่ง Packet ที่มีการตั้งค่าที่เป็นค่า Default ของ Router เอง
หากเราต้องการping โดยการแก้ไขพารามิเตอร์บางตัวทำได้โดยดังนี้
Router # ping
หลังจากกด enter แล้ว จะมีพารามิเตอร์ต่าง ๆ ตามหลังมา ให้ระบุตามที่เราต้องการ
การทดสอบโดยการใช้คำสั่ง trace
เส้นทางที่ Packet วิ่งผ่านมีอะไรบ้าง ?
คำสั่ง trace เป็นเครื่องมือในอุดมคติ สำหรับการค้นหาว่าข้อมูลถูกส่งไปในโครงข่ายอย่างไร โดย trace command ใช้เทคโนโลยีเดียวกันกับ Ping command ยกเว้นเพียงแต่ว่า แทนที่จะเป็นการทดสอบการเชื่อมต่อแบบปลายถึงปลาย trace test จะทำการแจ้งข้อมูลทุกช่วงที่ Datagram วิ่งผ่าน
การทำงานนี้ สามารถกระทำที่ User หรือ privileged EXEC levels โปรโตคอลที่รองรับ Trace functions ได้แก่ IP, AppleTalk, VINES และ CLNS
คำสั่ง trace จะแจ้งให้ทราบด้วย error message ที่ผลิตออกมาจาก Router เมื่อ Datagram วิ่งผ่านเกินกว่าค่า Time To Live (TTL)ที่ระบุไว้
คำสั่ง trace เริ่มต้นโดยการส่ง probe datagrams ที่มีค่า TTL เท่ากับ 1 โดยค่านี้เป็นเหตุให้ Router ตัวแรก ทำการ discard ข้อมูลที่เป็นprobe datagram และส่ง error message กลับมา
คำสั่ง trace ทำการส่ง probe หลายๆ ตัวที่ TTL ต่าง ๆ และแสดงผลของ round trip time แต่ละช่วง เป้าหมายของคำสั่ง trace ก็คือ เพื่อบอกให้เราทราบว่า Router ตัวใดในเส้นทางที่เป็นตัวสุดท้ายที่ทำงาน ซึ่งเรียกว่า Fault isolation
ในกรณีที่มี Router ตัวใดตัวหนึ่ง Unreachable จะแสดงด้วยเครื่องหมาย * แทนที่จะเป็นชื่อของ Router และจะทำงานไปเรื่อย ๆ จนกว่าจะไปถึงปลายทาง หรือจนกว่าเราจะยกเลิกโดยการกดปุ่ม <Ctrl><Shift><6> ตามลำดับ
ตัวอย่าง
Router # trace 10.1.1.10 แสดงให้เห็นเส้นทางหรือ Router ที่ Packet วิ่งผ่าน
การใช้คำสั่ง Show ip route
เราสามารถดูข้อมูลใน Routing table ซึ่งจะเป็นตัวบ่งบอกถึงทิศทางที่ Router ใช้ในการตัดสินใจว่าจะทำการส่งผ่าน Traffic ผ่านเครือข่ายเป้าหมายไปได้อย่างไร โดยการใช้คำสั่งนี้จะใช้ทดสอบในระดับ Network layer ดังตัวอย่าง
Router# show ip route
การทดสอบการทำงานของ Link
อินเตอร์เฟสจะมีส่วนที่เกี่ยวข้องอยู่ 2 ส่วน คือ ทางฟิสิคอล และโลจิคอล
· การตรวจสอบทาง· ฮาร์ดแวร์จะต้อง· ดูว่ามีการเชื่อมต่อได้อย่าง· ถูกต้อง· ระหว่าง· อุปกรณ์ทั้ง· สอง·
· ส่วนของ· Software ก็คือ Message ที่ส่ง· ผ่านระหว่าง· อุปกรณ์ที่ต่อเข้าหากัน
เมื่อทำการทดสอบ Physical และ Data link เราสามารถถาม 2 คำถามต่อไปนี้
1. มีสัญ2. ญ3. าณ Carrier Detect signal หรือไม่?
4. ได้รับ Keepalive message หรือไม่?
ตัวอย่าง
Router # trace 10.1.1.10 แสดงให้เห็นเส้นทางหรือ Router ที่ Packet วิ่งผ่าน
การใช้คำสั่ง show interface serial
คำสั่งนี้ใช้ในการแสดงสถานะของ Line และ Data-link protocol สถานะของ Line สามารถตรวจจับจากสัญญาณ Carrier Detect ซึ่งอ้างอิงตาม OSI ในระดับ Physical layer อย่างไรก็ตาม Line protocol อาจพิจารณาได้จากการตรวจจับ Keepalive frame ซึ่งอยู่ในส่วนของ Data-link framing
Basic Routing Protocol Configuring
นิยาม Routed and Routing Protocol
หลักการพื้นฐานของ Routed protocol, Non-routed protocol และ Routing protocols
1. Non-Routed Protocol เป็นโปรโตคอลที่ไม่สามารถเลือกเส้นทาง2. (Routed) ไปยัง3. เครือข่ายปลายทาง4. (Destination network) ได้ โดยการตรวจสอบจาก Network address ซึ่ง5. สามารถแก้ไขการทำง6. านของ7. โปรโตคอลนี้ได้ด้วยการใช้ Bridging
8. Routed Protocol เป็นโปรโตคอลที่สามารถเลือกเส้นทาง9. (Routed) ไปยัง10. เครือข่ายปลายทาง11. (Destination network) ได้ โดยการตรวจสอบจาก Network address หลักการสำหรับ Router configuration
12. ซึ่ง13. สามารถแก้ไขการทำง14. านของ15. โปรโตคอลนี้ได้ด้วยการใช้ Bridging

การ Route คืออะไร
ในการทำการ Route นั้น Router จำเป็นที่จะต้องรู้สิ่งต่าง ๆ ดังต่อไปนี้
· Destination address โดยที่ router จะต้อง· เรียนรู้ Destination ที่ไม่ได้ต่อกับตัวมันโดยตรง·
· Source ที่มันสามารถเรียนรู้ได้มาจากที่ใด
· เส้นทาง· (route) ที่เป็นไปได้
· เส้นทาง· (route) ที่ดีที่สุด
· การ Maintain และ verify routing information
Routing Protocol คืออะไร
Routing protocol ถูกใช้ระหว่าง Router เพื่อกำหนดเส้นทาง และดูแล routing tables
Autonomous Systems : Interior หรือ Exterior Routing Protocols
ระบบ Autonomous systems เป็นการรวมโครงข่ายให้อยู่ภายใต้ administrative domain เดียวกัน
IGPs (Interior Gateway Protocols) ทำงานอยู่ภายใน Autonomous System ตัวอย่างโปรโตคอลในกลุ่มนี้เช่น RIP, IGRP
EGPs (Exterior Gateway Protocols) ทำการเชื่อมต่อ Autonomous System ที่แตกต่างกัน ตัวอย่างโปรโตคอลในกลุ่มนี้เช่น BGP
Static Route
Static route ทำหน้าที่ทำการส่ง Traffic และ เลือก Routed protocol ไปในเส้นทางถาวร (Static path) ซึ่งถูกกำหนดโดย Network administrator ซึ่งทำการกำหนดไว้ใน Routing table โปรโตคอลนี้ เหมาะสำหรับ Stub network (เครือข่ายที่มี Gateway ต่อออกไปยังภายนอกเพียงทางเดียว) มีการใช้งานหน่วยความจำน้อย, ใช้ทรัพยากรน้อยและง่ายต่อการ Configure และในกรณีที่มีการกำหนดเส้นทางแบบ Static routeแต่เพียงอย่างเดียวนั้น จะไม่มีการส่ง routing updates ออกไปใน Link เลย ดังนั้นทำให้ประหยัด Bandwidth
ข้อเสียของ Statistic route ก็คือ ต้องมีการทำการเพิ่ม Configuration ทุกครั้งที่มีการเพิ่มเส้นทาง และปัญหาจากการ fixed เส้นทาง กรณีที่เส้นทางนั้นเกิด Failure ก็จะทำให้ใช้งานไม่ได้เลย
คำสั่งที่ใช้
Router (config) # ip route <destination><mask> {<dest_address> | <interface_type>} [metric]
o Destination คือ Destination network address
o Mask คือ Destination subnet mask
o Dest_address คือ IP address ของo Next hop router
o Interface_type เป็น Local interface type
o Metric คือ keyword parameter สำหรับการปรับระยะทางo ของo routing priority 0-255 ค่า default 1
ตัวอย่าง
Router (config) # ip route 172.16.1.0 255.255.255.0 172.16.2.1
คำอธิบาย
ip route 172.16.1.0 เป็นการระบุ Static route ไปยัง subnetwork ปลายทาง
255.255.255.0 เป็น Subnet mask
172.16.2.1 หมายถึง IP address ของ next hop router ที่มีเส้นทางไปยังปลายทางที่ต้องการ
Default Route
Default route ใช้สำหรับการส่ง Traffic ไปยังเครือข่ายปลายทางถัดไปในกรณีที่ Routing table ไม่มี entry อยู่ภายในตาราง
การใช้งาน Default route มีการใช้งานคล้ายกับ Statistic route
คำสั่งที่ใช้
Router (config) # ip default-network <dest_network>
o Dest_network คือ Destination network address
ตัวอย่าง
Router (config) # ip route 0.0.0.0 0.0.0.0 172.16.2.1
คำอธิบาย
ip route 0.0.0.0 เป็นการระบุ Static route ไปยังทุก ๆ subnetwork ปลายทาง
0.0.0.0 เป็นการระบุถึงทุก Subnet mask
172.16.2.1 หมายถึง IP address ของ next hop router ที่มีเส้นทางไปยังปลายทางที่ต้องการ
Dynamic Route
Dynamic route เป็นอัลกอริทึมที่ใช้ในการดูแล Routing table และแลกเปลี่ยนข้อมูลระหว่าง Router ที่ต่อเข้าด้วยกัน
Cisco ได้มีการใช้งาน Dynamic routing algorithm อยู่ 3 ชนิดคือ
o Distance Vector (DV) พิจารณาจากระยะทางo
o Link State (LS) พิจารณาจากสถานะของo Link
o Advanced Distance Vector (ADV) หรือ Dynamic Update Algorithm (DUAL) พิจารณาจากระยะทางo พร้อมทั้งo มีการคำนวณเพิ่มเติม ทำให้เกิด fast convergence
ประโยชน์ของ Dynamic routing protocol ก็คือ
- มีการ update อย่างอัตโนมัติ เมื่อโทโพโลยี (Topology) มีการเปลี่ยนแปลงไป
ข้อเสียของ Dynamic routing protocol ก็คือ
- มีการใช้ทรัพยากรมากและการควบคุมการ update เป็นคาบเวลา (Periodical update) ต้องใช้เวลามากกว่า
Class of Routing Protocols
1. Distance Vector
2. Link State
3. Hybrid Routing
1. Distance Vector Routing Protocols
Distance – ไกลเท่าไร Vector – ทิศทางไหน
ในการปรับปรุง Routing table จะทำการปรับปรุงตามคาบเวลา โดย Router แต่ละตัวจะส่งตาราง Routing tableไปยัง Router ข้างเคียง (Neighbor routers) และพิจารณา distance vectors
Router จะทำการค้นหาเส้นทางที่ดีที่สุดที่จะส่งข้อมูลไปยังปลายทางจาก Router ข้างเคียงแต่ละช่วง ซึ่งวิธีการเลือกเส้นทางที่ดีที่สุดจะพิจารณาจาก Metrics ซึ่ง Protocol แต่ละแบบจะพิจารณา Metrics ที่แตกต่างกันไปเช่น
RIP พิจารณา metrics คือ hop count
IPX พิจารณา metrics คือ Ticks และ hop count
IGRP พิจารณา metrics คือ bandwidth, Delay, Load, Reliability, MTU
การดูแลและจัดการ Routing information
มีการ Update อย่างต่อเนื่องเป็น Sep by step จาก Router ตัวหนึ่งไปยัง Router อีกตัวหนึ่ง
ปัญหาที่อาจจะเกิดขึ้นในการ Maintaining Routing Information
ปัญหา Routing loop
มักจะเกิดขึ้นมาจากการที่ Network ปลายทางที่ต้องการส่งผ่านมีจำนวน Hop count เป็น Infinity
วิธีการแก้ไขมีหลายวิธีดังต่อไปนี้
1. Defining a maximum hop ทำการกำหนด Limit จำนวนของ2. hop เพื่อป้อง3. กัน infinite loop
4. ใช้วิธี split horizon ไม่มีความจำเป็นเลยที่จะทำการส่ง5. ข้อมูลเส้นทาง6. กลับมายัง7. เส้นทาง8. เดิมที่ข้อมูลเดินทาง9. ผ่าน
10. Route Poisoning ทำได้โดย Router ทำการกำหนด distance ของ11. routed ที่มีโอกาสเป็น infinity
12. Poison Reverse
13. Hold-down Timers
14. Triggered Updates ตัว Router จะทำการส่ง15. update เมื่อมีการเปลี่ยนแปลง16. ในRouting tables เกิดขึ้น
2. Link State Routing Protocols
ภายหลังจาก Router ทำการ Initial flood แล้ว จะส่งผ่าน small event-triggered link-state updates ไปยัง Router ทุก ๆ ตัว
3. Hybrid Routing
ใช้หลักการผสมผสานระหว่าง Distance vector และ Link-state routing
คำสั่งที่ใช้
Router (config) # router <protocol> [keyword]
o Protocol คือ Routing protocol ที่กำหนดใช้งo าน
Router (config-router) # network <network number>
o Network number คือ หมายเลข network ที่กำหนด
ตัวอย่าง
Router (config) # router rip
คำอธิบาย
กำหนด Routing protocol ที่ใช้งานเป็น RIP
ปัจจัยหลัก (Metric) ในการเลือกเส้นทางที่ดีที่สุด
· Hop count พิจารณาจากจำนวนของ· Router ที่ข้อมูลต้อง· เดินทาง· ผ่านจากต้นทาง· ไปยัง· ปลายทาง·
· Tick พิจารณาจากค่า Delay time หรือค่า Response time ที่เกิดขึ้นในส่วนของ· LAN เช่นของ· IBM อยู่ที่ 50 mS (ค่านี้มักอยู่ในหน่วย mS)
· Bandwidth พิจารณาจาก Bandwidth ของ· เส้นทาง· ที่ข้อมูลเดินทาง· ผ่าน (หน่วยเป็น kbps)
· Delay พิจารณาจากค่า Delay time ที่เกิดขึ้นในส่วนของ· WAN (มีหน่วยเป็น uS)
· Load พิจารณาจากปริมาณของ· ข้อมูลที่ต้อง· การส่ง· มีหน่วยเป็น % ค่า default เป็น [1/255]
· Reliability พิจารณาจากค่าความน่าเชื่อถือของ· ระบบ มีหน่วยเป็น % ค่า default เป็น [255/255]
· MTU พิจารณาจากค่า Maximum Transfer Unit ของ· เครือข่ายแต่ละชนิดเช่น Ethernet LAN มี MTU = 64-1518 bytes หรือ FDDI & token ring มี MTU = 32-4096 byte หากส่ง· ข้อมูลต่ำกว่าค่า minimum MTU จะเรียกว่า Under launch แต่ถ้าสูง· กว่า Maximum MTU จะเรียกว่า Over launch
· Cost พิจารณาจากค่าราคาทั้ง· ที่เป็น Path cost และ Administration cost ค่าโดยประมาณของ· cost ประมาณเท่ากับ BW/1000
Network Protocol Configuring
TCP/IP Configuration
ชุดโปรโตคอลของ TCP/IP (TCP/IP Protocol Stack)
Application layer :
· ตัวอย่าง· เช่น ftp, telnet, smtp, snmp, http, และอื่น ๆ
Transport Layer :
· ตัวอย่าง· เช่น tcp, udp
Network Layer :
· ตัวอย่าง· เช่น IP, ICMP, ARP, Echo, และอื่น ๆ
Data Link Layer :
· ตัวอย่าง· เช่น Ethernet, Token Ring, FDDI, HDLC, PPP และอื่น ๆ
Physical Layer :
· ตัวอย่าง· เช่น Physical Media, UTP, AUI และอื่นๆ

การกำหนด IP address และการแบ่งคลาส (IP Addressing and Classes)
1. Public Class : ใช้เป็นสาธารณะ จัดสรรใช้ง2. านโดยหน่วยง3. าน interNIC
· A – IP address à 1-126
· B – IP address à 128-191
· C – IP address à 192-223
2. Reserved Class : สง3. วนไว้สำหรับ ใช้ทำเป็น Multicast network เป็น Multimedia address
· D – IP address à 224-239
· E – IP address à 240-254
3. Private Class : ใช้ในอง4. ค์กรภายใน
· A – IP address à 10.0.0.0 ถึง· 10.255.255.255
· B – IP address à 172.16.0.0 ถึง· 172.31.255.255
· C – 192.168.0.0 ถึง· 192.168.255.255
Subnet Mask
Default Subnet mask :
· A – 255.0.0.0
· B – 255.255.0.0
· C – 255.255.255.0
Constant Subnet mask :
· สามารถเป็นได้คือ 128, 192, 224, 240, 248, 252, 254, 255
ตัวอย่าง รูปแบบของ Subnet mask :
· Dotted decimal เช่น 10.1.1.1 255.0.0.0
· Bit count เช่น 172.19.1.12/16
· Hexadecimal :192.168.55.4 0xFFFFFF00

การใช้งานคำสั่ง ip address
ในการกำหนด ip address ของอุปกรณ์สามารถทำได้โดยใช้คำสั่ง ip address ดังนี้
Router (config-if)# ip address <ip-address> <subnet-mask>
ip-address ระบุ 32-bits dotted decimal number เช่น 203.151.1.17
subnet-mask ระบุ 32-bits dotted decimal number ที่แสดงถึง subnet เช่น 255.255.255.248
คำสั่ง term ip <netmask-format> ใช้ในการกำหนดรูปแบบของ Network mask ที่จะแสดงให้เห็นด้วย show command ซึ่งรูปแบบของ netmask-format อาจจะเป็น Bit count, Dotted decimal (เป็นค่า Default) และ Hexadecimal
ตัวอย่าง การพิจารณาการออกแบบ Subnet
· สมมุติว่า บริษัทของ· คุณประกอบด้วย 3 แผนก และ17 ส่วนแต่ละแผนกและส่วนจะมี subnet เป็นของ· ตนเอง· โดยแต่ละ subnet ต้อง· การให้มี host อย่าง· น้อย 5 hosts โดยบริษัทได้ทำการ register มีโดเมนเป็น company.com ซึ่ง· InterNIC ได้กำหนดให้เป็น Class C 221.14.98.0 จง· ออกแบบ Subnet mask ให้กับเครือข่ายและเขียนตาราง· address table list
· คำถาม : จำนวน subnet bit ที่ออกแบบมาต้อง· ใช้จำนวนเท่าไหร่จึง· จะได้ตามข้อมูลข้าง· ต้น
· คำตอบ : 5 บิต

Novell / IPX Configuring
Novell / IPX Overview
· IPX address มีขนาด 80 bits อยู่ในรูปแบบเลขฐาน 16 (HEX format) ประกอบด้วย Network.node โดย Network number 32 bits และ Node number ใช้ 48 bits ภายใน node number จะมี MAC address ของ· อินเตอร์เฟสอยู่
· Default Routing – IPX / RIP
· การประกาศการให้บริการ SAP (Service Advertising Protocol) – ทุก ๆ 60 วินาที
· Interface Encapsulation : รูปแบบการ Encapsulate สามารถเลือกทำได้ 4 แบบดัง· นี้
· ARPA – Ethernet II ใช้ได้ Novell netware V 4.0 ขึ้นไป
· SAP – Ethernet 802.2
· SNAP – Ethernet SNAP (Subnetwork Access Point) ใช้กับ FDDI
· Novell- Ether – Ethernet 802.3 ใช้ได้กับ Novell netware V 2.x, 3.1 และ 3.12

คุณสมบัติของ IPX RIP
· Metrics : Ticks (ประมาณ 1/18 sec) and Hop Count.
· อัลกอริทึมที่ใช้ : Link state routing protocol
· Max Hop Count : 15
· Max Path : ค่าปกติคือ 1 (สูง· สุด =64) หมายความว่า ไม่ทำ load balance
· การส่ง· ข้อมูล Update (Sending Update) : 60 วินาที
· Service Adverting protocol (SAP) : มีลักษณะเป็น Broadcast service เป็นการประกาศการให้บริการออกไปยัง· เครือข่าย ทุก ๆ 60 วินาที
· File Service – 4 หมายถึง· การ Map drive
· Print Service – 7
· Get Nearest Server Protocol (GNS) เป็น SAP advertisement แบบหนึ่ง· ที่ช่วยให้ Client ทำการ Login ไปยัง· Server ที่ใกล้ที่สุดได้
· GNS Client and GNS Server

IPX RIP Routing configuration
· Router (config)#ipx routing[node] คำสั่ง· นี้ ใช้ในการสั่ง· Enable Novell IPX routing และเริ่มกระบวนการ Routing process
· Router (config)#ipx maximum-paths <path> ใช้สำหรับการ configure Round-robin load sharing ค่า Default คือ 1 ค่าสูง· สุดคือ 512
Ex : Router (config)#ipx maximum-paths 2 (หมายถึง การยินยอมให้มีการทำ Load sharing ไปในเส้นทางที่ขนานกันไปยังปลายทาง โดยกำหนดให้เส้นทางที่ขนานกันนั้นจำกัดอยู่ที่ 2 เส้นทาง)
· Router (config)#interface <type> <slot#/port#>
Ex : Router (config)#interface ethernet 0
· Router (config-if)#ipx network <net#> encapsulation <encap> [secondary] ใช้ในการกำหนด Primary and secondary network number and encapsulation
<net#> คือ ระบุหมายเลขของ Network number อยู่ในรูปเลขฐาน 16 จำนวน 8 หลัก
<encap> คือ ระบุชนิดของการ encapsulate ของอินเตอร์เฟส โดยสามารถระบุได้เป็น novell-ether, sap, arpa หรือ snap
[secondary] คือการระบุ Network number และ encapsulate อื่น ๆ
Ex : Router (config-if)#ipx network 9e encapsulation novell-ether (หมายเลข 9e คือการกำหนด Network number และทำการระบุ Frame format ที่ใช้กับ Network segment นี้ โดยในที่นี้กำหนดให้เป็นNovell’s terminology ที่เป็น Ethernet_802.3)
Ex : Router (config-if)#ipx network 6c encapsulation sap secondary (หมายเลข 6c คือการกำหนด Secondary Network number และทำการระบุ Frame format ที่ใช้กับ Network segment นี้ โดยในที่นี้กำหนดให้เป็นNovell’s terminology ที่เป็น Ethernet_802.2 ซึ่งมีชนิดของเฟรมเป็น Ethernet 802.3 ที่รวม 802.2 LLC อยู่ภายใน)
· Router (config-if)#end จบจากการ config interface
· Router (config)#exit ออกไปยัง· โหมดหลัก
· Router #

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show ipx interface แสดง· พารามิเตอร์และสถานะต่าง· ๆ ของ· อินเตอร์เฟสที่ใช้ง· าน IPX
· Router #show ipx route แสดง· เส้นทาง· ของ· Routing table
· Router #show ipx severs ดูว่ามี Server ใดให้บริการอยู่บ้าง· รวมทั้ง· รายละเอียดเพิ่มเติมอื่นๆ
· Router #show ipx traffic แสดง· Traffic ที่วิ่ง· ในเครือข่าย ทั้ง· จำนวนและชนิดของ· packets ที่อยู่ในเครือข่าย
· Troubleshooting
· Router #debug ipx routing activity ใช้แสดง· ข้อมูลเกี่ยวกับ RIP update packets
· Router #debug ipx sap activity ใช้แสดง· ข้อมูลเกี่ยวกับ SAP update packets
· Router #ping ipx <destination>

DECnet Configuring
DEC เบื้องต้น
· DEC เป็นโปรโตคอล ที่ออกแบบมาโดยบริษัท Digital Equipment Corporation (DEC proprietary)
· DEC มี Address 16 บิท อยู่ในรูปแบบเลขฐานสิบ (Area.Node) โดยเป็น Area 6 บิท (มี Area สูง· สุดทั้ง· หมด 63 maximum areas) และเป็น Node 10 บิท (มีโหนดสูง· สุดทั้ง· หมด 1023 maximum areas) ตัวอย่าง· เช่น 10.2 หรือ 20.2
· โหนดถูกจัดกลุ่มรวมกันเป็น Area
· ไม่มี Broadcast advertising protocol
· ใช้วิธีการ Routing ด้วย DECnet routing
· มี Modified MAC address หมายถึง· DECnet NAC address หรือ Bern in address(bia) เช่น 0006.533C.7200

คุณสมบัติของ DECnet
· Metrics : Cost
· ใช้อัลกอริทึมเป็นแบบ Distance vector protocol
· ใช้ address เดียวในการแทนอุปกรณ์ 1 ตัว
· ใช้ hello protocol ในการ update ข้อมูล Routing information โดย Routersและ end nodes ทำการประกาศสถานะภาพปัจจุบันด้วย Hello messages
· ชนิดของ· การ Routing :
· Inter Area – Level 2 (ระหว่าง· Areas)
· Intra Area – Level 1 (ภายใน Area เดียวกัน) (กำหนดเป็น Enableโดยค่า Default)
· ใช้ Routing protocol คือ DECnet
· การส่ง· ข้อมูล Update (Sending Update) : ทุก ๆ 40 วินาที

DECnet configuration
· Router (config)#decnet routing<address> (address ที่ระบุคือ DECnet address)
· Router (config)#decnet node-type <type>
· Router (config)#interface <type> <slot#/port#>
· Router (config-if)#decnet cost <cost>
· DECnet Address :
· Area.Node – 6.10 (รวม 16 bit)
· DECnet type :
· Routing-iv (L1) เป็นค่า Default
· Area (L2)
· DECnet cost :
· Admin cost assigned

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show decnet interface ใช้ในการแสดง· สถานะต่าง· ๆ เกี่ยวกับ DECnet interfaces รวมทั้ง· Line status, timers, access lists assigned เป็นต้น
· Router #show decnet route ใช้ในการแสดง· รายละเอียดภายใน DECnet routing table
· Router #show decnet traffic ใช้ในการแสดง· ปริมาณ traffic ที่มายัง· Router
· Troubleshooting
· Router #debug decnet routing ใช้ในการแสดง· Routing update messages
· Router #debug decnet activity
· Router #debug ipx decnet event
· Router #ping decnet <destination>

Module 4 : TCP/IP Routing Protocol
Routing Information Protocol (RIP)
TCP/IP Dynamic Routing Protocols
คุณสมบัติของ RIP
· RIP protocol มีข้อกำหนดอยู่ใน RFC 1058
· Metrics : ใช้ Hop count ในการเลือกเส้นทาง· โดยมีค่าสูง· สุดคือ 15 ดัง· นั้นเหมาะกับเครือข่ายขนาดเล็ก มี Router ไม่เกิน 15 ตัว
· อัลกอริทึมที่ใช้ : Distance Vector Algorithm
· การส่ง· ข้อมูล Update (Sending Update) : ทุก ๆ 30 วินาที (หมายถึง· การส่ง· ข้อมูล table ให้เครื่อง· ข้าง· เคียง· ทุก ๆ 30 วินาที)
· Load Balanced : ค่า Default คือ 4 (สูง· สุดคือ 6)
· Version : RIPv1 = Classful (หมายถึง· รู้จัก Subnet mask ที่เป็น 8, 16 และ 24 บิทเท่านั้น), RIPv2 = Classless (หมายถึง· ไม่สนใจ class ใช้ VLSM(Variable Length Subnet mask)
· Distance : ค่า Default คือ 120
· Invalid After : 180 วินาที
· Hold Down Timer : 180 วินาที
· Flushed After : 240 seconds


· Standard RIP
มีคำสั่งดังนี้
· Router (config)#router rip (เริ่มใช้ RIP routing process)
· Router (config-router)#version <ver#> (กำหนดการใช้ rip version ใด)
· Router (config-router)#network <net#> กำหนด Network address ที่ WAN port ของ· Router
คำสั่ง router rip เป็นการเลือกใช้ RIP เป็น Routing protocol
คำสั่ง Network ใช้ในการกำหนด NIC-based address ของ Router ที่จะนำไปเชื่อมต่อโดยตรง กระบวนการเลือกเส้นทาง (Routing process) จะเกี่ยวข้องกับ interface และ addresses และจะทำการประมวลผล Packet ที่อยู่ในเครือข่ายที่กำหนด
ตัวอย่าง
Router (config)#router rip (เริ่มใช้ RIP routing process)
Router (config-router)#network 172.16.0.0
Router (config-router)#network 10.0.0.0
คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show ip protocol
เป็นคำสั่งที่ใช้ในการแสดงค่าเกี่ยวกับ Router timers และข้อมูลเครือข่ายซึ่งเกี่ยวข้องกับ router นั้น
· Router #show ip route
เป็นคำสั่งที่ใช้แสดงรายการของ IP routing table ซึ่งภายใน Routing table จะมีรายการของ Networks และ Subnetworks ที่ Router รู้จัก รวมทั้งมี Code ที่แสดงถึงวิธีการที่ Router นั้นทำการเรียนรู้เส้นทาง เช่น Code R หมายถึง ใช้ RIP protocol หรือ Code B หมายถึงใช้ BGP protocol เป็นต้น
· Troubleshooting
· Router #debug ip rip จะแสดง· ข้อมูลการปฏิบัติการของ· RIP เช่นการส่ง· sending update ฯลฯ

Interior Gateway Routing Protocol (IGRP)
คุณสมบัติของ IGRP
· Metrics : Bandwidth และ delay
· Hop count : ค่า Default คือ 100 (สูง· สุดคือ 255)
· อัลกอริทึม : Distance Vector Algorithm
· การส่ง· ข้อมูล Update (Sending Update) : ทุก ๆ 90 วินาที
· Load Balanced : ค่า Default คือ 4 (สูง· สุดคือ 6)
· IGRP Metric weight : K1=1, K2=0,K3=1,K4=0,K5=0
· Distance : ค่า Default คือ 100
· Invalid After : 270 วินาที
· Hold Down Timer : 280 วินาที
· Flushed After : 630 seconds

· Cisco’s proprietary IGRP
ข้อดีคือ มี Scalable สูงกว่า RIP
-ใช้ Sophisticated metric ได้แก่ Bandwidth, Delay, Reliability, Loading และ MTU
- Multiple-path support
· Router (config) # router igrp <as#>
· Router (config-router) # network <net#> กำหนด Network address ที่ WAN port ของ· Router
· Router (config-router) # variance <multiplier> (คำสั่ง· นี้ใช้ในการควบคุมการทำ Load balance กรณี multiplier เป็น 1 คือไม่เป็น Load balance)
· Router (config-router) # traffic share <?> เป็นการ share traffic
· AS# -Autonomous System number (1-65536)

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show ip protocol
· Router #show ip route
· Troubleshooting
· Router #debug ip igrp transaction จะแสดง· ข้อมูลการปฏิบัติการของ· IGRP เช่นการส่ง· sending update ฯลฯ
· Router #debug ip igrp events

การจัดการเรื่องความปลอดภัยและ Traffics ด้วย ACL
Access Control list Overview
ทำไมต้องมีการใช้ Access Lists
o เพื่อจัดการ IP traffic ตามการเติบโตของo เครือข่าย
o เพื่อกรองo Packet ที่ส่งo ผ่าน Router
· Standard ACL :
· ทำการ Match source address ของ· Packet
· Extended ACL :
· ทำการ Match source และ destination ของ· Packet
· ทำการ Match โปรโตคอลแบบอื่น ๆ
· ACL Process :
· Inbound – ตรวจสอบ Incoming packets กับ ACL และทำการ Route ออกไปยัง· Outgoing interface
· Outbound – ส่ง· ผ่าน Incoming packets ไปยัง· Outgoing interface ก่อน แล้วจึง· ตรวจสอบกับ ACL ในภายหลัง·
· Test Condition :
· Permit – ยินยอมให้มีการส่ง· Packets และทำการส่ง· ไปยัง· Process ต่อไป
· Deny – ไม่ยินยอมให้มีการส่ง· Packets และทำการ Drop out ออกจาก Process
· จะมี Implicit Deny All ที่ท้ายบรรทัดเสมอ
· ACL จะมีการทำง· านตามลำดับและไม่สามารถใส่เข้าไป หรือเรียง· ใหม่ได้
· ใน IOS release 12.0 สามารถที่จะระบุ ACL name ได้
· Standard ACL จะใส่ที่ปลายทาง·
· Extended ACL จะใส่ที่ต้นทาง·
· Test condition ทำได้โดยการใช้ Wildcard bit mask
· สามารถใช้คำว่า “any” สำหรับ 0.0.0.0 255.255.255.255
· สามารถใช้คำว่า “host” สำหรับตรวจสอบ address bits ทั้ง· หมด
· Wildcard mask : 0’s condition match หมายถึง· ต้อง· ตรวจสอบ address bit, 1’s don’t care หมายถึง· ไม่ต้อง· ตรวจสอบ address bit
· ในการ Verifying ACLใช้คำสั่ง· :
- Router#show access-list
ACL Configuration
· Router (config)#access-list <list#> <condition> <test condition>
· Router (config-if)#access-group <list#> <process>
· List# :
· Standard IP- 1-99
· Extended IP- 100-199
· Standard IPX- 800-899
· Extended IPX- 900-999
· SAP IPX –1000-1099
· Condition
· Permit
· Deny
· Process
· In
· Out (Default)
ขั้นตอนที่ 1 กำหนดพารามิเตอร์ สำหรับ access list test statement (ซึ่งอาจจะมีเพียงหนึ่งหรือหลายๆ Statements)
· Router (config)#access-list <list#> <condition> <test condition>
ขั้นตอนที่ 2 กำหนดให้ Interface ใช้ access list ที่ระบุ
· Router (config-if)#access-group <list#> <process>
ตัวอย่างการกำหนด Standard IP access list configuration
· Router (config)#access-list <list#> <condition> <test condition>
· List# :
· Standard IP- 1-99
· Default wildcard mask คือ 0.0.0.0
· Condition
· Permit
· Deny
· Router (config-if)#access-group <list#> <process>
· Process
· In
· Out (Default)
ตัวอย่างการกำหนด Extended IP access list configuration
· Router (config)#access-list <list#> <condition> <test condition>
· List# :
· Extended IP- 100-199
· Default wildcard mask คือ 0.0.0.0
· Condition
· Permit
· Deny
· Router (config-if)#access-group <list#> <process>
· Process
· In
· Out (Default)

Module 5 : Wide Area Network
CISCO’s Serial Line Options
Serial Line Options
· Cisco’s Serial Interface Options :
· Multiple Encapsulation
· Canalized or Sub Interface
· Compression
· Cisco’s Serial Encapsulation:
· ค่าโดย Default คือ กำหนดให้เป็น High Level Data Link Connection Protocol (HDLC)
HDLC Configuring
· HDLC เป็น Cisco’s Proprietary
· Router (config)#interface serial <slot#/port#>
· Router (config-if)#encapsulation hdlc
· หมายเหตุ :
· HDLC encapsulation ไม่แสดง· ใน Configuration file
คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show interface serial <slot#/port#>
· Troubleshooting
· Router #debug serial interface

คุณสมบัติของ PPP
· PPP ทำง· านจาก 2 Layers –LCP และ NCP
· LCP Options:
· Authentication
· Compression
· Error Detection
· MultiLink
· PPP เป็น โปรโตคอลมาตรฐาน

PPP Configuring
· PPP Configuration
· Router (config)#hostname <name>
· Router (config)#username <name> password <string>
· Router (config)#
· Router (config)#interface serial <slot#/port#>
· Router (config-if)#encapsulation ppp
· Router (config-if)#ppp authentication <type> (type มีให้เลืแก 2 อย่าง· คือ PAP (Password Authentication Protocol) และ CHAP (Challenge Handshake Authentication Protocol)
คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show interface serial <type#/port#>
· Router #show running-configuration
· Troubleshooting
· Router #debug ppp authentication
· Router #debug ppp negotiate
· Router #debug ppp packet

X.25 protocol configuring
X.25 Overview
· X.25 ทำง· านเป็นแบบ Connection oriented, โดยใช้โปรโตคอล NBMA(Non-Broadcast Multi Access protocol)
· X.25 อาศัยหลักการของ· Packet Switching
· X.25 ทำง· านด้วย Virtual Connections ทั้ง· แบบ PVC และ SVC
· PAD คือ Packet Assembly/Disassembly
· Cisco’s Router สามารถทำการ Configure ให้เป็นได้ทั้ง· อุปกรณ์ DTE หรือ DCE
· มาตรฐาน X Series ที่เกี่ยวข้อง·
· X.121 -X.25 Addressing
· X.400 –E-Mail gateway
· Etc.
X.25 Characteristics
· X.121 Address :
· DNIC – 4 decimal digits
· NTN – 10 ถึง· 11 decimal digits
· X.25 ใช้ LAP-B (Link Access Protocol-B) เป็น Data link protocol เพื่อ Negotiate Virtual Connection
· X.25 protocol มีการกำหนดพารามิเตอร์ต่าง· ๆ มากมาย
· สามารถสร้าง· VC ได้ทั้ง· หมด 4095 VCs ทั้ง· PVC และ SVC
· สามารถทำการ Configure SVC ให้รอง· รับ Single หรือ Multiple protocol ได้ในแต่ละ VCs
· สามารถ Configure สำหรับ Sub interfaces

X.25 Configuring
· Router (config)#interface serial <slot#/port#>
· Router (config-if)#encapsulate x25 <type> (type อาจจะเป็น DCE หรือ DTE ก็ได้)
· Router (config-if)#x25 address <x121>
· Router (config-if)#ip address <ip> <mask>
· Router (config-if)#x25 map <protocol> <address> <x121> [option]
· Router (config-if)#x25 <?>

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show x25 map
· Router #show x25 vc <vc#>
· Router #show x25 route
· Router #show interface serial <slot#/port#>
· Router #show running-config
· Troubleshooting
· Router #debug x25 activity
· Router #debug x25 event
· Router #ping <destination>

Frame Relay configuring
Frame Relay Overview
· Frame relay เป็นมาตรฐานของ· ITU-T และ ANSI
· Frame Relay เป็น layer 2 Equivalent WAN protocol
· Frame Relay ทำง· านเป็นแบบ Connection oriented
· Frame Relay อาศัยหลักการของ· Packet Switching และ NBMA protocol (Nonbroadcast Multiaccess Protocol)
· Frame Relay ใช้หลักการพื้นฐานอยู่บน Virtual connection หรือ Virtual Circuit (VC)
· Virtual Connection :
· Permanent Virtual Circuit (PVC) – Static
· Switch Virtual Circuit (SVC) – Dynamic
· Frame Relay ทำง· านอยู่บน Permanent virtual circuits ซึ่ง· หมายความว่า การเชื่อมต่อเป็นแบบ Statistics ซึ่ง· เราสามารถทำการ Provisioning ได้โดยการกำหนด Configuration
· ตัวที่ใช้ระบุภายในแต่ละ PVC คือ DLCI (Data-link connection identifier)
· สามารถทำการ Configure ได้สูง· สุด 4095 VCs ต่อ Sub interface
· Sub interface สามารถ configured ให้เป็นแบบ point to point และ point to multipoint

Frame Relay Parameters
· Local Access Rate
· Data link Connection identifier (DLCI)
· Local Management Interface (LMI)
· Inverse ARP ทำหน้าที่ map IPไปเข้า DLCI
· Committed information Rate (CIR)
· Forward Explicit Congestion Notification (FECN)
· Backward Explicit Congestion Notification (BECN)

Local Management Interface (LMI)
· Cisco’s LMI :
· Cisco เป็น Proprietary
· Anex-A ; Q933 กำหนดโดย ITU-T
· Anex-D : T1.617 กำหนดโดย ANSI
· LMI Status :
· Active – VC สามารถ initiated และส่ง· ข้อมูลข้ามไปได้
· Inactive - VC ไม่สามารถ initiated และส่ง· ข้อมูลข้ามไปได้
· Deleted – Frame Relay Switch ไม่ support

Frame Relay Configuring
· Router (config)#frame-relay switching
· Router (config)#interface serial <slot#/port#>
· Router (config-if)#ip address <ip> <netmask>
· Router (config-if)#encapsulation frame-relay [ietf] ใช้ในการกำหนด encapsulation type ที่จะใช้ใน Serial interface ที่จะต่อเข้ากับ Frame relay network กำหนดได้ 2 แบบคือ Default เป็นแบบ Cisco encapsulation ใช้ได้กับ Router ยี่ห้อ Cisco ด้วยกันเท่านั้น
· Router (config-if)#bandwidth <kbps>
· Router (config-if)#frame-relay lmi-type <type>
· Router (config-if)#frame-repay map <protocol> <address> <dlci> [option] (address คือ IP address ของ· อุปกรณ์ฝั่ง· ตรง· ข้าม, dlci คือ หมายเลข dlci ฝั่ง· ตรง· ข้าม)
· Router (config-if)#frame-relay intf-type <type>
· Router (config-if)#frame-relay interface-dlci <dlci> ใช้ในการกำหนด DLCI ที่ใช้ง· าน
· Router (config-if)# no shutdown
· Router (config-if)#end
· Router (config)#exit
· Router)#

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show interface serial <slot#/port#>
· Router #show running-config
· Router #show frame-relay map
· Router #show frame-relay pvc <pvc#>
· Router #show frame-relay lmi
Troubleshooting
· Router #debug frame-relay lmi
· Router #ping <destination>

ISDN Configuring
ISDN overview
· ISDN interface Type :
· Basic Rate Interface (BRI) - 2B+D
· Primary Rate Interface (PRI) – 23/30B+D
· Channel Capacity :
· B- 64 kbps สำหรับส่ง· สัญ· ญ· าณ Voice และ Data (HDLC,PPP)
· D- 16/64 kbps สำหรับส่ง· สัญ· ญ· าณ Signal controlling (LAPD)
· ISDN เป็นมาตรฐานของ· ITU-T standard
· E-series กล่าวถึง· วิธีการกำหนด Address
· I-series กล่าวถึง· ทฤษฎีของ· ISDN และหลักการของ· ISDN
· Q-series กล่าวถึง· วิธีการใช้ง· าน Signaling
· Protocol : PPP หรือ HDLC
· ISDN switch type : ขึ้นอยู่กับชนิดของ· สัญ· ญ· าณ
· ISDN Switch WAN : ใช้เป็นแบบ Circuit Switching

ISDN Reference point and Devices
· Terminal Equipment-Type I (TE1)
· Terminal Equipment-Type II (TE2)
· Network Termination 2 (NT2)
· Network Termination 1 (NT1)
· Reference Signal Point :
· R/S
· T
· U

ISDN BRI Configuring
· Router (config)#isdn switch-type <switch> กำหนดชนิดของ· ISDN switch
· Router (config)#interface bri <slot#/port#>
· Router (config-if)# isdn switch-type <switch> กำหนดชนิดของ· ISDN switch ที่ต่อกับอินเตอร์เฟสของ· Router
· Router (config-if)#isdn spid1 <spid#1> เป็น Option เพื่อให้ใช้ได้กับ Service provider หลาย ๆ ราย
· Router (config-if)#isdn spid2 <spid#2>เป็น Option เพื่อให้ใช้ได้กับ Service provider หลาย ๆ ราย
· Router (config-if)#encapsulation <encap> กำหนดวิธีการ Encapsulate
· Router (config-if)#ip address <ip> <mask> กำหนด ip addressและ Netmask
· Router (config-if)#end
· Router (config)#exit
· Router)#

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show isdn active
· Router #show interface bri <slot#/port#>
· Router #show isdn status
· Router #show ip route
Troubleshooting
· Router #debug isdn q921
· Router #debug isdn q931
· Router #debug dialer
· Router #debug ppp authentication
· Router #debug ppp negotiate
· Router #ping <destination>
· Router #trace <destination>
· Router #telnet <destination>

Module 6 : Bridging protocol
Bridging Concept
Bridging overview
· Bridge เป็นอุปกรณ์ในเครือข่ายที่ทำหน้าที่ส่ง· ผ่าน Frame ข้ามไปยัง· segment อื่น
· Bridge ทำง· านที่ระดับ layer 2 ของ· OSI
· Bridge เป็นอุปกรณ์ที่ทำง· านขึ้นอยู่กับโปรโตคอลแต่ไม่ขึ้นกับ media
· ใช้ Bridging software technology
· หน้าที่หลักของ· Bridge :
· ทำการ Learning Frame (Transparent)
· Forwarding and Filtering Frame
· หลีกเลี่ยง· การเกิด Loop โดยใช้ Spanning Tree Algorithm (STA) (ดูข้อมูล STA เพิ่มเติมจาก IEEE 802.1d)

คุณสมบัติของ Bridge
· ใช้กับ Non-routed protocolเช่น LAT (ของ· DEC), SNA(Simple Network Architecture), NetBIOS, NetBEUI ฯลฯ
· Spanning-Tree Protocol (IEEE 802.1D) :
· Network หนึ่ง· สามารถมีได้ 1 Root Bridge
· Segment หนึ่ง· สามารถมีได้ 1 Designed Port
· Root port หนึ่ง· สามารถอยู่บน 1 Non-Root Bridge
· Bridge ใช้ BPDU (Bridge Protocol Data Unit) ในการจัดการและดูแล Bridge configuration message ระหว่าง· กัน โดยส่ง· ทุก ๆ 2 วินาที
· Spanning-Tree Protocol Transition State :
· Blocking à listening à Learning à Forwarding
· รวมเวลาทั้ง· หมด 50 วินาที = 20 à 15 à 15

Transparent Bridging configuring
· Bridge(config)#bridge-group <bg> protocol <protocol> (protocol ที่เลือกได้คือ IEEE, DEC, IBM)
· Bridge(config)#interface <type> <slot#/port#>
· Bridge(config-if)#bridge-group <bg>

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show running-config
· Router #show bridge <bg>
· Router #show spantree
Troubleshooting
· Router #debug bridge activity
· Router #debug spantree

Module 7 : Scaleable Routing Protocol and Traffic Management
Enhanced IGRP Configuring
· EIGRP เป็น Cisco’s proprietary
· EIGRP ใช้อัลกอริทึมเป็นแบบ Advanced Distance Vector algorithm โดยการใช้อัลกอริทึมแบบ DUAL (Dynamic Update Algorithm)
· EIGRP ใช้ integrated multi-protocol routing table ที่มีการรวม metrics ระหว่าง· โปรโตคอล
· Combine Metrics :
· Bandwidth
· Delay
· Load
· Reliability
· MTU

· Shift-In-Night – integrates with IP,IPX และ Appletalk
· EIGRP package types :
· Hello; Update; Query; Rply; ACK


Open Shortest Path first Configuring
OSPF Overview
· OSPF เป็น Dynamic routing protocol ที่มีการใช้ง· าน Link State Algoithm
· OSPF ใช้หลักการของ· Area border concept เพื่อทำการแบ่ง· เครือข่ายขนาดใหญ· ่ให้เป็นเครือข่ายย่อย ๆ
· ใช้ Link State Advertising Packet ในการ Update ข้อมูล Routing information
· ทำง· านร่วมกับ OSPF process ID
· OSPF network topologies :
· Broadcast Multi Access (BMA)
· Point to Point (P-P)
· Non Broadcast Multi Access (NBMA)
· มี Backbone (Area0) อยู่เพียง· Area เดียว และมีหลาย ๆ border areas
· OSPF เป็น Standard routing protocol และ Interoperate vender
· OSPF สามารถใช้ route summarization
· OSPF สามารถใช้ reach ค่าของ· VLSM addressing

OSPF Configuring
· Router (config)#router ospf <id>
· Router (config-router)#network <net#> <wildcard> area <area#>
· Router (config-router)#area <area> virtual-link <router-id>
· Router (config)#interface <type> <slot#/port#>
· Router (config-if)#ip ospf cost <cost>
· Router (config-if)#ip ospf network non-broadcast
· Router (config-if)#ip ospf network point-to-multipoint [option]
· Router (config-if)#
คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show ip route
· Router #show ip protocol
· Router #show ip ospf <process-id>
· Router #show ip ospf border-router
· Router #show ip ospf interface
· Router #show ip ospf database
· Router #show ip ospf neighbor detail
· Router #show ip ospf virtual-links
Troubleshooting
· Router #clear ip route *
· Router #debug ip ospf <option>
· Router #ping <destination>

Border Gateway Protocol Configuring
BGP Overview
· BGP เป็น Standard routing protocol ที่มีการใช้ง· าน Advanced Distance Vector Algorithm
· EGP เป็น Exterior Gateway Protocol ใช้ง· านทดแทน BGP V.4
· BGP เป็นโปรโตคอลที่ใช้เชื่อมต่อระหว่าง· Autonomous System
· ชนิดของ· BGP :
· Internal BGP (IGP) – เป็น BGP session ภายใน AS
· External BGP (EGP) – เป็น BGP session ระหว่าง· AS
· BGP ใช้ metric ที่สมบูรณ์มากรวมทั้ง· Called Attribute

BGP Configuring
· Router (config)#ip prefix-list <list#> <condotion> <test>
· Router (config)#router bgp <AS#>
· Router (config-router)#network <net#> <mask>
· Router (config-router)#neighbor <neighbor> remote-as <remote AS#>
· Router (config-router)#neighbor <neighbor> next-hop-self
· Router (config-router)#no synchronization
· Router (config-router)#aggregate-address <ip> <mask> [option]
· Router (config-router)#neighbor <ip> router-reflector-client
· Router (config-router)#neighbor <ip> prefix-list <list#> <process>
· Router (config-router)#neighbor <ip> weight <weight>
· Router (config-router)#bgp default locol-preference
· Router (config-router)#redistribute <protocol>

คำสั่งที่ใช้ในการ Monitoring และ Troubleshooting
· Monitoring
· Router #show ip bgp
· Router #show ip bgp summary
· Router #show ip bgp neighbors
· Router #show ip prefix-list detail
· Router #show running-config
Troubleshooting
· Router #clear ip bgp [option]
· Router #clear ip bgp summary
· Router #debug ip bgp update
· Router #ping <destination>

2 ความคิดเห็น: