zoukankan      html  css  js  c++  java
  • 同一路由器不同vlan之间的通信(一)

    还是废话不多说,第一步,看拓扑图。




    先把pc上的ip都配好。開始设置

    switch0:

    >en

    >conf t

    >vlan 2

    >exit

    >int fa 0/1

    >switchport access vlan 2

    >exit

    >int fa 0/2

    >switchport access vlan 2

    >exit

    >int fa 0/3

    >switchport mode trunk 

    >end



    switch1:

    >en

    >conf t

    >vlan 3

    >exit

    >int fa 0/1

    >switchport access vlan 3

    >exit

    >int fa 0/2

    >switchport access vlan 3

    >exit

    >int fa 0/3

    >switchport mode trunk 

    >end



    Router0:

    >enable

    >configure terminal

    >interface fastEthernet 0/0

    >no ip adderss     //清除ip

    >no shutsown

    >exit

    >interface fastEthernet 0/0.1     //子接口设置

    >encapsulation dot1Q 2    //封装协议 连到vlan 2

    >ip address 192.168.0.1 255.255.255.0

    >exit

    >interface fastEthernet 0/1

    >no ip adderss     //清除ip

    >no shutsown

    >exit

    >interface fastEthernet 0/1.1     //子接口设置

    >encapsulation dot1Q 3   //封装协议 连到vlan 3

    >ip address 192.168.1.1 255.255.255.0

    >end



    pc0  CMD:

    ping PC1



    ping PC 3





    资源下载   http://download.csdn.net/detail/lihuozhiling/7368489



  • 相关阅读:
    cogs 826. Feb11] GF打dota
    cogs 133. [USACO Mar08] 牛跑步 A*k短路算法
    luogu cogs 1437. [NOIP2013]转圈游戏
    RESTful
    中间件
    回顾基础知识,类,fbv,cbv
    Vue
    ES6的一些说明
    小试牛刀2
    小试牛刀
  • 原文地址:https://www.cnblogs.com/mengfanrong/p/3999038.html
Copyright © 2011-2022 走看看