Вы находитесь на странице: 1из 6

VLANS (S1)

S1>enable
Password:
S1#conf t
Enter configuration commands, one per line. End with CNTL/Z.
S1(config)#vlan 86
S1(config-vlan)#name BlackHole
S1(config-vlan)#int fa0/1
S1(config-if)#switchport mode trunk
S1(config-if)#switchport trunk native vlan 99
S1(config-if)#int range fa0/7-18
S1(config-if-range)#switchport mode access
S1(config-if-range)#switchport access vlan 15
S1(config-if-range)#int range fa0/19-24
S1(config-if-range)#switchport mode access
S1(config-if-range)#switchport access vlan 25
S1(config-if-range)#show vlan brief
^
% Invalid input detected at '^' marker.

S1(config-if-range)#do show vlan brief

VLAN Name Status Ports


---- -------------------------------- --------- -------------------------------
1 default active Fa0/1, Fa0/2, Fa0/3, Fa0/4
Fa0/5, Fa0/6, Gig0/1, Gig0/2
15 Customers active Fa0/7, Fa0/8, Fa0/9, Fa0/10
Fa0/11, Fa0/12, Fa0/13, Fa0/14
Fa0/15, Fa0/16, Fa0/17, Fa0/18
25 Employee active Fa0/19, Fa0/20, Fa0/21, Fa0/22
Fa0/23, Fa0/24
86 BlackHole active
99 Management&Native active
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
S1(config-if-range)#int range g0/1-2, fa0/2-6
S1(config-if-range)#switchport mode access
S1(config-if-range)#switchport access vlan 86
S1(config-if-range)#shutdown

%LINK-5-CHANGED: Interface GigabitEthernet0/1, changed state to administratively


down

%LINK-5-CHANGED: Interface GigabitEthernet0/2, changed state to administratively


down

%LINK-5-CHANGED: Interface FastEthernet0/2, changed state to administratively down

%LINK-5-CHANGED: Interface FastEthernet0/3, changed state to administratively down

%LINK-5-CHANGED: Interface FastEthernet0/4, changed state to administratively down

%LINK-5-CHANGED: Interface FastEthernet0/5, changed state to administratively down

%LINK-5-CHANGED: Interface FastEthernet0/6, changed state to administratively down


S1(config-if-range)#

R2 VLANS

R2>enable
Password:
R2#int g0/0.25
^
% Invalid input detected at '^' marker.

R2#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R2(config)#g0/0.25
^
% Invalid input detected at '^' marker.

R2(config)#int g0/0.25
R2(config-subif)#encapsulation dot1q
% Incomplete command.
R2(config-subif)#encapsulation dot1Q 25
R2(config-subif)#ip address 192.168.1.129 255.255.255.192
R2(config-subif)#ipv6 address 2001:db8:a:25::1/64
R2(config-subif)#ipv6 address fe80::2 link-local
R2(config-subif)#

R2 con0 is now available

Press RETURN to get started.

AUTHORIZED ACCESS ONLY (Passwords: cisco, class)

User Access Verification

Password:
R2>enable
Password:
R2#int g0/0.1
^
% Invalid input detected at '^' marker.

R2#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R2(config)#int g0/0.1
R2(config-subif)#encapsulation dot1Q 1
R2(config-subif)#ip add 192.168.1.193 255.255.255.224
R2(config-subif)#do show run
Building configuration...

Current configuration : 1564 bytes


!
version 15.1
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname R2
!
!
!
enable secret 5 $1$mERr$9cTjUIEqNGurQiFU.ZeCi1
!
!
!
!
!
!
ip cef
no ipv6 cef
!
!
!
!
license udi pid CISCO1941/K9 sn FTX1524ET18
!
!
!
!
!
!
!
!
!
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface GigabitEthernet0/0
no ip address
duplex auto
speed auto
shutdown
!
interface GigabitEthernet0/0.1
encapsulation dot1Q 1 native
ip address 192.168.1.193 255.255.255.224
ipv6 address FE80::2 link-local
ipv6 address 2001:DB8:A:1::1/64
!
interface GigabitEthernet0/0.15
no ip address
ipv6 address FE80::2 link-local
ipv6 address 2001:DB8:A:15::1/64
!
interface GigabitEthernet0/0.25
encapsulation dot1Q 25
ip address 192.168.1.129 255.255.255.192
ipv6 address FE80::2 link-local
ipv6 address 2001:DB8:A:25::1/64
!
interface GigabitEthernet0/0.99
no ip address
ipv6 address FE80::2 link-local
ipv6 address 2001:DB8:A:99::1/64
!
interface GigabitEthernet0/1
no ip address
duplex auto
speed auto
shutdown
!
interface Serial0/0/0
description Link to R1
ip address 10.1.1.1 255.255.255.252
ipv6 address FE80::2 link-local
ipv6 address 2001:DB8:A:A::1/64
clock rate 2000000
!
interface Serial0/0/1
no ip address
clock rate 2000000
shutdown
!
interface Vlan1
no ip address
shutdown
!
ip classless
!
ip flow-export version 9
!
!
!
banner motd ^CAUTHORIZED ACCESS ONLY (Passwords: cisco, class)^C
!
!
!
!
line con 0
password cisco
login
!
line aux 0
!
line vty 0 4
password cisco
login
!
!
!
end

R2(config-subif)#int g0/0.15
R2(config-subif)#encapsulation dot1Q 1

%Configuration of multiple subinterfaces of the same main


interface with the same VID (1) is not permitted.
This VID is already configured on GigabitEthernet0/0.1.

R2(config-subif)#encapsulation dot1Q 15
R2(config-subif)#ip add 192.168.1.1 255.255.255.128
R2(config-subif)#int g0/0.99
R2(config-subif)#encapsulation dot1Q 99
R2(config-subif)#ip add 192.168.1.225 255.255.255.224
R2(config-subif)#encapsulation dot1Q 99 native
R2(config-subif)#exit
R2(config)#int g0/0
R2(config-if)#no shutdown

R2(config-if)#
%LINK-5-CHANGED: Interface GigabitEthernet0/0, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0, changed state


to up

%LINK-5-CHANGED: Interface GigabitEthernet0/0.1, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0.1, changed state


to up

%LINK-5-CHANGED: Interface GigabitEthernet0/0.15, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0.15, changed


state to up

%LINK-5-CHANGED: Interface GigabitEthernet0/0.25, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0.25, changed


state to up

%LINK-5-CHANGED: Interface GigabitEthernet0/0.99, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0.99, changed


state to up

R2(config-if)#
****************************************************************************
PPP

R2(config-if)#exit
R2(config)#username R1 password cisco
R2(config)#int s0/0/0
R2(config-if)#encapsulation ppp
R2(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0/0, changed state to down

R2(config-if)#ppp authentication chap

R1>enable
Password:
R1#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#int s0/0/0
R1(config-if)#encapsulation ppp
R1(config-if)#ppp authentication chap
R1(config-if)#exit
R1(config)#username R2 password cisco
R1(config)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0/0, changed state to up

**********************************************************************************

ROUTING

R1(config)#ip route 0.0.0.0 0.0.0.0 s0/0/1


%Default route without gateway, if not a point-to-point interface, may impact
performance
R1(config)#ipv6 route ::0/0/1
^
% Invalid input detected at '^' marker.

R1(config)#ipv6 route ::/0 s0/0/1

R2(config-if)#exit
R2(config)#ipv6 route ::/0 s0/0/0
R2(config)#

Вам также может понравиться