VLAN - 5-я - и последняя лабораторная работа к первой аттестации по адм в ИС ФКН ВГУ 2012

Лабораторная 8.11: Конфигурирование коммутаторов учебной лаборатории с топологией "Standard Lab"
В этой лабораторной Вы настроите коммутаторы учебной лаборатории с топологией "Standard Lab". В этой топологии два коммутатора модели 2950 и два - модели 3550 (более совершенной, Layer-3).

В задании коммутаторы 3550 используются для VLAN конфигурации, а маршрутизатор 2600C - для маршрутизации с поддержкой наиболее распространенного вида инкапсуляции - 802.1q.

Обратите внимание: Данная лабораторная базируется на предварительной настроенной (см. 5 главу) топологии "Standard Lab". По крайней мере маршрутизаторы 2600A, 2600B, 2600C должны быть настроены.

изучите текст и поймите что к чему - скрипты для подгрузки можно взять здесь =http://fkn.ktu10.com/?q=node/3147

Нужно также немного изменить конфигурацию узлов и коммутаторов. Нужно удалить стартовую конфигурацию коммутаторов 2950A и 3550A и задать новые конфигурации для узлов A - D.

Затем мы создадим два новых VLAN-а на коммутаторах 3550A и 3550B. Потребуется две новые подсети: 172.16.2.0/24 и 172.16.3.0/24. На коммутаторах 2950A и 2950B настройка VLAN выполнятся не будет.
Тем не менее, их интерфейсы управления поднятые в vlan=1 должны быть доступны (в т.ч. пинговаться) из других подсетей.

Интерфейс маршрутизатора 2600C Fastethernet 0/0 останется с адресом 172.16.10.1/24, однако, потребуется перенести этот адрес на саб-интерфейс.

Для начала выполним начальную подготовку коммутаторов 2950A и 3550A.

1. Для удаления конфигурации из NVRAM на 2950A используем команду erase startup-config. Придется перегрузить коммутатор, чтобы коммутатор не обнаружив стартовой конфигурации, использовал настройку по-умолчанию (нужно потом прервать диалог интерактивной настройки во время загрузки коммутатора).

   Todd2950A#erase startup-config
   Erasing the nvram filesystem will remove all files! Continue? [confirm] press enter
   [OK]
   Erase of nvram: complete
   Todd2950A#sh start
   %% Non-volatile configuration memory is not present
   Tdd2950A#

2. Для удаления конфигурации из NVRAM на 3550A используем команду erase startup-config. Придется перегрузить коммутатор, чтобы коммутатор не обнаружив стартовой конфигурации, использовал настройку по-умолчанию (нужно потом прервать диалог интерактивной настройки во время загрузки коммутатора).

   Todd3550A#erase startup-config
   Erasing the nvram filesystem will remove all files! Continue? [confirm] press enter
   [OK]
   Erase of nvram: complete
   Todd3550A#sh start
   %% Non-volatile configuration memory is not present
   Todd3550A#

3. Вернемся на 2950A и установим hostname, пароли и настройки интерфейсов. После настройки, проверьте ее пингом на шлюз по-умолчанию.

Switch>enable
Switch#config t
Switch(config)#hostname 2950A
2950A(config)#enable password todd
2950A(config)#enable secret routersim
2950A(config)#interface vlan 1
2950A(config-if)#ip address 172.16.40.2 255.255.255.0
2950A(config-if)#no shutdown
2950A(config-if)#exit
2950A(config)#ip default-gateway 172.16.40.1
2950A(config)#interface fastethernet 0/1
2950A(config-if)#description Link_to_2600A
2950A(config-if)#interface fastethernet 0/2
2950A(config-if)#description Link_to_HostE
2950A(config-if)#exit
2950A(config)#exit
2950A#ping 172.16.40.1

4. Выполните аналогичную процедуру на 2950B:

Switch>enable
Switch#config t
(config)#hostname 2950B
2950B(config)#enable password todd
2950B(config)#enable secret routersim
2950B(config)#int vlan 1
2950B(config-if)#ip address 172.16.50.2 255.255.255.0
2950B(config-if)#no shutdown
2950B(config-if)#exit
2950B(config)#ip default-gateway 172.16.50.1
2950B(config)#interface fastethernet 0/1
2950B(config-if)#description Link_to_2600B
2950B(config-if)#interface fastethernet 0/2
2950B(config-if)#description Link_to_HostF
2950B(config-if)#exit
2950B(config)#exit
2950B#ping 172.16.50.1

