【正文】
nterface FastEther0/2, changed state to up *Oct 6 08:24:35: %LINK3UPDOWN: Interface FastEther0/3, changed state to up *Oct 6 08:24:35: %LINK3UPDOWN: Interface FastEther0/4, changed state to up *Oct 6 08:24:35: %LINK3UPDOWN: Interface FastEther0/5, changed state to up *Oct 6 08:24:36: %LINEPROTO5UPDOWN: Line protocol on Interface FastEther0/05, changed state to up *Oct 6 08:24:36: %LINEPROTO5UPDOWN: Line protocol on Interface FastEther0/3, changed state to up *Oct 6 08:24:36: %LINEPROTO5UPDOWN: Line protocol on Interface FastEther0/4, changed state to up 以下的例子顯示使用句號來配置不同類型端口的組 : Switch configure terminal Switch(config) interface range fastether0/1 3, gigabitether0/1 2 Switch(configifrange) no shutdown Switch(configifrange) *Oct 6 08:29:28: %LINK3UPDOWN: Interface FastEther0/1, changed state to up *Oct 6 08:29:28: %LINK3UPDOWN: Interface FastEther0/2, changed state to up *Oct 6 08:29:28: %LINK3UPDOWN: Interface FastEther0/3, changed state to up *Oct 6 08:29:28: %LINK3UPDOWN: Interface GigabitEther0/1, changed state to up *Oct 6 08:29:28: %LINK3UPDOWN: Interface GigabitEther0/2, changed state to up *Oct 6 08:29:29: %LINEPROTO5UPDOWN: Line protocol on Interface GigabitEther0/ 1, changed state to up *Oct 6 08:29:29: %LINEPROTO5UPDOWN: Line protocol on Interface FastEther0/ 2, changed state to up *Oct 6 08:29:29: %LINEPROTO5UPDOWN: Line protocol on Interface FastEther0/ 3, changed state to up 配置二層端口 3750 的所有端口缺省的端口都是二層口,如果此端口已經(jīng)配置成三層端口的話,則需要用 switchport 來使其成為二層端口。 配置端口速率及雙工模式 可以配置快速以太口的速率為 10/100Mbps 及千兆以太口的速率為10/100/1000Mbps。 但對于 GBIC 端口則不能配置速率及雙工模式,有時可以配置 nonegotiate,當需要聯(lián)接不支持自適應的其它千兆端口時 命令 目的 Step 1 configure terminal 進入配置狀態(tài) . Step 2 interface interfaceid 進入端口配置狀態(tài) . Step 3 speed {10 | 100 | 1000 | auto | nonegotiate} 設置端口速率 注 1000 只工作在千兆口 . GBIC模塊只工作在 1000 Mbps 下 . nonegotiate 只能在這些 GBIC 上用 1000BASESX, LX, and ZX GBIC. Step 4 duplex {auto | full | half} 設置全雙工或半雙工 . Step 5 end 退出 Step 6 show interfaces interfaceid 顯示有關配置情況 Step 7 copy runningconfig startupconfig 保存 Switch configure terminal Switch(config) interface fastether0/3 Switch(configif) speed 10 Switch(configif) duplex half 端口描述 命令 目的 Step 1 configure terminal 進入配置模式 Step 2 interface interfaceid 進入要加入描述的端口 Step 3 description string 加入描述 (最多 240 個字符 ). Step 4 end 退回 . Step 5 show interfaces interfaceid 驗證 . description or show runningconfig Step 6 copy runningconfig startupconfig 保存 Use the no description interface configuration mand to delete the description. This example shows how to add a description on Fast Ether interface 0/4 and to verify the description: Switch config terminal Enter configuration mands, one per line. End with CNTL/Z. Switch(config) interface fastether0/4 Switch(configif) description Connects to Marketing Switch(configif) end Switch show interfaces fastether0/4 description Interface Status Protocol Description Fa0/4 up down Connects to Marketing 配置三層口 Catalyst 3750 支持三種類型的三層端口 : ? SVIs: 即 interface vlan Note 當生成一個 interface Vlan 時,只有當把某一物理端口分配給它時才能被激活 ? 三層以太網(wǎng)通道口( EtherChannel) ? .路由口:路由口是指某一物理端口在端口配置狀態(tài)下用 no switchport 命令生成的端口 所有的三層都需要 IP 地址以實現(xiàn)路由交換 配置步驟如下: 命令 目的 Step 1 configure terminal 進入配置狀態(tài) Step 2 interface {{fastether | gigabitether} interfaceid} | {vlan vlanid} | {portchannel portchannelnumber} 進入端口配置狀 態(tài) Step 3 no switchport 把物理端口變成三層口 Step 4 ip address ip_address sub_mask 配置 IP地址和掩碼 Step 5 no shutdown 激活端口 Step 6 end 退出 Step 7 show interfaces [interfaceid] show ip interface [interfaceid] show runningconfig interface [interfaceid] 驗 證配置 Step 8 copy runningconfig startupconfig 保存配置 配置舉例如下: Switch configure terminal Enter configuration mands, one per line. End with CNTL/Z. Switch(config) interface gigabitether0/2 Switch(configif) no switchport Switch(configif) ip address Switch(co