接口(對于工作站就是缺省網關),當1條上聯鏈路失效時,數據必然會從另 外1條鏈路傳輸到另外一臺交換機上進行處理,這時就存在缺省網關變更的問題。 為了消除當一條鏈路失效導致的工作站缺省網關重新定義的問題,我們使用Cisco公 司專有HSRP(Hot Standby Redundant PRotocol)技術來解決這個問題。 HSRP技術就是將分布在2臺交換機上相同網段的不同路由接口ip地址映射為一個虛 擬IP地址來消除工作站缺省網關重新定義的問題。配置如下: 在其中一臺65xx上按下面模版進行配置 interface Vlan x ip address x.x.x.x x.x.x.x no ip redirects no ip directed-broadcast standby 1 ip y.y.y.y standby 1 priority 100 standby 1 preempt standby 1 authentication secret
在另一臺65xx上按下面模版進行配置 interface Vlan x ip address x.x.x.x x.x.x.x no ip redirects no ip directed-broadcast standby 1 ip y.y.y.y standby 1 priority 110 ;這個優先級高,成為Master standby 1 preempt standby 1 authentication secret
7. 配置NTP NTP (Network Time Protocol) 為路由器、交換機和工作站之間提供了一種時間同步 的機制。時間同步了,多臺網絡設備上的相關事件記錄可以放在一起看,更為清楚, 方便了分析較復雜的故障和安全事件等。 (1)本地時鐘設置: clock timezone Peking +8 ;定義時區 clock calendar-valid ;答應使用硬件calendar作為時鐘源 clock set hh:mm:ss month year ;如clock set 14:02:30 10 December 2003 clock update-calendar ;更新硬件時鐘 (2)ntp server ntp calendar-update ;答應NTP定期更新calendar ntp master 3 ;答應本機作為NTP協議的主時鐘,精度級別3,供其它對等體同步用。 ntp source int vlan 7 ;設置ntp時鐘原的端口或IP地址 (3)常用的調試命令有: show ntp status show ntp associations 8. 配置鏡像端口 在交換機上配置鏡像端口(Mirroring Port)用于建立內部網絡的監控端口,以便收 集相關被監測端口的數據流量,進行數據流監控及分析。我們這里配置鏡像端口用于 配置入侵檢測設備(鏡像端口)的檢測口檢測一級防火墻和二級防火墻的內網接口, 以探測是否有入侵行為發生。 #monitor session 1 source interface Fa7/14 - 19 rx #monitor session 1 destination interface Fa7/22 #monitor session 2 source interface Fa7/24 #monitor session 2 destination interface Fa7/25 9. 升級配置 9.1. 交換機IOS保存和升級 交換機的IOS保存和升級是采用TFTP協議完成,所以首先你必須要下載一個TFTP軟 件,然后按照下面的步驟來進行: 1.在你的機器上啟動TFTP 。 2.登陸到交換機,然后在enable狀態下輸入如下命令來完成IOS的保存: switch#copy Flash tftp Source IP address or hostname [171.68.206.171]? Source filename []? cat6000-sup2k8.7-1-1.bin Destination filename [cat6000-sup2k8.7-1-1.binn]? Loading cat6000-sup2k8.7-1-1.bin to 171.68.206.171 (via VLAN1): !!!! !!!!!!!!!!! [OK - 1125001 bytes] 3.假如你要升級IOS文件,那么你首先要檢查flash空間是否夠,假如空間不夠的 話,則需要先刪除原來的IOS然后再升級。按照如下命令來完成IOS的升級: switch#copy tftp flash Source IP address or hostname []? 171.68.206.171 Source filename []? cat6000-sup2k8.7-1-1.bin Destination filename [cat6000-sup2k8.7-1-1.bin]? y Loading cat6000-sup2k8.7-1-1.bin