Skip to content

Commit

Permalink
[message] tap_interface_regex column add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
SongZhen0704 authored and sharang committed Aug 25, 2022
1 parent 1540b59 commit 49ade95
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 4 deletions.
9 changes: 8 additions & 1 deletion message/trident.proto
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,14 @@ message Config {
optional uint32 sync_interval = 4 [default = 60];
optional uint32 stats_interval = 5 [default = 60];
optional uint64 global_pps_threshold = 6 [default = 200000];
optional string tap_interface_regex = 8 [default = "^(tap|cali|veth|eth|en[ospx]).*"];
// qemu: tap.*
// localhost: lo
// common nic: eth|en[ospx].*
// flannel: veth.*
// calico: cali.*
// cilium: lxc.*
// kube-ovn: [0-9a-f]+_h$
optional string tap_interface_regex = 8 [default = "^(tap.*|cali.*|veth.*|eth.*|en[ospx].*|lxc.*|lo|[0-9a-f]+_h)$"];
optional string host = 9; // override statsd host tag
optional bool rsyslog_enabled = 10 [default = true];
optional uint32 output_vlan = 11 [default = 0];
Expand Down
2 changes: 1 addition & 1 deletion server/controller/common/vtap_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ var (
RsyslogEnabled = 1
MaxTxBandwidth = int64(0)
BandwidthProbeInterval = 10
TapInterfaceRegex = "^(tap.*|cali.*|veth.*|eth.*|en[ospx].*|lxc.*|lo)$"
TapInterfaceRegex = "^(tap.*|cali.*|veth.*|eth.*|en[ospx].*|lxc.*|lo|[0-9a-f]+_h)$"
MaxEscapeSeconds = 3600
Mtu = 1500
OutputVlan = 0
Expand Down
11 changes: 9 additions & 2 deletions server/controller/service/vtap_group_config_example.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,15 @@ thread_threshold: 500
process_threshold: 10
# 基础配置参数
# 采集网口,默认值:^(tap.*|cali.*|veth.*|eth.*|en[ospx].*|lxc.*|lo)$,长度范围[0, 65535]
tap_interface_regex: ^(tap.*|cali.*|veth.*|eth.*|en[ospx].*|lxc.*|lo)$
# 采集网口,默认值:^(tap.*|cali.*|veth.*|eth.*|en[ospx].*|lxc.*|lo|[0-9a-f]+_h)$,长度范围[0, 65535]
# qemu: tap.*
# localhost: lo
# common nic: eth|en[ospx].*
# flannel: veth.*
# calico: cali.*
# cilium: lxc.*
# kube-ovn: [0-9a-f]+_h$#
tap_interface_regex: ^(tap.*|cali.*|veth.*|eth.*|en[ospx].*|lxc.*|lo|[0-9a-f]+_h)$
# 流量过滤,默认值:空,表示全采集,长度范围[1, 512]
# 请参考BPF语法:https://biot.com/capstats/bpf.html
capture_bpf:
Expand Down

0 comments on commit 49ade95

Please sign in to comment.