5. Выполните аналогичную процедуру на 3550A:

Switch>enable
Switch#config t
Switch(config)#hostname 3550A
3550A(config)#enable password todd
3550A(config)#enable secret routersim
3550A(config)#line console 0
3550A(config-line)#password console
3550A(config-line)#login
3550A(config-line)#line vty 0 15
3550A(config-line)#password console
3550A(config-line)#login
3550A(config-line)#exit
3550A(config-if)#interface vlan 1
3550A(config-if)#ip address 172.16.10.3 255.255.255.0
3550A(config-if)#no shutdown
3550A(config-if)#interface fastethernet 0/3
3550A(config-if)#description Trunk Link to 3550B
3550A(config-if)#switchport mode trunk
3550A(config-if)#speed 100
3550A(config-if)#duplex full
3550A(config-if)#exit
3550A(config)#ip route 0.0.0.0 0.0.0.0 172.16.10.1
3550A(config)#exit
3550A#ping 172.16.10.1
3550A#ping 172.16.10.4
3550A#ping 172.16.40.2

Пинг не будет выполняться, пока Вы не настроите транк и VLAN-ы на 3550B и удалите IP адрес на интерфейсе f0/0 маршрутизатора 2600C.

6. Создайте VTP домен с именем routersim и оставьте серверный VTP режим коммутатора 3550A (по-умолчанию все коммутаторы - серверы VTP протокола).

3550A#config t

3550A(config)#vtp domain routersim

7. Перейдем на 3550B и установим hostname, пароли и настройки интерфейсов. После настройки, проверьте ее пингом на шлюз по-умолчанию.

Switch>enable
Switch#config t
Switch(config)#hostname 3550B
3550B(config)#enable password todd
3550B(config)#enable secret routersim
3550B(config)#line console 0
3550B(config-line)#password console
3550B(config-line)#login
3550B(config-line)#line vty 0 15
3550B(config-line)#password console
3550B(config-line)#login
3550B(config-line)#exit
3550B(config)#interface vlan1
3550B(config-if)#ip address 172.16.10.4 255.255.255.0
3550B(config-if)#no shutdown
3550B(config-if)#interface fastethernet 0/3
3550B(config-if)#description Trunk_Link_to_3550A
3550B(config-if)#switchport mode trunk
3550B(config-if)#speed 100
3550B(config-if)#duplex full
3550B(config-if)#exit
3550B(config)#ip default-network 172.16.10.0
3550B(config)#exit
3550B#ping 172.16.10.1
3550B#ping 172.16.10.3
3550B#ping 172.16.50.2

8. Настроим 3550B на членство в VTP домене routersim и установим клиентский VTP режим 3550B.

3550B#config t
3550B(config)#vtp domain routersim
3550B(config)#vtp mode client

9. Создадим два VLAN-а на 3550A.

3550A#vlan database
3550A(vlan)#vlan 2
3550A(config-vlan)#vlan 3
Обратите внимание, что мы создали два VLAN-а: 2 и 3. VLAN=1 - сконфигурирован по-умолчанию на всех коммутаторах и не может быть удален или изменен.

10. Перейдем на 3550B и выполним "show VLAN" для проверки информации о VLAN , которая передалась по VTP протоколу.

3550B(config)#exit
3550B#show vlan

Вы должны увидеть три VLAN-а: 1-3, переданные по протоколу VTP коммутатором 3550A.

11. HostA и HostC пусть будут в VLAN=2, под названием Sales, с адресом подсети 172.16.2.0/24. HostA пусть будет иметь адрес 172.16.2.2 и HostC пусть будет иметь адрес 172.16.2.3. Шлюз по-умолчанию 172.16.2.1 мы настроим на маршрутизаторе 2600C далее.

На 3550A сделаем порт f0/1 участником VLAN=2.

3550A#config t
3550A(config)#interface fastethernet 0/1
3550A(config-if)#switchport access vlan 2
3550A(config-if)#switchport mode access

12. На 3550B сделаем порт f0/1 участником VLAN=2.

3550B#config t
3550B(config)#interface fastethernet 0/1
3550B(config-if)#switchport access vlan 2
3550B(config-if)#switchport mode access

13. Настройте HostA и HostC. Для HostA IP=172.16.2.2/24, шлюз 172.16.2.1. Для HostC, IP=172.16.2.3/24, шлюз 172.16.2.1. (см. лабораторную 5.5)

14. Проверим корректность настройки VLAN выполнив ping с HostA на HostC.

>ping 172.16.2.3

