Hướng dẫn sử dụng NetScope Console Using NetScope Console
Tài liệu này đi từng trang của dashboard, giải thích ý nghĩa mỗi widget, và chỉ bạn cách cấu hình sensor, zone, cảnh báo và API key. This guide walks through every page of the dashboard, explains each widget, and shows you how to configure sensors, zones, alerts, and API keys.
Phiên bản:Version: v1.1.0 · cập nhật 2026-04-22 · hỗ trợ sFlow v5 và NetFlow v5 (NetFlow v9 / IPFIX sắp ra mắt). v1.1.0 · updated 2026-04-22 · supports sFlow v5 and NetFlow v5 (NetFlow v9 / IPFIX coming soon).
1 · Đăng nhập 1 · Signing in
Mở trình duyệt và truy cập domain mà quản trị viên đã cung cấp (ví dụ https://netscope.example.com). Bạn sẽ thấy màn hình đăng nhập.
Open your browser and navigate to the domain provided by your administrator (for example https://netscope.example.com). You'll land on the sign-in page.
-
Nhập tên đăng nhập và mật khẩuEnter username and password
Tài khoản mặc định
adminđược tạo lúc cài đặt; mật khẩu nằm trong/etc/sflow/sflow.envtrên server. The defaultadminaccount is created at install time; its password lives in/etc/sflow/sflow.envon the server. -
Phiên đăng nhậpSession
Cookie
sflow_sessioncó thời hạn 12 giờ. Sau khi hết hạn, bạn sẽ được chuyển lại về trang đăng nhập. Thesflow_sessioncookie lasts 12 hours. You'll be bounced back to the sign-in page when it expires. -
Đổi mật khẩuChange your password
Vào menu người dùng ở góc phải trên → Password. Mật khẩu mới tối thiểu 12 ký tự. Open the user menu in the top-right corner → Password. New passwords must be at least 12 characters.
Đừng dùng mật khẩu mặc định trong production.Never leave the default password in place in production. Đổi ngay sau khi đăng nhập lần đầu và cân nhắc bật HTTPS bắt buộc ở Nginx. Change it immediately after the first login and enforce HTTPS at the Nginx layer.
2 · Khái niệm cốt lõi 2 · Core concepts
Trước khi đi sâu vào từng trang, có một số khái niệm bạn sẽ gặp liên tục. Before diving into each page, there are a few concepts you'll run into constantly.
| Khái niệmConcept | Ý nghĩaMeaning |
|---|---|
| Sensor | Một UDP listener + protocol decoder. Mỗi exporter thực tế (router / switch) thường map với một sensor.A UDP listener + protocol decoder. Each physical exporter (router / switch) typically maps to one sensor. |
| IP Zone | Tập hợp tiền tố IP được theo dõi riêng (ví dụ "khách hàng", "peering HN", "peering HCM"). Match bằng longest-prefix match.A set of IP prefixes you track separately (e.g. "customers", "HN peering", "HCM peering"). Matched via longest-prefix match. |
| Node | Một prefix nằm trong zone. Có thể có cờ graphs (vẽ biểu đồ) và accounting (tính bps).A prefix inside a zone. Each node carries graphs (show on charts) and accounting (include in bps totals) flags. |
| NIX / IXP | nix = traffic nội địa (cả hai đầu ở Việt Nam hoặc cùng zone). ixp = traffic quốc tế.nix = domestic traffic (both ends in-country or in-zone). ixp = international traffic. |
| Bin | Khung tổng hợp 5 giây căn theo wall-clock. Mọi con số trên dashboard thực chất là bps / pps trong một bin.A 5-second aggregation window aligned to wall-clock. Every number on the dashboard is really a bps / pps inside a bin. |
| Sampling rate | Router chỉ lấy 1 trong N gói để gửi về. NetScope tự nhân lên để ước tính lưu lượng thực.Routers only forward 1 out of every N packets. NetScope automatically scales back up to estimate real traffic. |
| Decoder | Nhãn gán cho flow dựa trên port / protocol (IP, TCP, UDP, DNS, HTTPS, …). Một flow có thể có nhiều nhãn.A label applied to flows based on port / protocol (IP, TCP, UDP, DNS, HTTPS, …). A flow can carry multiple labels. |
3 · Dashboard 3 · Dashboard
Trang chủ / là dashboard mặc định. Bạn có biểu đồ global, top talker theo bps / pps, top ASN, và có thể kéo-thả để sắp xếp lại layout. Mọi widget tự refresh; layout lưu vào localStorage của trình duyệt — mỗi người dùng có layout riêng.
The root path / is the default dashboard. It has a global chart, top talkers by bps / pps, top ASNs, and you can drag widgets to rearrange the layout. All widgets auto-refresh; layout is saved in the browser's localStorage — each user has their own.
TRAFFIC GLOBAL · 600sGLOBAL TRAFFIC · 600s
TOP BPS · IN
| 8.2G | |
| 5.1G | |
| 3.7G | |
| 1.8G |
PPS TOTAL
4.9MppsTOP ASN · IXP
| AS15169 | 6.8G |
| AS32934 | 4.1G |
| AS13335 | 2.9G |
TOP ASN · NIX
| AS45899 | 12.1G |
| AS18403 | 8.7G |
| AS7552 | 5.2G |
Danh sách widgetWidget reference
| Widget | Mô tảDescription |
|---|---|
| Global Chart | Biểu đồ bps toàn hệ thống, cửa sổ 10 phút, chia 2 hướng IN/OUT.System-wide bps chart, 10-minute window, split into IN/OUT. |
| Top BPS In / Out | Top 10 IP có throughput cao nhất mỗi hướng (từ live_top.json).Top 10 IPs by throughput per direction (from live_top.json). |
| Top PPS In / Out | Tương tự nhưng theo packet-per-second.Same, but by packets-per-second. |
| Top IXP BPS In / Out | Chỉ xét IP quốc tế đi qua peering IXP.Only international IPs crossing an IXP peer. |
| Top ASN IXP / NIX | Top ASN kèm tên tổ chức (Google, Cloudflare, …). Ẩn khi geo.ixp_enabled=0 hoặc geo.nix_enabled=0.Top ASNs with organization name (Google, Cloudflare, …). Hidden when geo.ixp_enabled=0 or geo.nix_enabled=0. |
Mẹo: giữ chuột trên biểu đồ để đọc giá trị chính xác tại từng thời điểm. Cuộn chuột để zoom in/out. Nhấp đôi để reset view. Tip: hover the chart to read exact values at any moment. Scroll to zoom, double-click to reset the view.
4 · Cấu hình Sensor 4 · Configuring sensors
Mỗi sensor là một UDP listener riêng, gắn với một exporter (router / switch). Vào trang /sensors để thêm mới, sửa, hoặc xóa sensor.
Each sensor is its own UDP listener bound to one exporter (router / switch). Visit /sensors to add, edit, or remove sensors.
Các trườngFields
| TrườngField | Giải thíchExplanation |
|---|---|
name | Duy nhất; dùng trong tag InfluxDB và hiển thị trên UI.Unique; used as InfluxDB tag and displayed in the UI. |
listen_ip | IP nội bộ nhận UDP. 0.0.0.0 = mọi interface.Local IP that receives UDP. 0.0.0.0 = any interface. |
listen_port | Port UDP. Mặc định: 6343 (sFlow), 2055 (NetFlow), 4739 (IPFIX).UDP port. Defaults: 6343 (sFlow), 2055 (NetFlow), 4739 (IPFIX). |
protocol | sflow · nfv5 · nfv9 · ipfix |
exporter_ip | Lọc chỉ nhận gói từ router này. 0.0.0.0 = wildcard (mọi exporter).Accepts packets only from this exporter. 0.0.0.0 = wildcard (any exporter). |
ip_validation | Bật để drop flow có IP không thuộc zone — chống spoofing tổng hợp.Drop flows whose IP is outside every zone — aggregate anti-spoofing. |
as_validation | Bật để drop flow có AS trong dải private.Drop flows whose AS sits in the private range. |
perf_mode | low / balanced / high — ảnh hưởng số goroutine và buffer.affects goroutine count and buffer size. |
-
Bật nhận flow trên routerEnable flow export on the router
Ví dụ Cisco IOS-XR:For example, on Cisco IOS-XR:
flow exporter-map netscope version v9 transport udp 2055 destination 10.0.0.10 ! sampler-map s-1k random 1 out-of 1024 ! interface HundredGigE0/0/0/0 flow ipv4 monitor default sampler s-1k ingress flow ipv6 monitor default sampler s-1k ingress -
Thêm sensor trên UIAdd the sensor in the UI
Chọn đúng protocol, khai báo exporter IP (chính là IP của router), đặt tên mô tả (ví dụ
core-rt-hn-1).Pick the right protocol, set the exporter IP (the router's IP), and give it a descriptive name (e.g.core-rt-hn-1). -
Gán zoneAttach a zone
Mỗi sensor có thể gắn nhiều zone (qua bảng
sensor_ipzone). Zone quyết định IP nào được tính vào biểu đồ.A sensor can be tied to multiple zones (via thesensor_ipzonejunction). Zones decide which IPs count toward the charts. -
Kiểm traVerify
Ngay sau khi lưu (không cần restart), mở
/sensors/{id}— biểu đồ per-sensor phải có số > 0 trong vòng 10 giây.Right after save (no restart needed), open/sensors/{id}— the per-sensor chart should show non-zero within ten seconds.
Hot-reload: không cần restart sfsensor khi thêm / sửa sensor. Tiến trình reload tự động mỗi 30 giây hoặc khi nhận SIGHUP.
Hot-reload: you don't need to restart sfsensor when adding or editing a sensor. It reloads every 30 seconds or on SIGHUP.
5 · Quản lý IP Zone 5 · Managing IP zones
Zone là cách bạn mô tả "dải IP nào là của mình". Không có zone thì NetScope không biết flow nào là "in zone" — các biểu đồ per-node sẽ trống. Zones tell NetScope which IP ranges you own. Without zones, the system doesn't know which flows are "in-zone" — per-node charts will stay empty.
Cấu trúc câyTree structure
Zone chứa node. Node là prefix (CIDR) có thể lồng nhau:Zones contain nodes. Nodes are CIDR prefixes that can nest:
# Zone: Customer Network
203.0.113.0/24 # graphs=on, accounting=on
├─ 203.0.113.0/26 # sub-node cho nhóm khách A
└─ 203.0.113.64/26 # sub-node cho nhóm khách B
2001:db8::/32 # graphs=on, accounting=on
└─ 2001:db8:1::/48 # branch office
Lookup dùng longest-prefix match — IP sẽ khớp với node cụ thể nhất.Lookups use longest-prefix match — an IP resolves to the most specific node.
Cờ inheritInheritance flags
graphs(bit 0) — node có hiển thị trên biểu đồ per-node không.whether the node appears in per-node charts.accounting(bit 1) — node có tính vào tổng bps không.whether it contributes to totals.
Mặc định cả hai bật. Node con kế thừa từ node cha; bạn có thể override ở node con.Both default to on. Children inherit from parents; you can override at the child level.
Bulk import: với list CIDR lớn, dùng POST /api/v1/zone/{id}/nodes/bulk — nhanh hơn nhiều lần thay vì thêm từng node.
Bulk import: for large CIDR lists, call POST /api/v1/zone/{id}/nodes/bulk — much faster than adding one node at a time.
6 · Tra cứu IP 6 · Looking up an IP
Trang /ip cho phép tìm một IP hoặc subnet và xem biểu đồ lịch sử. Hỗ trợ cả IPv4 và IPv6.
The /ip page lets you find an IP or subnet and inspect historical charts. IPv4 and IPv6 are both supported.
Ba chế độ xemThree view modes
- Host — bps/pps của 1 IP đơn lẻ.bps/pps for a single IP.
- CIDR — cộng dồn cả subnet.summed over a subnet.
- Host + Proto — breakdown theo protocol (TCP, UDP, …).broken down by protocol (TCP, UDP, …).
Auto-bin theo rangeAuto-bin by range
Để biểu đồ không bị nghẽn khi zoom xa, NetScope tự chọn group-by theo khoảng thời gian:To keep charts responsive when you zoom out, NetScope auto-picks the group-by:
| Range | GROUP BY |
|---|---|
| ≤ 1h | 5s |
| ≤ 6h | 30s |
| ≤ 24h | 2m |
| ≤ 7d | 15m |
| > 7d | 1h |
7 · Xem flow trực tiếp 7 · Live flow view
Trang /flows kết nối SSE tới /api/v1/live/flows và stream những flow gần nhất (ring buffer 2000). Hữu ích khi điều tra sự cố hoặc kiểm tra router mới lắp.
The /flows page opens an SSE connection to /api/v1/live/flows and streams the most recent flows (2000-entry ring buffer). Handy when you're investigating an incident or verifying a new router.
| TS | SRC | DST | PROTO | L4 | BYTES | GEO |
|---|---|---|---|---|---|---|
| 12:45:02.118 | TCP | HTTPS | 1.8 MB | US→VN ixp | ||
| 12:45:02.094 | UDP | DNS | 182 B | VN→US ixp | ||
| 12:45:01.972 | TCP | HTTPS | 512 KB | VN→VN nix | ||
| 12:45:01.845 | TCP | HTTPS | 3.2 MB | VN→VN nix | ||
| 12:45:01.720 | TCP | HTTP | 1.1 MB | VN→VN nix |
Bộ lọcFilters
- Sensor — chỉ xem flow từ 1 sensor.Sensor — restrict to one sensor.
- Protocol — TCP / UDP / ICMP.Protocol — TCP / UDP / ICMP.
- IP / CIDR — khớp src hoặc dst.IP / CIDR — match src or dst.
- Port — src hoặc dst.Port — src or dst.
SSE reconnect: mỗi lần mất mạng hoặc đổi filter, trình duyệt sẽ tự kết nối lại và tiếp tục nhận flow mới. SSE reconnect: on network drops or filter changes, the browser automatically reopens the stream.
8 · Cảnh báo & Thông báo 8 · Alerts & notifications
Hệ thống alert có 3 khái niệm: Channel (nơi gửi — Telegram / webhook), Rule (điều kiện), và History (nhật ký event). The alert system has three concepts: Channel (destination — Telegram / webhook), Rule (condition), and History (event log).
Channel
| Type | Cấu hìnhConfig |
|---|---|
telegram | bot_token + chat_id |
webhook | url + optional secret (ký HMACHMAC signed) |
Nhấn Test gửi thử một message — không ghi vào history.Hit Test to send a ping — it doesn't get recorded in history.
Rule
{
"name": "egress saturation",
"target_type": "sensor", // global | subnet | ip | sensor
"target_value": "5", // sensor_id=5
"metric": "bps_out",
"threshold": 9000000000, // 9 Gbps
"sustained_s": 60, // phải vượt 60s mới fire
"cooldown_s": 300, // im lặng 5 phút sau khi fire
"notify_resolve": true,
"channel_id": 1
}
Vòng đờiLifecycle
State machine:State machine:
ok ──breach──▶ pending ──sustained──▶ firing ──✉ FIRING──▶ (cooldown)
▲ │
└─resolved sustained┘──▶ ok ──✉ RESOLVED
Rule per-IPPer-IP rules
Với target_type=ip hoặc subnet, engine theo dõi từng IP. Khi nhiều IP cùng fire, alert được gom lại — tối đa 10 IP mỗi message Telegram. IP không thấy trong 90 giây được garbage-collect khỏi state.With target_type=ip or subnet, the engine tracks each IP individually. When many fire together, alerts are batched — max 10 IPs per Telegram message. IPs unseen for 90 seconds are garbage-collected from state.
Template message: trường message_template dùng cú pháp Go text/template với các biến {{.RuleName}}, {{.Metric}}, {{.Value}}, {{.Target}}. Để trống sẽ dùng template mặc định.
Message templates: the message_template field uses Go text/template with {{.RuleName}}, {{.Metric}}, {{.Value}}, {{.Target}}. Leave empty for the built-in template.
9 · Quản lý người dùng 9 · User management
Ba vai trò, phân cấp: Three hierarchical roles:
| Role | QuyềnPermission |
|---|---|
readonly | Xem dashboard, chart, flow; không sửa gì.View dashboards, charts, flows; no writes. |
operator | Như readonly, thêm quyền sửa sensor, zone, alert rule.Readonly plus editing sensors, zones, alert rules. |
admin | Full quyền: user, settings, license, retention, update.Full access: users, settings, license, retention, updates. |
Tạo người dùngCreate a user
- Vào
/users→ + New user.Go to/users→ + New user. - Nhập username (lowercase, 3-32 ký tự) và mật khẩu tạm thời.Enter a username (lowercase, 3–32 chars) and a temporary password.
- Chọn role — có thể đổi sau.Pick a role — editable later.
- Người dùng đăng nhập lần đầu, bắt buộc đổi mật khẩu.On first sign-in the user must change the password.
10 · Cài đặt hệ thống 10 · System settings
Trang /settings gom 3 nhóm: API, GeoIP, và License.
The /settings page groups three areas: API, GeoIP, and License.
API
api.rate_limit_rps— mặc định 60. Giới hạn mỗi API key.default 60. Per-key rate.api.rate_limit_burst— mặc định 120. Token bucket.default 120. Token bucket burst.api.audit_retention_days— mặc định 30. Retention bảngapi_access_log.default 30. Retention for theapi_access_logtable.
GeoIP
Bạn có thể upload file GeoLite2-Country.mmdb và GeoLite2-ASN.mmdb trực tiếp, hoặc bật auto-update bằng cách nhập maxmind_license_key. Auto-update chạy mỗi thứ Tư hàng tuần trong goroutine nền.You can upload GeoLite2-Country.mmdb and GeoLite2-ASN.mmdb directly, or enable auto-update by entering a maxmind_license_key. Auto-update fires every Wednesday in a background goroutine.
geo.ixp_enabled— tắt nếu bạn không quan tâm traffic quốc tế; các widget IXP sẽ ẩn.disable if you don't care about international traffic; IXP widgets are hidden.geo.nix_enabled— tương tự cho NIX.same for NIX.
License
Xem mục License bên dưới.See the License section below.
11 · Lưu trữ & retention 11 · Storage & retention
Trang /storage cho phép đặt thời gian giữ dữ liệu trong InfluxDB. Mặc định là 30 ngày cho số liệu per-IP, 180 ngày cho số liệu aggregate.
The /storage page controls how long data sticks around in InfluxDB. Defaults are 30 days for per-IP metrics, 180 days for aggregates.
| Measurement | Tags | Fields |
|---|---|---|
ip | ipnode, decoder, direction, sensor | bps, pps |
ip_host | addr, direction, sensor | bps, pps |
ip_host_proto | addr, decoder, direction, sensor | bps, pps |
geo | class, direction, sensor | bps, pps |
ip_geo | ipnode, class, direction, sensor | bps, pps |
ip_host_geo | addr, class, direction, sensor | bps, pps |
ip_geo_proto | ipnode, class, decoder, direction, sensor | bps, pps |
ip_host_geo_proto | addr, class, decoder, direction, sensor | bps, pps |
asn | asn, class, direction, sensor | bps, pps |
Giữ ngắn giúp đỡ đĩa: measurement ip_host* tăng nhanh theo số IP unique. Trên hệ thống > 1M IP / ngày, giữ 7-14 ngày là thực tế hơn.
Shorter retention saves disk: ip_host* measurements explode with unique IP count. For > 1M unique IPs / day, 7–14 days is more realistic.
12 · License 12 · License
Key có định dạng SFLOW-{payload-base64}.{hmac-hex} và lưu trong app_config.
Keys are formatted as SFLOW-{payload-base64}.{hmac-hex} and stored in app_config.
| Mode | Điều kiệnCondition | ReadOnly |
|---|---|---|
trial | Chưa có key, ≤ 30 ngày từ lần chạy đầu.No key, ≤ 30 days since first run. | No |
licensed | Key valid, chưa hết hạn.Valid key, not expired. | No |
grace | Hết hạn ≤ 30 ngày.Expired ≤ 30 days. | No |
expired | Hết hạn > 30 ngày.Expired > 30 days. | Yes |
Khi ReadOnly, mọi endpoint write trả HTTP 403. Dashboard vẫn xem được; bạn có thể dán key mới trong /settings để thoát ngay.When in ReadOnly, every write endpoint returns HTTP 403. The dashboard stays visible; paste a fresh key in /settings to recover immediately.
Anti-rollback: hệ thống ghi last_seen_at mỗi giờ. Nếu đồng hồ server lùi > 5 phút so với giá trị này, license tự chuyển sang expired. Luôn bật NTP.
Anti-rollback: the system writes last_seen_at hourly. If the system clock goes back more than 5 minutes, the license flips to expired. Always run NTP.
13 · Cập nhật phiên bản 13 · Upgrades
NetScope có daemon sfupdater chạy dưới quyền root, lắng nghe qua Unix socket /run/sfupdater.sock. Bạn điều khiển từ UI /settings → Updates (chỉ admin).
NetScope ships with an sfupdater daemon running as root, controlled through the Unix socket /run/sfupdater.sock. Drive it from /settings → Updates (admin only).
- Check
So sánh version hiện tại (
/opt/sflow/VERSION) với mirror.Compare the installed version (/opt/sflow/VERSION) with the mirror. - Download & verify
Tải binary + UI + schema, verify SHA-256 từng file.Pull binaries, UI and schema, verify SHA-256 for each file.
- Apply
Stop → install atomic (
.newrename) → migrate DB → start. Rollback tự động nếu lỗi bước 5-8.Stop → atomic install (.newrename) → migrate DB → start. Auto-rollback if steps 5–8 fail. - Status
UI poll
/api/v1/update/statusđể hiển thị log từng bước.The UI polls/api/v1/update/statusto show step-by-step logs.
14 · External API & API Keys 14 · External API & API keys
API key dùng khi bạn muốn hệ thống bên ngoài query NetScope (ví dụ dashboard Grafana, script báo cáo hàng tuần). API keys are for external systems that query NetScope (Grafana dashboards, weekly report scripts).
Tạo keyCreating a key
- Vào
/settings→ API keys → + New key.Open/settings→ API keys → + New key. - Đặt tên mô tả, chọn scope:
read·write·admin.Give it a descriptive name, pick a scope:read·write·admin. - Đặt rate (mặc định 60 rps / 120 burst) và TTL (tùy chọn).Set a rate (default 60 rps / 120 burst) and TTL (optional).
- Copy key — key chỉ hiện một lần, sau đó DB chỉ lưu hash SHA-256.Copy the key — it shows only once; the DB stores only the SHA-256 hash.
Format: sfk_ + 24 ký tự base62 (143 bit entropy). Gửi kèm request theo 1 trong 2 cách:Format: sfk_ + 24 base62 chars (143 bits of entropy). Send it one of two ways:
# Bearer header (recommended)
curl -H "Authorization: Bearer sfk_abcdef0123456789ABCDEF" \
https://netscope.example.com/api/external/v1/series
# Hoặc X-API-Key
curl -H "X-API-Key: sfk_abcdef0123456789ABCDEF" \
https://netscope.example.com/api/external/v1/series
Endpoint thường dùngFrequently used endpoints
| Method | Path | Mô tảDescription |
|---|---|---|
| GET | /api/v1/live/top | Top IP talker hiện tại.Top current IP talkers. |
| GET | /api/v1/live/top/asn | Top ASN hiện tại.Top current ASNs. |
| SSE | /api/v1/live/flows | Stream flow trực tiếp.Streaming flow feed. |
| GET | /api/v1/ip/host-series | Chuỗi thời gian cho 1 IP.Time series for one IP. |
| GET | /api/v1/series/global | Chuỗi global bps.Global bps time series. |
| POST | /api/v1/sensors | Tạo sensor mới (write).Create a sensor (write). |
| POST | /api/v1/zone/{id}/nodes/bulk | Thêm nhiều prefix cùng lúc.Bulk-add prefixes. |
| GET | /api/external/v1/openapi.yaml | OpenAPI spec đầy đủ (public).Full OpenAPI spec (public). |
Rate limitRate limits
Nếu vượt rate, server trả HTTP 429 với header Retry-After bằng giây. Client nên tôn trọng giá trị này.Exceeding the rate returns HTTP 429 with a Retry-After header in seconds. Clients should respect it.
Audit log ghi mỗi request vào api_access_log (method, path, status, duration, IP). Flush async mỗi 128 entries hoặc 500 ms; prune theo giờ.The audit log records each request into api_access_log (method, path, status, duration, IP). Async flush every 128 entries or 500 ms; pruned hourly.
15 · Khắc phục sự cố 15 · Troubleshooting
Biểu đồ trống hoặc phẳng lỳCharts empty or flat
-
Xem
/api/v1/health—tsdb_errornếu InfluxDB không kết nối được. Check/api/v1/health—tsdb_errorflags an InfluxDB issue. -
Kiểm tra sensor có nhận UDP không:
tcpdump -i any -n udp port 6343trên server. Verify UDP is arriving:tcpdump -i any -n udp port 6343on the server. -
Log sfsensor:
journalctl -u sfsensor -f— cảnh báo drop nếu worker không theo kịp. Check sfsensor logs:journalctl -u sfsensor -f— drop warnings mean the workers can't keep up. - Sensor có zone gán chưa? Không có zone match → flow bị bỏ qua hoàn toàn. Is a zone attached? Without a matching zone, flows are dropped entirely.
Top talker hiển thị IP nhưng không có biểu đồTop talker shows an IP but no chart
Có khả năng IP đó không nằm trong node nào. Vào /ip, nhập IP, xem trường Zone / Node. Nếu trống, bạn cần thêm node phù hợp trong /zones.Likely the IP is outside every node. Visit /ip, enter the address, check the Zone / Node field. If blank, add the right node in /zones.
Không nhận Telegram alertNo Telegram alerts
- Nhấn Test trên channel — nếu fail,
bot_tokenhoặcchat_idsai.Click Test on the channel — a failure meansbot_tokenorchat_idis wrong. - Bot phải được add vào group và có quyền post message.The bot must be added to the group and allowed to post messages.
- Kiểm tra
/notifications→ History: ôok=false+errorsẽ nói chính xác lỗi gì.Inspect/notifications→ History:ok=falserows include anerrorcolumn.
Licence chuyển expired đột ngộtLicense flips to expired unexpectedly
Kiểm tra timedatectl. Nếu server vừa đồng bộ NTP về quá khứ, anti-rollback đã trigger. Đồng bộ NTP rồi apply lại key.Run timedatectl. If the clock just synced backwards, anti-rollback triggered. Sync NTP, then re-apply the key.
Nhật ký hữu íchUseful logs
journalctl -u sfsensor -f # decoder / aggregator
journalctl -u sfconsole -f # HTTP API
journalctl -u sftsdb -f # InfluxDB schema bootstrap
journalctl -u sfupdater -f # updater
ls -la /opt/sflow/spool/ # wgflow archives & live JSON
sfflowdump /opt/sflow/spool/wgflow.* | head # dump flow archive
16 · Thuật ngữ 16 · Glossary
| Thuật ngữTerm | Định nghĩaDefinition |
|---|---|
| bps / pps | Bits per second / packets per second — quy ra từ bin 5 giây.Bits/packets per second, derived from the 5-second bin. |
| exporter | Thiết bị phát flow (router / switch).The device that emits flows (router / switch). |
| collector | Tiến trình nhận flow — ở đây là sfsensor.The process receiving flows — here, sfsensor. |
| LPM | Longest Prefix Match — tìm prefix cụ thể nhất chứa 1 IP.Longest Prefix Match — finding the most-specific prefix containing an IP. |
| FlowRecord | Cấu trúc chuẩn hóa nội bộ, mọi decoder output về nó.The internal canonical struct; every decoder outputs it. |
| SSE | Server-Sent Events — push 1 chiều server→browser, dùng cho live flows và alert stream.Server-Sent Events — one-way server→browser push, used for live flows and alert streams. |
| wgflow.* | File archive binary chứa raw flow, xoay vòng 5 phút.Binary archive of raw flows, rotated every 5 minutes. |
Cần hỗ trợ? Liên hệ quản trị hệ thống nội bộ hoặc mở ticket kèm log từ journalctl 5 phút gần nhất.
Need help? Contact your internal admin or open a ticket with the last 5 minutes of journalctl output.