690428:2116 Update Infras #05
CI / CD Pipeline / build (push) Successful in 5m8s
CI / CD Pipeline / deploy (push) Successful in 1m59s

This commit is contained in:
2026-04-28 21:16:49 +07:00
parent 1a51bfa3c4
commit de059c9edb
5 changed files with 1273 additions and 83 deletions
@@ -1,11 +1,12 @@
# Switch Configuration Guide — Omada SDN V6
# Network Infrastructure Guide — Omada SDN V6
**Version:** 3.0
**Last Updated:** 2026-04-24
**Version:** 3.1
**Last Updated:** 2026-04-28
**Status:** Production
**Author:** Infrastructure Team
**Maintainer:** NAP-DMS DevOps
**Scope:** LCBP3 Network Infrastructure (SG3210X-M2 + SG2428P)
**Scope:** LCBP3 Network Infrastructure (SG3210X-M2 + SG2428P + **AMPCOM ZX-SWTGW218AS 2.5G**)
**Filename:** `04-network-infrastructure-guide.md` (renamed from `switch-configuration-guide.md`)
---
@@ -15,14 +16,19 @@
2. [VLAN Definitions](#vlan-definitions)
3. [Port Profiles](#port-profiles)
4. [VLAN Mapping](#vlan-mapping)
5. [Network Diagram](#network-diagram)
- [SG3210X-M2 (Core)](#sg3210x-m2-core-port-configuration)
- [SG2428P (Access)](#sg2428p-access-port-configuration)
- [AMPCOM ZX-SWTGW218AS (2.5G)](#ampcom-zx-swtgw218as-25g-access-port-configuration)
5. [Network Diagram](#network-diagram-v31)
6. [Configuration Procedure](#configuration-procedure)
7. [Change Log](#change-log)
8. [Quick Reference](#quick-reference--edit-port-values)
9. [Pre-Deployment Checklist](#pre-deployment-checklist)
10. [Testing Guide](#testing-guide--vlan--lacp--stp)
11. [Security & Optimization](#security--optimization-recommended)
12. [Related Documents](#related-documents)
8. [Checklists](#checklists-)
- [Pre-Deployment](#pre-deployment-checklist-กอน-apply-คา)
- [Post-Deployment Validation](#post-deployment-validation-checklist-หลง-apply-คา)
- [Final Validation](#final-validation-checklist-หลงทดสอบครบถวน)
9. [Security Hardening](#-security-hardening-ตองทำเพม)
10. [Configuration Analysis](#configuration-analysis--recommendations-)
11. [Related Documents](#related-documents)
---
@@ -40,12 +46,30 @@
|--------|-------|------|
| Core Switch | SG3210X-M2 | 10G Core Switch |
| Access Switch | SG2428P | PoE Access Switch |
| **2.5G Access Switch** | **AMPCOM ZX-SWTGW218AS** | **2.5Gbps Desktop Switch + SFP+ Uplink** |
| NAS Storage | QNAP / ASUSTOR | Network Attached Storage |
| Unmanaged Switch 1 | TL-SG1210P | IP Phone + PC |
| Unmanaged Switch 2 | TL-SL1226P | CCTV |
| Wireless AP | EAP610 | Wi-Fi Access Points |
| Router | ER7206 | Edge Router |
### New Connection Topology (v3.1)
```
SG3210X-M2 (Core)
├── Port 1-2 (LACP) → SG2428P Port 21-22
├── Port 3-4 (LACP) → QNAP
├── Port 5-6 (LACP) → ASUSTOR
├── Port 7 (SFP+) → [Reserved/MGMT] — Block All
├── Port 8 (SFP+) → AMPCOM Port 9 (SFP+) — Trunk Allow All
├── Port 9 (SFP+ 1Gbps) → ER7206 Port 1 (SFP) — Router Uplink
└── Port 10 → [Reserved/MGMT]
AMPCOM ZX-SWTGW218AS (2.5G Access)
├── Port 1-7 → 2.5Gbps Desktop/Laptop
└── Port 8 → Admin Desktop (VLAN 10)
```
### Configuration Concepts
**Port Profile** — Template defining port-level settings (STP Security, Loopback Control, Multicast Fast Leave, Flow Control, EEE, LLDP-MED, PoE). Port Profiles do NOT contain VLAN configuration.
@@ -78,6 +102,20 @@
| 999 | UNUSED | Reserved (was NATIVE) — ไม่ใช้แล้ว | — | — | — |
| 60 | UNUSED | Reserved for future use | — | — | — |
### Network Tags Setting Reference
| Network Tags | Tagged Networks | ใช้เมื่อ |
|--------------|-----------------|----------|
| **Allow All** | อนุญาตทุก VLAN (ยกเว้น Native) | Trunk, AP |
| **Block All** | ไม่อนุญาต VLAN ใดๆ | Access, MGMT |
| **Custom** | อนุญาตเฉพาะ VLAN ที่ระบุใน Tagged Network | NAS, Voice |
> **โครงสร้าง Omada UI (Edit Port):**
> 1. **Native Network** — PVID/Native VLAN
> 2. **Network Tags Setting** — Allow All / Block All / Custom (ควบคุม Tagged VLANs)
> 3. **Untagged Network** — VLAN สำหรับ Untagged traffic (แยกจาก Native)
> 4. **Tagged Network** — ปรากฏเมื่อเลือก Custom
---
## Port Profiles
@@ -360,115 +398,110 @@ Bandwidth Control: Storming Control
**Bandwidth Control:** Management Port ใช้ทั่วไป → Storm Control เป็นค่า Default ปลอดภัย รอง
---
## Quick Reference — Port Profiles Summary
> **สรุปค่าตั้งค่าหลักของแต่ละ Profile สำหรับการเปรียบเทียบ**
| Profile | Edge Port | BPDU Protect | Root Protect | Loop Protect | LLDP-MED | Bandwidth Control |
|---------|-----------|--------------|--------------|--------------|----------|-------------------|
| **001-CORE-TRUNK-LACP** | DISABLE | DISABLE | DISABLE | ENABLE | DISABLE | Storming Control |
| **002-NAS-LACP** | DISABLE | DISABLE | DISABLE | ENABLE | DISABLE | Storming Control |
| **003-UNMANAGED-SWITCH** | DISABLE | DISABLE | **ENABLE** 🔥 | ENABLE | DISABLE | Storming Control |
| **004-AP-TRUNK** | **ENABLE** | **ENABLE** 🔥 | DISABLE | DISABLE | **ENABLE** | Storming Control |
| **005-VOICE-ONLY** | **ENABLE** | **ENABLE** 🔥 | DISABLE | DISABLE | **ENABLE** 🔥 | Storming Control |
| **006-ACCESS-PC** | **ENABLE** 🔥 | **ENABLE** 🔥🔥🔥 | DISABLE | DISABLE | DISABLE | Storming Control |
| **007-DEFAULT-MGMT** | **ENABLE** | **ENABLE** | DISABLE | DISABLE | DISABLE | Storming Control |
### ความหมายสัญลักษณ์
| สัญลักษณ์ | ความหมาย |
|-----------|----------|
| 🔥 | สำคัญ — ต้องเปิดเพื่อความปลอดภัย |
| 🔥🔥🔥 | สำคัญมาก — ห้ามปิดเด็ดขาด |
### หลักการเลือก Profile
| ประเภทพอร์ต | Profile | เหตุผลหลัก |
|-------------|---------|-----------|
| **Trunk LACP** | 001 | Loop Protect ป้องกัน Loop จากอุปกรณ์เบื้องหลัง |
| **NAS LACP** | 002 | NAS บางรุ่นส่ง BPDU แปลก → ห้ามเปิด BPDU Guard |
| **Unmanaged Switch** | 003 | **Root Protect** ป้องกัน switch เถื่อนยึด root bridge |
| **Access Point** | 004 | **Edge Port + BPDU Guard** ป้องกัน rogue switch |
| **IP Phone** | 005 | **LLDP-MED** สำหรับ Voice VLAN, BPDU Guard ปลอดภัย |
| **PC/Printer** | 006 | **Edge Port + BPDU Guard** ป้องกันการเสียบ switch โดยไม่ได้รับอนุญาต |
| **Management** | 007 | ค่า Default ปลอดภัย สำหรับพอร์ตทั่วไป |
---
## VLAN Mapping 🔶
### SG3210X-M2 (Core) Port Configuration
| Port | Destination | Profile | Native (Untagged) | Tagged | Voice |
|------|-------------|---------|-------------------|--------|-------|
| 1-2 | SG2428P (LACP) | 001-CORE-TRUNK-LACP | 20 | 10,30,40,50,70 | Off |
| 3-4 | QNAP (LACP) | 002-NAS-LACP | 10 | 20 🔥 | Off |
| 5-6 | ASUSTOR (LACP) | 002-NAS-LACP | 10 | 20 🔥 | Off |
| 7 | Reserved / MGMT Port | 007-DEFAULT-MGMT | 20 | None | Off |
| 8 | Admin Desktop | 006-ACCESS-PC | 10 | None | Off |
| 9 | ER7206 (Router) | 001-CORE-TRUNK-LACP | 20 | 10,30,40,50,70 | Off |
| 10 | Reserved / MGMT Port | 007-DEFAULT-MGMT | 20 | None | Off |
| Port | Destination | Profile | Native (Untagged) | Tagged | Voice | Network Tags |
|------|-------------|---------|-------------------|--------|-------|--------------|
| 1-2 | SG2428P (LACP) | 001-CORE-TRUNK-LACP | 20 | 10,30,40,50,70 | Off | Allow All |
| 3-4 | QNAP (LACP) | 002-NAS-LACP | 10 | 20 🔥 | Off | Allow All |
| 5-6 | ASUSTOR (LACP) | 002-NAS-LACP | 10 | 20 🔥 | Off | Allow All |
| 7 | Reserved / MGMT Port | 007-DEFAULT-MGMT | 20 | | Off | **Block All** 🔒 |
| 8 | AMPCOM Port 9 (SFP+) | 001-CORE-TRUNK-LACP | 20 | 10,30,40,50,70 | Off | **Allow All** 🔥 |
| 9 | ER7206 Port 1 (SFP 1Gbps) | 001-CORE-TRUNK-LACP | 20 | 10,30,40,50,70 | Off | Allow All |
| 10 | Reserved / MGMT Port | 007-DEFAULT-MGMT | 20 | | Off | Allow All |
📌 **NAS (Port 3-6) ปรับใหม่:** เพิ่ม Tagged VLAN 20 สำหรับ MGMT redundancy
📌 **NAS (Port 3-6):** Tagged VLAN 20 สำหรับ MGMT redundancy
📌 **Trunk LACP (Port 1-2, 9):** Native VLAN 20 — ใช้ร่วมกับ Management VLAN เพื่อลดความซับซ้อน
📌 **Port 7 (SFP+):** **Block All** — Isolated Management Port ( hardened )
📌 **Port 8 (SFP+):** Trunk ไปยัง AMPCOM 2.5G Switch — **Allow All VLANs**
📌 **Port 9 (SFP+):** Router Uplink (Fixed 1Gbps) — ER7206 SFP Port 1
📌 **Native VLAN 20:** ใช้ร่วมกับ Management VLAN สำหรับทุก Trunk Port
---
### SG2428P (Access) Port Configuration
| Port | Destination | Profile | Native (Untagged) | Tagged | Voice |
|------|-------------|---------|-------------------|--------|-------|
| 1-16 | EAP610 | 004-AP-TRUNK | 20 | 10,30,40,50,70 🔥 allow all | Off |
| 17-18 | IP Phone Port 1 | 005-VOICE-ONLY | 50 | 30 | Enable (VLAN 50) |
| 19-20 | Reserved / MGMT Port | 007-DEFAULT-MGMT | 20 | None | Off |
| 21-22 | SG3210X-M2 (LACP) | 001-CORE-TRUNK-LACP | 20 | 10,30,40,50,70 | Off |
| 23 | Printer | 006-ACCESS-PC | 30 | None | Off |
| 24 | OC200 (Controller) | 007-DEFAULT-MGMT | 20 | None | Off |
| 25 | TL-SL1226P (CCTV) | 003-UNMANAGED-SWITCH | 40 | None | Off |
| 26 | TL-SG1210P (IP Phone + PC) | 003-UNMANAGED-SWITCH | 30 | 50 | Enable (VLAN 50) |
| 27-28 | Reserved / MGMT Port | 007-DEFAULT-MGMT | 20 | None | Off |
| Port | Destination | Profile | Native (Untagged) | Tagged | Voice | Network Tags |
|------|-------------|---------|-------------------|--------|-------|--------------|
| 1-16 | EAP610 | 004-AP-TRUNK | 20 | 10,30,40,50,70 🔥 allow all | Off | Allow All |
| **17-19** | **IP Phone + PC Trunk** | **005-VOICE-ONLY** | **50** | **30** | **Enable (VLAN 50)** | **Custom** |
| **20** | **Reserved / MGMT** | **007-DEFAULT-MGMT** | **20** | **—** | **Off** | **Block All** 🔒 |
| 21-22 | SG3210X-M2 (LACP) | 001-CORE-TRUNK-LACP | 20 | 10,30,40,50,70 | Off | Allow All |
| 23 | Printer | 006-ACCESS-PC | 30 | | Off | Allow All |
| 24 | OC200 (Controller) | 007-DEFAULT-MGMT | 20 | | Off | Block All 🔒 |
| 25 | TL-SL1226P (CCTV) | 003-UNMANAGED-SWITCH | 40 | | Off | Allow All |
| 26 | TL-SG1210P (IP Phone + PC) | 003-UNMANAGED-SWITCH | 30 | 50 | Enable (VLAN 50) | Custom |
| 27-28 | Reserved / MGMT Port | 007-DEFAULT-MGMT | 20 | | Off | Allow All |
📌 **IP Phone Ports (17-18) ปรับใหม่:** Native VLAN 50 (Voice) + Tagged VLAN 30 (Data for PC ที่ต่อ Port 2 ของ IP Phone)
📌 **IP Phone Ports (17-19):** Native VLAN 50 (Voice) + Tagged VLAN 30 (Data) — **3 Ports สำหรับ IP Phone Trunk**
📌 **AP Ports (1-16) ปรับใหม่:** Allow all VLANs สำหรับ future expansion — Native VLAN 20 ร่วมกับ Management
📌 **Port 20 (MGMT Hardened):** **Block All** — Isolated Management Port สำหรับ future use
📌 **SG2428P MGMT (Port 19-20, 27-28):** Access Switch ต้องการ Management IP บน VLAN 20
📌 **OC200 (Port 24):** Controller ใช้ VLAN 20 (MGMT) + **Network Tags = Block All** 🔒
📌 **OC200 (Port 24):** Controller ใช้ VLAN 20 (MGMT) และ Hardening ด้วย **Network Tags Setting = Block All** ใน OC200 UI
📌 **AP Ports (1-16):** Allow all VLANs สำหรับ future expansion — Native VLAN 20
---
## Network Diagram
### AMPCOM ZX-SWTGW218AS (2.5G Access) Port Configuration
| Port | Destination | Profile | Native (Untagged) | Tagged | Voice | Speed |
|------|-------------|---------|-------------------|--------|-------|-------|
| 1-7 | 2.5G Desktop/Laptop | 006-ACCESS-PC | 10 | — | Off | **2.5Gbps** |
| 8 | Admin Desktop | 006-ACCESS-PC | 10 | — | Off | **2.5Gbps** |
| **9 (SFP+)** | **SG3210X-M2 Port 8** | **001-CORE-TRUNK-LACP** | **20** | **10,30,40,50,70** | **Off** | **10Gbps** 🔥 |
📌 **AMPCOM Port 9 (SFP+):** Uplink 10Gbps ไปยัง Core Switch — Trunk All VLANs
📌 **Port 1-8:** 2.5Gbps Access Ports สำหรับ Admin/Desktop — VLAN 10 (NAS-ADMIN)
📌 **Admin Desktop:** ย้ายจาก SG3210X-M2 Port 8 มาที่ AMPCOM Port 8 (2.5Gbps)
---
## Network Diagram (v3.1)
```
┌──────────────┐
│ ER7206 │
│ (Trunk 20)
└──────┬───────┘
┌──────────────────────────┐
│ SG3210X-M2 (Core) │
[Root Bridge 4096]
└──────────────────────────┘
LACP 1-2 / | | | | \ Reserved
/ | | | | \
▼ ▼ ▼ ▼ ▼ ▼
SG2428P (Access) QNAP ASUSTOR Admin Reserved
[Priority 8192] (VLAN10+20) (VLAN10+20) (VLAN10)
(AP 116 Trunk)
┌──────────────┐
│ ER7206 │
│ (SFP 1Gbps)
│ Port 1 │
└──────┬───────┘
┌──────────────────────────┐
SG3210X-M2 (Core)
│ [Root Bridge 4096] │
│ Port 9 (SFP+ 1Gbps) │
└──────────────────────────┘
LACP 1-2 / / | | | \
/ / | | | \
▼ ▼ ▼ ▼ ▼ ▼ Port 10
SG2428P (Access) QNAP ASUSTOR AMPCOM Reserved
[Priority 8192] (VLAN10+20) (VLAN10+20) [2.5G Access]
(AP 116) Port 8 → Admin
(VLAN 10)
Uplink SG3210XM2 (12) ↔ SG2428P (2122)
Uplink Connections:
├── SG3210X-M2 Port 1-2 (LACP) ↔ SG2428P Port 21-22
├── SG3210X-M2 Port 8 (SFP+) → AMPCOM Port 9 (SFP+ 10Gbps)
├── SG3210X-M2 Port 9 (SFP+ 1Gbps) → ER7206 Port 1 (SFP)
└── SG3210X-M2 Port 7 → [Reserved/Block All]
WiFi Staff → VLAN 30
WiFi Guest → VLAN 70
CCTV → VLAN 40
IP Phone → VLAN 50
Printer → VLAN 30
Admin Desktop → VLAN 10
NAS → VLAN 10 (+20 MGMT)
OC200 → VLAN 20
Device VLANs:
├── WiFi Staff → VLAN 30
├── WiFi Guest → VLAN 70
├── CCTV → VLAN 40
├── IP Phone → VLAN 50 (Ports 17-19)
├── Printer → VLAN 30
├── Admin Desktop → VLAN 10 (AMPCOM Port 8, 2.5Gbps)
├── NAS → VLAN 10 (+20 MGMT)
└── OC200 → VLAN 20 (Port 24, Block All)
```
---
@@ -498,373 +531,56 @@ OC200 → VLAN 20
| Version | Date | Changes |
|---------|------|---------|
| 3.1 | 2026-04-28 | **Document Renamed** — Changed from `switch-configuration-guide.md` to `04-network-infrastructure-guide.md` to better reflect comprehensive scope (switches, VLAN, security, topology, AMPCOM 2.5G). **AMPCOM 2.5G Integration** — Added AMPCOM ZX-SWTGW218AS 2.5Gbps switch, SG3210X-M2 Port 8→AMPCOM SFP+ Trunk, Port 9→ER7206 SFP 1Gbps, Port 7→Block All, Port 10→Reserved. SG2428P Port 17-19→IP Phone Trunk (3 ports), Port 20→Block All. Admin Desktop moved to AMPCOM Port 8 (2.5Gbps) |
| 3.0 | 2026-04-24 | **FINAL VERSION** — STP-only (no Loop Detection), BPDU Guard on access ports, Root Guard on unmanaged switch ports, Native VLAN 20 สำหรับทุก Trunk, NAS with MGMT redundancy (VLAN 20 tagged), AP allow-all VLANs, Security Hardening section |
| 2.0 | 2026-04-24 | Updated port mappings (LACP 21-22), new VLAN scheme (30/40/50/70), consolidated CCTV/IoT to VLAN 40, added DHCP table, renamed PC-ONLY to ACCESS-PC |
| 1.0 | 2026-04-23 | Initial version with basic port profiles and VLAN mapping |
---
## Quick Reference — Edit Port Values
## Checklists ✅
> **โครงสร้าง Omada UI (Edit Port):**
> 1. **Native Network** — PVID/Native VLAN
> 2. **Network Tags Setting** — Allow All / Block All / Custom (ควบคุม Tagged VLANs)
> 3. **Untagged Network** — VLAN สำหรับ Untagged traffic (แยกจาก Native)
> 4. **Tagged Network** — ปรากฏเมื่อเลือก Custom
### SG3210X-M2
| Port | Native | Network Tags | Untagged | Tagged | Profile | Voice |
|------|--------|--------------|----------|--------|---------|-------|
| 1-2 | 20 | Allow All | 20 | All (ยกเว้น 20) | 001-CORE-TRUNK-LACP | Off |
| 3-4 | 10 | Custom | 10 | 20 | 002-NAS-LACP | Off |
| 5-6 | 10 | Custom | 10 | 20 | 002-NAS-LACP | Off |
| 7 | 20 | Block All | 20 | — | 007-DEFAULT-MGMT | Off |
| 8 | 10 | Block All | 10 | — | 006-ACCESS-PC | Off |
| 9 | 20 | Allow All | 20 | All (ยกเว้น 20) | 001-CORE-TRUNK-LACP | Off |
| 10 | 20 | Block All | 20 | — | 007-DEFAULT-MGMT | Off |
### SG2428P
| Port | Native | Network Tags | Untagged | Tagged | Profile | Voice |
|------|--------|--------------|----------|--------|---------|-------|
| 1-16 | 20 | Allow All | 20 | All (ยกเว้น 20) | 004-AP-TRUNK | Off |
| 17-18 | 50 | Custom | 50 | 30 | 005-VOICE-ONLY | 50 |
| 19-20 | 20 | Block All | 20 | — | 007-DEFAULT-MGMT | Off |
| 21-22 | 20 | Allow All | 20 | All (ยกเว้น 20) | 001-CORE-TRUNK-LACP | Off |
| 23 | 30 | Block All | 30 | — | 006-ACCESS-PC | Off |
| 24 | 20 | Block All | 20 | — | 007-DEFAULT-MGMT | Off |
| 25 | 40 | Block All | 40 | — | 003-UNMANAGED-SWITCH | Off |
| 26 | 30 | Custom | 30 | 50 | 003-UNMANAGED-SWITCH | 50 |
| 27-28 | 20 | Block All | 20 | — | 007-DEFAULT-MGMT | Off |
### ความหมาย Network Tags Setting
| Network Tags | Tagged Networks | ใช้เมื่อ |
|--------------|-----------------|----------|
| **Allow All** | อนุญาตทุก VLAN (ยกเว้น Native) | Trunk, AP |
| **Block All** | ไม่อนุญาต VLAN ใดๆ | Access, MGMT |
| **Custom** | อนุญาตเฉพาะ VLAN ที่ระบุใน Tagged Network | NAS, Voice |
---
## Pre-Deployment Checklist
### Pre-Deployment Checklist (ก่อน Apply ค่า)
ก่อน Apply ค่า Configuration:
- [ ] สร้าง VLANs 10, 20, 30, 40, 50, 70 ใน Omada Controller (VLAN 20 = Native + Management)
- [ ] สร้าง Port Profiles 001007 ครบถ้วน (STP Mode — ไม่ใช้ Loop Detection)
- [ ] ตรวจสอบ LACP Group Configuration (Port 1-2 ↔ Port 21-22)
- [ ] **AMPCOM Setup:** เพิ่ม AMPCOM ZX-SWTGW218AS ใน Omada → Set Port 9 = Trunk, Port 1-8 = VLAN 10
- [ ] **SG3210X-M2 Port 9:** Fix Speed = 1Gbps (สำหรับ ER7206 SFP Port 1)
- [ ] **SG3210X-M2 Port 8:** เชื่อมต่อกับ AMPCOM Port 9 (SFP+) — Trunk All VLANs
- [ ] ตั้งค่า DHCP Server ตามตาราง VLAN Definitions
- [ ] ตรวจสอบว่า OC200 อยู่บน VLAN 20 และมี IP 192.168.20.x
- [ ] **OC200 Hardening:** Settings → Network → Network Tags Setting = **Block All** (เฉพาะ VLAN 20)
- [ ] **SG3210X-M2 MGMT:** ตั้งค่า Management IP บน VLAN 20 (192.168.20.x) — Port 7, 10 ใช้ VLAN 20
- [ ] **SG3210X-M2 Hardening:** Port 7 = **Block All** (Isolated MGMT)
- [ ] **SG2428P Hardening:** Port 20 = **Block All** (Isolated MGMT)
- [ ] **ER7206 MGMT:** Router มี IP บน VLAN 20 (ผ่าน Tagged) — Native VLAN 20 ใช้ร่วมกับ Management
- [ ] **SG2428P MGMT:** Access Switch ได้รับ IP บน VLAN 20 ผ่าน Uplink — ตรวจสอบใน Devices
- [ ] **AP MGMT:** EAP610 ได้รับ Management IP ผ่าน VLAN 20 — ตรวจสอบการ Adopt
- [ ] ตรวจสอบ Voice VLAN Enable บน Port 17-18 และ 26
- [ ] กำหนด STP Priority: Core=4096, Access=8192
- [ ] สำรอง Configuration ปัจจุบันก่อน Apply
- [ ] **IP Phone:** ตรวจสอบ Voice VLAN Enable บน Port 17-19 (3 ports) และ Port 26
- [ ] **Admin Desktop:** ย้ายเชื่อมต่อไปที่ AMPCOM Port 8 (2.5Gbps)
---
# Testing Guide — VLAN + LACP + STP
### Final Validation Checklist (หลังทดสอบครบถ้วน)
การทดสอบทีละ Layer โดยไม่ต้องใช้เครื่องมือพิเศษ — ใช้แค่ PC + ping + OC200 UI
---
## PART 1 — Testing VLAN (Step-by-Step)
### Goal
- ตรวจสอบว่าแต่ละพอร์ตอยู่ VLAN ถูกต้อง
- ตรวจสอบว่า Tagged/Untagged ทำงาน
- ตรวจสอบว่า DHCP แจก IP ถูก subnet
- ตรวจสอบว่า WiFi → VLAN ถูกต้อง
---
### STEP 1 — Test VLAN 10 (NAS-ADMIN)
**Test Equipment:**
- Admin Desktop (Port 8 SG3210X-M2)
- QNAP / ASUSTOR
**Procedure:**
1. Connect Admin Desktop → Port 8
2. Open Command Prompt
3. Type:
```
ipconfig
```
4. Expected IP range:
```
192.168.10.x
```
**Ping Tests:**
```
ping 192.168.10.1 ← Gateway
ping <QNAP-IP>
ping <ASUSTOR-IP>
```
**Expected Result:**
- All pings successful
- Should NOT ping to VLAN 30/40/50/70 (if ACL configured)
---
### STEP 2 — Test VLAN 30 (USERS)
**Test Equipment:**
- General PC
- Printer
- Staff WiFi (SSID: Staff)
**Procedure:**
1. Connect PC → Port 23 or Port 26 (via TL-SG1210P)
2. Type:
```
ipconfig
```
3. Expected IP:
```
192.168.30.x
```
**Ping Tests:**
```
ping 192.168.30.1
ping <Printer-IP>
```
**WiFi Staff Test:**
1. Connect to SSID Staff
2. Type:
```
ipconfig
```
3. Expected IP: 192.168.30.x
---
### STEP 3 — Test VLAN 40 (CCTV/IoT)
**Test Equipment:**
- CCTV Camera (via TL-SL1226P Port 25)
**Procedure:**
1. Open OC200 → Clients
2. Camera must show as VLAN 40
3. Test ping from Admin Desktop:
```
ping <CCTV-IP>
```
**Expected Result:**
- Ping successful
- DHCP must assign IP 192.168.40.x
---
### STEP 4 — Test VLAN 50 (VOICE)
**Test Equipment:**
- IP Phone (Port 1718 SG2428P)
**Procedure:**
1. IP Phone boots up
2. Expected IP:
```
192.168.50.x
```
3. In OC200 → Clients, must see Voice VLAN 50
**LLDP-MED Test:**
In OC200 → Switch → Port 1718, must see:
```
LLDP-MED: Active
Voice VLAN: 50
```
---
### STEP 5 — Test VLAN 70 (Guest WiFi)
**Procedure:**
1. Connect to SSID Guest
2. Type:
```
ipconfig
```
3. Expected IP:
```
192.168.70.x
```
**Isolation Test:**
```
ping 192.168.30.1 ← Must NOT pass
ping 192.168.10.1 ← Must NOT pass
```
---
## PART 2 — Testing LACP (Step-by-Step)
### Goal
- ตรวจสอบว่า LACP ระหว่าง SG3210X-M2 ↔ SG2428P ทำงาน
- ตรวจสอบว่า QNAP/ASUSTOR LACP ทำงาน
- ตรวจสอบว่าไม่มี Mis-config
---
### STEP 1 — Check LACP Status in OC200
**Path:** Insight → Switch → LAG Status
Expected status:
**SG3210X-M2:**
- LAG1 (Port 12) → **Up**
- LAG2 (Port 34) → **Up**
- LAG3 (Port 56) → **Up**
**SG2428P:**
- LAG1 (Port 2122) → **Up**
---
### STEP 2 — Test Load Balancing
**Procedure:**
1. Open QNAP → File Station
2. Copy large file (1020GB) to Admin Desktop
3. Open Task Manager → Performance → Ethernet
4. Must see traffic on both links (Port 34 or 56)
**Uplink Test:**
1. Run Speedtest between PC VLAN 30 → NAS VLAN 10
2. Must achieve > 1Gbps (if 2Gbps LACP)
---
### STEP 3 — Test Failover
**Procedure:**
1. Disconnect cable from **Port 1** of SG3210X-M2
2. LACP must remain **Up** (using Port 2)
3. Disconnect Port 2 → LACP must go Down
Repeat test with QNAP/ASUSTOR
---
## PART 3 — Testing STP (Step-by-Step)
### Goal
- ตรวจสอบว่าไม่มี Loop
- ตรวจสอบว่า Root Bridge ถูกต้อง
- ตรวจสอบว่า STP Security ทำงาน
---
### STEP 1 — Check Root Bridge
**Path:** Devices → SG3210X-M2 → Ports → STP
Expected:
```
SG3210X-M2 = Root Bridge
```
If not, adjust Priority:
```
SG3210X-M2 Priority = 4096
SG2428P Priority = 8192
```
---
### STEP 2 — Test Loop Detection
**Safe Test Method:**
1. Go to TL-SG1210P (Port 26 SG2428P)
2. Create loop with LAN cable (Port 1 ↔ Port 2)
3. Check OC200 → Alerts
Expected alert:
```
Loop Detected on Port 26
Port Shutdown (BPDU Protect)
```
Port must auto-shutdown
---
### STEP 3 — Test STP Blocking
**Procedure:**
1. Connect cable from SG2428P Port 19 → SG2428P Port 20
2. Check OC200 → Switch → Ports
Expected:
```
STP State: Blocking
```
---
### STEP 4 — Test Topology Change (TC Guard)
**Procedure:**
1. Power cycle AP (Port 116)
2. Check OC200 → Logs
Expected: **NO** message:
```
Topology Change Detected
```
Because TC Guard is enabled
---
## PART 4 — Testing Checklist (SOP)
### VLAN Tests
- [ ] VLAN 10 gets IP 192.168.10.x
- [ ] VLAN 30 gets IP 192.168.30.x
- [ ] VLAN 40 gets IP 192.168.40.x
- [ ] VLAN 50 gets IP 192.168.50.x
- [ ] VLAN 70 gets IP 192.168.70.x
### WiFi Tests
- [ ] Staff WiFi → VLAN 30
- [ ] Guest WiFi → VLAN 70
### Device Tests
- [ ] CCTV → VLAN 40
- [ ] IP Phone → VLAN 50
- [ ] Printer → VLAN 30
- [ ] Admin Desktop → VLAN 10
- [ ] NAS → VLAN 10
- [ ] OC200 → VLAN 20
### LACP Tests
- [ ] LACP SG3210X-M2 ↔ SG2428P = Up
- [ ] LACP QNAP = Up
- [ ] LACP ASUSTOR = Up
- [ ] Load balancing works (2Gbps)
- [ ] Failover works (single link failure)
### STP Tests
#### Connectivity
- [ ] LACP = UP ทุกเส้น (Core↔Access, QNAP, ASUSTOR)
- [ ] Root Bridge = SG3210X-M2 (Priority 4096)
- [ ] BPDU Guard shutdown test (เสียบ switch ที่ port PC → port ต้อง shutdown)
- [ ] Root Guard works (003-UNMANAGED-SWITCH)
- [ ] STP Blocking works
- [ ] TC Guard works (no topology change on AP reboot)
- [ ] WiFi ได้ VLAN ถูกต้อง (Staff=30, Guest=70)
- [ ] NAS เข้าถึงได้ทั้ง VLAN 10 และ 20 (Management)
- [ ] Guest VLAN เข้า LAN ไม่ได้ (isolation)
#### Security
- [ ] DHCP Snooping blocks rogue DHCP (test: ต่อ rogue DHCP server ที่ access port)
- [ ] Storm Control limits broadcast (AP Ports 1-16)
- [ ] BPDU Guard shuts down unauthorized switches
- [ ] Root Guard prevents rogue root bridge (Port 25-26)
#### Performance
- [ ] Jumbo Frame works (MTU 9000 end-to-end: PC → NAS)
- [ ] LACP load balancing 2Gbps aggregate
- [ ] Failover works (single link failure ไม่มี downtime)
---
@@ -966,26 +682,179 @@ Jumbo Frame: 9000
---
## 💥 Final Validation Checklist
## Configuration Analysis & Recommendations 🔍
### Connectivity Tests
- [ ] LACP = UP ทุกเส้น (Core↔Access, NAS)
- [ ] Root Bridge = Core Switch (SG3210X-M2 Priority 4096)
- [ ] เสียบ switch ที่ port PC → port ต้อง shutdown (BPDU Guard)
- [ ] WiFi ได้ VLAN ถูกต้อง (Staff=30, Guest=70)
- [ ] NAS เข้าถึงได้ทั้ง VLAN 10 และ 20
- [ ] Guest VLAN เข้า LAN ไม่ได้ (isolation)
> **สรุปการวิเคราะห์การตั้งค่าปัจจุบัน พร้อมข้อเสนอแนะสำหรับการปรับปรุง**
### Security Tests
- [ ] DHCP Snooping blocks rogue DHCP
- [ ] Storm Control limits broadcast
- [ ] BPDU Guard shuts down unauthorized switches
- [ ] Root Guard prevents rogue root bridge
---
### Performance Tests
- [ ] Jumbo Frame works (MTU 9000 end-to-end)
- [ ] LACP load balancing (2Gbps aggregate)
- [ ] Failover works (single link failure)
### 1. VLAN Architecture Analysis
| หัวข้อ | สถานะปัจจุบัน | การประเมิน | ข้อเสนอแนะ |
|--------|--------------|-----------|-----------|
| **Native VLAN** | VLAN 20 (MGMT) | ✅ ดี — ใช้ VLAN เดียวกับ Management | คงไว้ ลดความซับซ้อน |
| **VLAN 999** | UNUSED | ⚠️ ระวัง — ไม่ใช้แล้วแต่ยังมีในระบบ | พิจารณาลบออกหรือเก็บสำรอง |
| **VLAN Segmentation** | 7 VLANs (10,20,30,40,50,60,70) | ✅ ดี — แยกกลุ่มชัดเจน | คงไว้ ครอบคลุมทุก use case |
| **Guest VLAN (70)** | แยกจาก USERS (30) | ✅ ดี — Security สูง | คงไว้ มี Isolation ที่ถูกต้อง |
#### ⚠️ ประเด็นที่ต้องระวัง
```
🔴 VLAN 20 ใช้ทั้ง Native + Management
└─ ข้อดี: ลดความซับซ้อน
└─ ข้อควรระวัง: ต้องใช้ Network Tags = Block All บน MGMT ports
เพื่อป้องกัน unauthorized access
```
---
### 2. Port Profile Analysis
| Profile | จุดแข็ง | จุดที่ต้องระวัง | คะแนน |
|---------|---------|----------------|--------|
| **001-CORE-TRUNK-LACP** | Loop Protect เปิด — ป้องกัน loop จาก downstream | ไม่มี Root Protect (ถูกต้องสำหรับ Trunk) | ⭐⭐⭐⭐⭐ |
| **002-NAS-LACP** | BPDU Protect ปิด — รองรับ NAS ที่ส่ง BPDU แปลก | ต้องตรวจสอบ NAS รุ่นก่อนใช้ | ⭐⭐⭐⭐ |
| **003-UNMANAGED-SWITCH** | Root Protect + Loop Protect — ปลอดภัยสูงสุด | ต้องใช้กับ Unmanaged Switch เท่านั้น | ⭐⭐⭐⭐⭐ |
| **004-AP-TRUNK** | Edge Port + BPDU Guard — ป้องกัน rogue AP | LLDP-MED เปิด — ตรวจสอบ AP รองรับ | ⭐⭐⭐⭐⭐ |
| **005-VOICE-ONLY** | BPDU Guard + LLDP-MED — เหมาะสมกับ IP Phone | ต้องตรวจสอบ Phone รองรับ LLDP-MED | ⭐⭐⭐⭐⭐ |
| **006-ACCESS-PC** | Edge Port + BPDU Guard 🔥🔥🔥 — ปลอดภัยสูง | ถ้ามี switch ซ่อน จะ shutdown ทันที | ⭐⭐⭐⭐⭐ |
| **007-DEFAULT-MGMT** | สมดุลระหว่างปลอดภัยและใช้งานได้ | ไม่มี LLDP-MED (ไม่จำเป็น) | ⭐⭐⭐⭐ |
#### 🎯 ข้อเสนอแนะเพิ่มเติมสำหรับ Profile
```
💡 003-UNMANAGED-SWITCH:
└─ พิจารณาเพิ่ม TC Guard = ENABLE ถ้า downstream switch
มี Topology Change บ่อย (เช่น CCTV ที่ reboot บ่อย)
💡 004-AP-TRUNK:
└─ ถ้า AP ไม่รองรับ LLDP-MED ให้ปิด LLDP-MED เพื่อประหยัดทรัพยากร
└─ หรือใช้ VLAN กำหนดเองใน AP GUI แทน
```
---
### 3. Network Tags (VLAN Assignment) Analysis
| พอร์ต | Network Tags | ความเหมาะสม | หมายเหตุ |
|--------|-------------|-------------|----------|
| **Trunk (1-2, 9, 21-22)** | Allow All | ✅ ถูกต้อง | ต้องรองรับทุก VLAN |
| **AP (1-16)** | Allow All | ✅ ถูกต้อง | WiFi มีหลาย SSID/หลาย VLAN |
| **NAS (3-6)** | Custom (20) | ✅ ถูกต้อง | NAS ต้องการ VLAN 10+20 เท่านั้น |
| **MGMT (7, 10, 19-20, 24, 27-28)** | Block All | ✅ ถูกต้อง | ปลอดภัย — ไม่ต้อง Tagged VLAN |
| **PC/Printer (8, 23)** | Block All | ✅ ถูกต้อง | Access port ไม่ต้อง Tagged |
| **Voice (17-18, 26)** | Custom (30/50) | ✅ ถูกต้อง | Voice VLAN + Data VLAN |
#### ⚠️ ประเด็นที่ตรวจสอบ
```
🔴 Port 24 (OC200):
└─ Network Tags = Block All ✅
└─ ต้องตั้งค่า OC200 UI: Settings → Network → Network Tags = Block All
เพื่อให้สอดคล้องกับ Switch config
🔴 Port 26 (TL-SG1210P):
└─ Untagged = 30, Tagged = 50 (Custom)
└─ ตรวจสอบว่า TL-SG1210P ส่งต่อ Voice VLAN ได้จริง
(บางรุ่น unmanaged switch ไม่ส่งต่อ VLAN tag)
```
```
# 🔐 Security Hardening (ต้องทำเพิ่ม)
Required security configurations for Enterprise-grade network protection.
---
## DHCP Snooping 🔥
```bash
Global: ENABLE
Trusted Ports:
- Uplink ไป Router (ER7206)
- Core Trunk (Port 1-2, 9)
```
**Path:** Settings → Wired Networks → Switch → DHCP Snooping
1. Enable **DHCP Snooping** globally
2. Mark **Trusted Ports**:
- SG3210X-M2 Port 9 (to ER7206)
- SG3210X-M2 Port 1-2 (Core Trunk)
- SG2428P Port 21-22 (Uplink to Core)
3. **Untrusted:** ทุก access port (จะถูก block ถ้าส่ง DHCP Offer)
---
## Storm Control (AP Ports) 🔥
```bash
Broadcast: 1%
Multicast: 2%
Unknown: 2%
```
**Path:** Settings → Wired Networks → Switch → Port Profile → 004-AP-TRUNK
1. Navigate to **Bandwidth Control / Storm Control**
2. Configure:
- Broadcast: 1% (หรือ 1000 pps)
- Multicast: 2% (หรือ 2000 pps)
- Unknown Unicast: 2% (หรือ 2000 pps)
3. Save
📌 **หมายเหตุ:** ใช้ percentage หรือ pps ตามความเหมาะสมกับ traffic
---
## STP Priority (Root Bridge Election) 🔥
```bash
SG3210X-M2 (Core): 4096
SG2428P (Access): 8192
```
**Path:** Devices → Switch → Config → STP → Priority
1. **SG3210X-M2:** Set Priority = **4096** (Root Bridge)
2. **SG2428P:** Set Priority = **8192** (Backup Root)
3. Save and verify:
```
OC200 → Topology → Root Bridge = SG3210X-M2
```
📌 **สำคัญ:** Core ต้องเป็น Root Bridge เสมอ
---
## Jumbo Frame 🔥
```bash
MTU: 9000
(ต้องตั้งทุก device ให้เท่ากัน)
```
### SG3210X-M2
**Path:** Devices → SG3210X-M2 → Config → Switch Settings
```
Jumbo Frame: Enable
MTU: 9000
```
### QNAP
**Path:** Control Panel → Network & Virtual Switch → Interfaces
```
MTU: 9000
```
### ASUSTOR
**Path:** Settings → Network → Interface → Advanced
```
Jumbo Frame: 9000
```
⚠️ **คำเตือน:** ถ้าตั้งไม่เท่ากันทุก device → จะมีปัญหา fragmentation หรือ packet drop
---
+1
View File
@@ -27,6 +27,7 @@ It consolidates what was previously split across multiple operations and specifi
| **[04-02-backup-recovery.md](./04-02-backup-recovery.md)** | Disaster Recovery | RTO/RPO strategies, QNAP to ASUSTOR backup scripts, Restic/Mysqldump config |
| **[04-03-monitoring.md](./04-03-monitoring.md)** | Observability | Prometheus metrics, AlertManager rules, Grafana alerts |
| **[04-04-deployment-guide.md](./04-04-deployment-guide.md)** | Production Rollout | Blue-Green deployment scripts, **Appendix A: QNAP Container Station**, **Appendix B: Gitea Actions CI/CD**, **Appendix C: act_runner setup** |
| **[04-network-infrastructure-guide.md](./04-network-infrastructure-guide.md)** | 🔥 **Network Design** | Omada SDN configuration, VLAN mapping, Port Profiles, STP Security, AMPCOM 2.5G integration, Security Hardening |
| **[04-05-maintenance-procedures.md](./04-05-maintenance-procedures.md)** | Routine Care | Log rotation, dependency updates, scheduled DB optimizations |
| **[04-06-security-operations.md](./04-06-security-operations.md)** | Hardening & Audit | User access review, SSL renewals, vulnerability scanning, **Appendix A: SSH Setup**, **Appendix B: Secrets Management** |
| **[04-07-incident-response.md](./04-07-incident-response.md)** | Escalation | P0-P3 classifications, incident commander roles, Post-Incident Review |