TIL 0208 in Internship part.1

CHAN LIM·2023년 2월 8일
0

ETC

목록 보기
9/18
post-thumbnail

CISCO 명령

STP 확인

Switch#show spanning-tree

RSTP 변경

Switch(config)#spanning-tree mode rapid-pvst

RSTP 우선순위 설정

Switch#show spanning-tree
DSwitch1(config)#spanning-tree vlan 1 priority 0
DSwitch2(config)#spanning-tree vlan 1 priority 4096

VLAN 설정

Switch#sh vlan

Switch(config)#vlan 10
Switch(config-vlan)#vlan 20
Switch(config-vlan)#vlan 30
Switch(config-vlan)#name edu
Switch(config-vlan)#do show vlan

Switch(config-vlan)#exit
Switch(config)#no vlan 30

Switch(config)#interface range f0/10-11
Switch(config-if-range)#switchport access vlan 10
Switch(config-if-range)#interface range f0/12,f0/13
Switch(config-if-range)#switchport access vlan 20

Trunk 설정

Switch1#show int f0/1 switchport

Switch1(config)#int f0/1
Switch1(config-if)#switchport mode trunk

Switch2#show int f0/1 switchport
Switch2#show interfaces trunk

L3 Trunk 설정

Switch(config)#int range f0/1-24
Switch(config-if-range)#switchport trunk encapsulation dot1q
Switch(config-if-range)#switchport mode trunk
Switch(config-if-range)#switchport trunk allowed vlan 1-100,500-600

Switch(config)#vlan 10
Switch(config-vlan)#vlan 20

Switch#show int trunk

EtherChannel 설정

Switch1(config)#int range f0/1-2
Switch1(config-if-range)#channel-protocol lacp
Switch1(config-if-range)#channel-group 1 mode active

Switch2(config)#int range f0/1,f0/2
Switch2(config-if-range)#channel-protocol lacp
Switch2(config-if-range)#channel-group 1 mode active

Switch#show etherchannel sum

Load-balance 설정

Switch#show etherchannel load-balance

Switch(config)#port-channel load-balance ?
Switch(config)#port-channel load-balance src-dst-mac


VLAN

  • Broadcast Domain
  • Logical Network (Subnet)
  • Layer 2에서 생성되는 서브넷
  • 같은 VLAN에 속하는 Port는 Broadcast를 공유하며, 동일한 IP subnet에 속한다.

효과

  • Broadcast 제어
  • 보안
  • 유연성 및 확장성

멤버십 설정

  • static
  • dynamic
  • voice

Trunk

  • 두개의 Switch 사이의 Point-to-Point연결을 통해 다수의 VLAN 트래픽을 전달하는 방법

Switch Port 종류

  • Access Port
    • 하나의 Vlan 소속
    • PC연결
  • Trunk Port
    • 모든 Vlan 소속
    • SW연결

Trunking Protocol

  • 전송할 프레임에 헤더를 추가하여 구분하는 방법
    • ISL (Inter-Switch Link) (CISCO)
      • 1548 byte
    • 802.1Q (표준)
      • 1522 byte
  • Vlan 1은 헤더를 추가하지 않고 넘긴다. (untagging.)
    • Native VLAN
    • default로 놔두는 것을 권장.

EtherChannel

  • 비슷한 링크들의 논리적 결합 - Virtual Link
  • 대역폭 확장
  • 경로 이중화
  • Load Balancing
  • 논리적인 하나의 Port
  • Redundancy

관리 방법

  • 수동 : ON
  • 자동
    • PAgP (CISCO) - 2, 4, 8개
      • desirable : 적극
      • auto : 수동
      • on : PAgP에 의해서가 아닌 수동으로 관리하겠다.
    • LAcP (표준) - 2, 4, 8, 16개 (단, 8개만 Active)
      • Active : 적극
      • Passive : 수동
      • on : PAgP에 의해서가 아닌 수동으로 관리하겠다.
profile
클라우드, 데이터, DevOps 엔지니어 지향 || 글보단 사진 지향

0개의 댓글