Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在 Splunk 中,如何为柱形图中的条形设置固定颜色?
如果您正在查看 SimpleXML 仪表板,则需要添加如下内容。您的仪表板/图表上应该有一个编辑 XML 按钮。
以下示例使 ERROR 列始终为红色,WARN 列始终为黄色,依此类推。
<option name="charting.fieldColors"> {"ERROR": 0xFF0000, "WARN": 0xFF9900, "INFO":0x009900, "NULL":0xC4C4C0} </option>
请参阅https://docs.splunk.com/Documentation/Splunk/8.0.5/Viz/BuildandeditdashboardswithSimplifiedXML#Specify_custom_colors_for_fields_in_charts