網絡改造前的準備

  辦公樓要進行裝修同時對現有網絡進行改造,目前核心交換機是思科產品後續用華爲的產品替換,爲了不影響辦公,先用華爲產品在臨時辦公地根據現有的網絡配置組建一個網絡,現在的用戶把計算機搬過去插上網線就可以和原來一樣上網。

  具體過程:


  在思科交換機上設置好Trunk口。


  conf t
  
  int gigabitethernet 6/8

  switchport mode trunk

  switchport trunk allow vlan all

  write
  exit


  在華爲的5720上進行具體設置:

  1、設置一個Trunk口;
  interface GigabitEthernet 0/0/49 //指定某個光電口
  port link-type trunk         //設置trunk
  port trunk allow-pass vlan all   //允許所有VLAN 通過

  或者

  interface GigabitEthernet0/0/49
  port link-type trunk
  port trunk allow-pass vlan 2 to 12   //允許Vlan2到Vlan12的訪問通過
  2、配置路由

  ip route-static 0.0.0.0 0.0.0.0  路由地址    //設置靜態路由
  3、設置交換機的地址,管理地址,開放訪問模式;



  4、將每個接口(端口)上配置Vlan,對應到現有的Vlan,綁定IP地址、Mac地址、接口(端口)號。

    ⑴ 創建Vlan

      interface Vlan號
        ip address 網關地址 子網掩碼
    
    ⑵進入具體接口,綁定Vlan即可。

      interface GigabitEthernet0/0/1
      port link-type access
      port default vlan 5
    ⑶綁定

      ip source check user-bind enable
      綁定IP地址、Mac地址、端口

      user-bind static ip-address IP地址 mac-address Mac地址 interface GigabitEthernet 0/0/1 vlan ID

      如需要刪除之前的綁定,可以輸入
      undo user-b static ip-address #ip地址;   //刪除端口、MAC地址綁定,也可以輸出mac-address #mac地址
      user-bind static ip-address #ip地址 mac-address #mac地址 ; //指定ip地址和mac地址綁定,綁定類型可以端口,ip,mac自由組合

      //第一種:綁定IP和端口(加Vlan)

      user-bind static ip-address IP地址 interface GigabitEthernet 0/0/1 vlan ID


      //第二種:綁定Mac和端口(加Vlan)

      user-bind static mac-address Mac地址 interface GigabitEthernet 0/0/1 vlan ID

      //第三種:綁定IP、Mac和端口(加Vlan)
      user-bind static ip-address IP地址 mac-address Mac地址 interface GigabitEthernet 0/0/1 vlan ID



      常用命令:

      quit              //退出配置界面

      save              //保存設置

      display this          //顯示當前接口或者Vlan的配置

      display Current         //顯示系統當前的配置

      undo 操作            //刪除操作

      與思科操作類似,不熟悉命令後面加?,記不全命令加Tab。

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章