I/ Giới thiệu: - DHCP snooping là một tính năng cho phép Aruba Mobility Switch được giám sát gói tin DHCP đi qua các cổng switch port của nó. - Có thể sử dụng trong các trường hợp: · Có thể được sự dụng cho việc tshoot các sự cố về việc phân bố địa chỉ IP. · Hỗ trợ các tính năng bảo mật như IP source Guard và kiểm tra Dynamic ARP. - Tính năng này chạy trên tất cả các sản phẩm Aruba Mobility Switche cùng phiên bản firmware 7.3 và mới hơn. II/ Các bước cấu hình: Bước 1. Tạo 1 profile dhcp-snooping động: tên theGioimang - DHCP-Snooping động là việc Switch sẽ tự học thông tin MAC và IP của DHCP Server trong lần đầu tiên nhận gói tin DHCP sau khi cấu hình. (ArubaS2500) #configure t (ArubaS2500) (config) #vlan-profile dhcp-snooping-profile theGioimang (ArubaS2500) (dhcp-snooping-profile "theGioimang") #enable (ArubaS2500) (dhcp-snooping-profile "theGioimang") #exit - Để show profile dùng lệnh: (ArubaS2500) (config) #show vlan-profile dhcp-snooping-profile theGioimang dhcp-snooping-profile " theGioimang" --------------------------- Parameter Value --------- ----- DHCP Snooping Enabled Bước 2. Thêm tính năng trên 1 VLAN: (ArubaS2500) (config) #vlan 1 (ArubaS2500) (VLAN "1") #dhcp-snooping-profile theGioimang (ArubaS2500) (VLAN "1") #exit - Lưu ý: Khi profile DHCP snooping được gắn vào trong "vlan 1". Trên cổng interface của vlan 1, chúng ta không còn option cho dhcp snooping nữa: (ArubaS2500) #configure t Enter Configuration commands, one per line. End with CNTL/Z (ArubaS2500) (config) #interface vlan 1 -------------> lệnh command không còn khả dụng ở đây (ArubaS2500) (vlan "1") #? clone Copy data from another vlan description Interface description dhcp-relay-profile Apply DHCP relay profile to interface igmp-profile Apply IGMP profile to interface ip Interface internet protocol commands ipv6 Interface internet protocol v6 commands mtu Set MTU on interface between 1400 and 1570 no Delete Command ospf-profile Apply OSPF profile to interface pim-profile Apply PIM profile to interface session-processing Enable session processing on this interface shutdown Enable or disable interface vrrp-profile Apply VRRP profile to interface(ArubaS2500) (vlan "1") # (ArubaS2500) (vlan "1") #exit (ArubaS2500) (config) # (ArubaS2500) (config) #vlan 1 -------------------------> lệnh command có thể sử dụng (ArubaS2500) (VLAN "1") #? aaa-profile VLAN AAA profile clone Copy data from another VLAN description VLAN description dhcp-snooping-database Add Static Snoop mac entry dhcp-snooping-profile dhcp snooping profile name igmp-snooping-profile igmp snooping profile name mac-address-table Configure the MAC address table mac-aging-time Mac Aging Time in Minutes mld-snooping-profile mld snooping profile name no Delete Command pvst-profile per vlan rapid spanning tree profile name Bước 3. Chúng ta cũng có thể nhập cấu hình bảng DHCP snooping bằng tay, lúc này trong sẽ hiện là Static entry: (ArubaS2500) (config) #vlan 1 (ArubaS2500) (VLAN "1") #dhcp-snooping-database 0A:C7:82:15:9C:01 gigabitethernet 0/0/20 10.1.1.100 (ArubaS2500) (VLAN "1") #exit (ArubaS2500) (config) #exit (ArubaS2500) #show dhcp-snooping-database Total DHCP Snoop Entries : 2 Learnt Entries : 1, Static Entries : 1 DHCP Snoop Table ---------------- MAC IP BINDING-STATE LEASE-TIME VLAN-ID INTERFACE --- -- ------------- ---------- ------- --------- 0A:C7:82:15:9C:01 10.1.1.100 Static entry No lease time 1 gigabitethernet0/0/20 f0:1f:af:52:44:09 10.1.1.251 Dynamic entry 2013-12-28 19:33:01 (PST) 1 gigabitethernet0/0/20 (ArubaS2500) # - Lệnh Để xóa một DHCP Snooping tĩnh: (ArubaS2500) #configure terminal Enter Configuration commands, one per line. End with CNTL/Z (ArubaS2500) (config) #vlan 1 (ArubaS2500) (VLAN "1") #no dhcp-snooping-database 0A:C7:82:15:9C:01 gigabitethernet 0/0/20 10.1.1.100 (ArubaS2500) (VLAN "1") #no dhcp-snooping-database f0:1f:af:52:44:09 gigabitethernet 0/0/20 10.1.1.251Error: Static DHCP Snoop entry doesn't exist. - Dòng lỗi sẽ xuất hiện khi bạn xóa vào Profile DHCP-Snooping động. Sau đó tiến hành kiểm tra. (ArubaS2500) (config) #show dhcp-snooping-database ---------------- MAC IP BINDING-STATE LEASE-TIME VLAN-ID INTERFACE --- -- ------------- ---------- ------- --------- f0:1f:af:52:44:09 10.1.1.251 Dynamic entry 2013-12-28 19:33:01 (PST) 1 gigabitethernet0/0/20 !!Lưu ý: Chúng ta chỉ có thể xóa bỏ trong bảng DHCP Snooping cấu hình tĩnh chứ không phải profile động đã được học. II/ Troubleshoot: - Để đảm báo tính năng DHCP snooping làm việc đúng: 1. Kiểm tra xem client đang sử dụng IP cấp từ DHCP Server. 2. Đảm bảo rằng port cắm đúng vào VLAN. 3. Kiểm tra lại Vlan có DHCP snooping profile được gắn đúng không.