Some knowledge about switches in computer network

case 4

Configure inter-vlan routing, enable Layer 3 SVI interface and configure IP address

Create vlan10, vlan 20, and configure IP 192.168.10.1 /24 172.16.20.1 /24 with interface

Enable a Layer 3 interface and configure IP 10.1.1.1 /24 


The drawing is as follows:




My choice: configure switch b first, then c, and finally a

b:
sys
vlan 10
quit
port gi 1/0/1 # put the interface into vlan10
quit

#Configure trunk

interface gi 1/0/2 #Enter port
port link-type trunk #Set to trunk mode
port trunk pemit vlan 10 20 (put vlan 10, 20 in at the same time, in fact, vlan 20 has not been created at this time)
quit

c: (same steps as b, just replace vlan 10 with vlan 20)

a:
sys
vlan 10 
quit
vlan 20
quit
interface gi 1/0/2
port link-type trunk
port trunk pemit vlan 10  20

quit
interface vlan 10
ip add 192.168.10.1 255.255.255.0
quit

interface gi 1/0/1
port link-type trunk
port trunk pemit vlan 10 20
quit
interface vlan 20
ip add 172.16.20.1 255.255.255.0
quit

At this point, add IP addresses, subnet masks, and gateways to the two PCs.


To enable a Layer 3 interface and configure IP10.1.1.1/24

interface gi 1/0/3
port link-mode route
ip add 10.1.1.1 255.255.255.0

quit


case 5

Static view of the mac CAM table display mac-address

Static interface binding:
mac-address static MAC (physical address string of characters) interface gi 1/0/1 vlan 10

Static IP, mac binding: (Static binding of IP and MAC)
arp static 192.168.10.2 MAC 10 gi 1/0/1 (interface)


display lldp ne  list


dis arp timer default time for aging arp

dis mac-adress aging-time View the saved time


case 6 Configuration of static routing and configuration of dynamic routing




Switch 1 is configured as vlan 10, vlan 20     

vlan 10 : ip  address 192.168.10.1   255.255.255.0
vlan 20 :   ip  address 192.168.20.1   255.255.255.0
Interface 0/3 : needs to be configured in routed mode
                 int gi 1/0/3
                 port  link-mode route
                 ip add 1.1.1.1 255.255.255.0

Switch 2 configure vlan30 vlan40

vlan 30 : ip address 192.168.30.1 255.255.255.0
vlan 40:     ip address 192.168.40.1  255.255.255.0
 Interface 0/3 : needs to be configured in routed mode
                 int gi 1/0/3
                 port  link-mode route
                 ip add 1.1.1.2  255.255.255.0

Assign the ip address to each of the PCs. Be careful to choose within your own gateway. For example: pc1 : 192.168.10.2     



Configure static routes: (bidirectional)

On switch 1:
      ip   route-static 192.168.30.0  255.255.255.0  1.1.1.2
      ip   route-static 192.168.40.0  255.255.255.0  1.1.1.2

On switch 2: 
      ip   route-static 192.168.10.0  255.255.255.0 1.1.1.1
      ip   route-static  192.168.20.0  255.255.255.0 1.1.1.1



#Explanation: ip route-static 192.168.40.0 (destination subnet) 255.255.255.0 (subnet mask) 1.1.1.2 (address of the next hop)



In fact, such a one-by-one input is too troublesome. Can use:

ip  route-static  0.0.0.0    0.0.0.0    1.1.1.1



Dynamic Routing Configuration (RIP)

rip (port number can be specified)

On switch 1:
network 192.168.10.0  0.0.0.255
network 192.168.20.0  0.0.0.255
network  1.1.1.0   0.0.0.255

On switch 2:
network 192.168.30.0  0.0.0.255
network 192.168.40.0  0.0.0.255
network  1.1.1.0   0.0.0.255











Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325818853&siteId=291194637