15. HostB и HostD будут в VLAN=3. Настроим сначала порт F0/2 коммутатора 3550A участником VLAN3.

3550A#config t
3550A(config)#interface fastethernet 0/2
3550A(config-if)#switchport access vlan 3
3550A(config-if)#switchport mode access

16. Теперь настроим порт F0/2 коммутатора 3550B участником VLAN3.

3550B#config t
3550B(config)#interface fastethernet 0/2
3550B(config-if)#switchport access vlan 3
3550B(config-if)#switchport mode access

17. Настройте HostB IP=172.16.3.2/24, шлюз по-умолчанию 172.16.3.1.

18. Настройте HostD IP=172.16.3.3/24, шлюз по-умолчанию 172.16.3.1.

19. Проверьте, что идет ping с HostD на HostB.

>ping 172.16.3.3

20. Для того, чтобы была связь между узлами, принадлежащими разным VLAN, конечно необходимо настроить маршрутизацию. Используем интерфейс Fastethernet 0/0 маршрутизатора 2600C и =

  • определим тип инкапсуляции 802.1q.
  • Создадим три саб-интерфейса, по одному в каждом VLAN

.

2600C>enable
2600C#config t
2600C(config)#interface fastethernet 0/0
2600C(config-if)#no ip address
2600C(config-if)#duplex full
2600C(config-if)#interface fastethernet 0/0.1
2600C(config-subif)#encapsulation dot1q 1
2600C(config-subif)#ip address 172.16.10.1 255.255.255.0
2600C(config-subif)# interface fastethernet 0/0.2
2600C(config-subif)#encapsulation dot1q 2
2600C(config-subif)#ip address 172.16.2.1 255.255.255.0
2600C(config-subif)# interface fastethernet 0/0.3
2600C(config-subif)#encapsulation dot1q 3
2600C(config-subif)#ip address 172.16.3.1 255.255.255.0

Кроме того, нужно установить порт коммутатора-партнера (3550B) в режим trunk:

3550B#config t
3550B(config-if)#interface fastethernet 0/10
3550B(config-if)#description Trunk_Link_to_2600С
3550B(config-if)#switchport mode trunk
3550B(config-if)#speed 100
3550B(config-if)#duplex full
3550B(config-if)#exit

Выполните команду

show int switchport

на коммутаторе 3550B и обратите внимание на статус портов, в частности, f0/3, f0/10 (транки) и f0/1, f0/2 (порты доступа).

21. Теперь нужно удостовериться, что выполняется ping между всеми хостами и маршрутизаторами. Полезно, также, выполнить трассировку. Например, с хоста А на хост D: tracert 172.16.3.3

vedro-compota's picture

3550B#show int switchport
Name: Fa0/1
Switchport: Enabled
Administrative Mode: static access
Operational Mode: static access
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: Off
Access Mode VLAN: 2 (VLAN0002)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/2
Switchport: Enabled
Administrative Mode: static access
Operational Mode: static access
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: Off
Access Mode VLAN: 3 (VLAN0003)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/3
Switchport: Enabled
Administrative Mode: trunk
Operational Mode: trunk
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: dot1q
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/4
Switchport: Enabled
Administrative Mode: dynamic auto
Operational Mode: down
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/5
Switchport: Enabled
Administrative Mode: dynamic auto
Operational Mode: down
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/6
Switchport: Enabled
Administrative Mode: dynamic auto
Operational Mode: down
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/7
Switchport: Enabled
Administrative Mode: dynamic auto
Operational Mode: down
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/8
Switchport: Enabled
Administrative Mode: dynamic auto
Operational Mode: down
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/9
Switchport: Enabled
Administrative Mode: dynamic auto
Operational Mode: down
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: native
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/10
Switchport: Enabled
Administrative Mode: trunk
Operational Mode: trunk
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: dot1q
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none
Administrative private-vlan host-association: none
Administrative private-vlan mapping: none
Administrative private-vlan trunk native VLAN: none
Administrative private-vlan trunk encapsulation: dot1q
Administrative private-vlan trunk normal VLANs: none
Administrative private-vlan trunk private VLANs: none
Operational private-vlan: none
Trunking VLANs Enabled: All
Pruning VLANs Enabled: 2-1001
Capture Mode Disabled
Capture VLANs Allowed: ALL
Protected: false
Unknown unicast blocked: disabled
Unknown multicast blocked: disabled
Appliance trust: none

Name: Fa0/11
Switchport: Enabled
Administrative Mode: dynamic auto

_____________
матфак вгу и остальная классика =)