Prometheus 從新標籤正則表達式
容許在採集以前對任何目標及其標籤進行修改ui
• 重命名標籤名
• 刪除標籤
• 過濾目標spa
action:從新標籤動做code
relabel_configs blog
relable_configs: # 源標籤 [ source_labels: '[' <labelname> [, ...] ']' ] # 多個源標籤時鏈接的分隔符 [ separator: <string> | default = ; ] # 從新標記的標籤 [ target_label: <labelname> ] # 整則表達式匹配源標籤的值 [ regex: <regex> | default = (.*) ] # 用的少,佔時略 [ modulus: <uint64> ] # 替換正則表達式匹配的分組,分組引用 $1,$2,$3,.... [ replacement: <string> | default = $1 ] # 基於正則表達式匹配執行的操做 [ action: <relabel_action> | default = replace ]