Skip to content

Nuface Blog

隨意隨手記 Casual Notes

Menu
  • Home
  • About
  • Services
  • Blog
  • Contact
  • Privacy Policy
  • Login
Menu

Category: QoS

About QoS

Example: Weighted Bandwidth Shaping

Posted on 2025-11-122025-11-12 by Rico

📘 1. Objective We have three major outbound traffic types: Application Direction Max Bandwidth Priority Web (HTTP/HTTPS) Download 2 Mbps Medium FTP Download 1 Mbps Low VoIP (SIP + RTP) Download 2 Mbps High Goal: ⚙️ 2. Configuration Steps Step 1️⃣ Create Pipes Navigate to: Name Bandwidth Description pipe_web 2 Mbps Web browsing and downloads…

Read more

OPNsense Traffic Shaping 實際設定範例

Posted on 2025-11-122025-11-12 by Rico

📘 一、範例目標 假設企業內部共有三類主要應用: 應用 流量方向 頻寬上限 優先權 Web 流量 (HTTP/HTTPS) Download 2 Mbps 中 FTP 檔案傳輸 Download 1 Mbps 低 VoIP 語音通話 Download 2 Mbps 高 希望達到以下效果: ⚙️ 二、設定步驟 Step 1️⃣ 建立 Pipes 進入: 建立三條下載管道: 名稱 頻寬 說明 pipe_web 2 Mbps 限制一般 HTTP/HTTPS 下載 pipe_ftp 1 Mbps 限制 FTP 傳輸頻寬 pipe_voip 2 Mbps 限制 VoIP…

Read more

Introduction to Traffic Shaping in OPNsense

Posted on 2025-11-122025-11-12 by Rico

🧭 1. What is Traffic Shaping? Traffic shaping is the control of network traffic to optimize or ensure performance, reduce latency, and increase usable bandwidth by applying additional delay or restrictions to packet flows. In OPNsense, traffic shaping is implemented via pipes, queues, and rules. The rules manage flows and assign them to pipes/queues based…

Read more

OPNsense中的頻寬管理簡介

Posted on 2025-11-122025-11-12 by Rico

🧭 一、什麼是 Traffic Shaping? Traffic Shaping(流量整形,也稱為封包整形/packet shaping)是一種網路流量控制技術,藉由對特定封包集合(流/flow)施加延遲或控制,使其符合預定的頻寬、優先順序或延遲要求。 在 OPNsense 中,Traffic Shaper 提供「管道 (Pipes)」「佇列 (Queues)」「規則 (Rules)」三個構件來實現,並可設定來源/目的 IP、介面、方向 (進/出)、通訊埠等條件。 ⚙️ 二、構成元件與原理 運作流程:使用者/裝置封包依來源、目的、介面、埠號等條件匹配到一條「Shaper Rule」,該規則將封包導向某條 Pipe,再透過該 Pipe 下的 Queue 依權重分配頻寬。若該流量達到管道上限,則多餘封包會被排隊或延遲。 🧩 三、主要應用場景 🧰 四、如何在 OPNsense 中設定 Step 1:建立 Pipes 前往:Firewall → Traffic Shaper → Pipes新增下載/上傳管道,設定頻寬、描述等。 Step 2:建立 Queues(如需權重) 前往:Firewall → Traffic Shaper → Queues選擇所屬 Pipe,設定權重 (weight)、遮罩 (mask)(如以來源或目的 IP 平分頻寬)等。…

Read more

Building a Linux Gateway with HTB + iptables + IFB

Posted on 2025-11-052025-11-05 by Rico

Complete Bidirectional Bandwidth Control (Web / Mail / FTP / VoIP) In this article, we’ll build a Linux-based gateway that not only routes traffic between your LAN and the Internet but also provides precise QoS and bandwidth shaping using HTB, iptables, and IFB. This setup is ideal for small offices, labs, or home networks where…

Read more

Linux Gateway 上的 HTB 雙向頻寬控制實作

Posted on 2025-11-052025-11-05 by Rico

一、環境設定 介面 方向 說明 eth0 外網(WAN) 連接 Internet(例如 PPPoE、NAT 出口) eth1 內網(LAN) 內部使用者連線的網卡,例如 192.168.10.0/24 Gateway Linux 主機 同時負責路由與 NAT 目標 控制內部使用者上 / 下行頻寬與分類(Web/Mail/FTP/VoIP) 二、邏輯說明 流量方向定義: 類型 封包方向 實際控制介面 上傳 LAN → WAN 控制 eth0 的 egress 下載 WAN → LAN 控制 eth1 的 ingress(轉發前)→ 用 IFB 重導再整形 因此: 重點:雖然下載的流量「進入 eth0」再被轉送到 eth1,但我們控制的是「eth0 的 ingress」,不是 eth1 的…

Read more

Recent Posts

  • Postfix + Let’s Encrypt + BIND9 + DANE Fully Automated TLSA Update Guide
  • Postfix + Let’s Encrypt + BIND9 + DANE TLSA 指紋自動更新完整教學
  • Deploying DANE in Postfix
  • 如何在 Postfix 中部署 DANE
  • DANE: DNSSEC-Based TLS Protection

Recent Comments

  1. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on High Availability Architecture, Failover, GeoDNS, Monitoring, and Email Abuse Automation (SOAR)
  2. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on MariaDB + PostfixAdmin: The Core of Virtual Domain & Mailbox Management
  3. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on Daily Operations, Monitoring, and Performance Tuning for an Enterprise Mail System
  4. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on Final Chapter: Complete Troubleshooting Guide & Frequently Asked Questions (FAQ)
  5. Building a Complete Enterprise-Grade Mail System (Overview) - Nuface Blog on Network Architecture, DNS Configuration, TLS Design, and Postfix/Dovecot SNI Explained

Archives

  • December 2025
  • November 2025
  • October 2025

Categories

  • AI
  • Apache
  • Cybersecurity
  • Database
  • DNS
  • Docker
  • Fail2Ban
  • FileSystem
  • Firewall
  • Linux
  • LLM
  • Mail
  • N8N
  • OpenLdap
  • OPNsense
  • PHP
  • QoS
  • Samba
  • Switch
  • Virtualization
  • VPN
  • WordPress
© 2025 Nuface Blog | Powered by Superbs Personal Blog theme