Zabbix-Network-Weathermap icon indicating copy to clipboard operation
Zabbix-Network-Weathermap copied to clipboard

Change Traffic Load table

Open psmartins opened this issue 7 years ago • 2 comments
trafficstars

Prototype-X

Thank you for always answering my questions. Currently in my work we use Weathermap + Cacti to monitor network traffic. The Traffic Load table in the current system looks like this: blue 0-10% green 10-40% yellow 40-70% orange 70-80% red 80-90% brown 90-100%

When the link gets down the arrows turn black.

It is possible to change the mappyng.py script and somehow adapt it so that the Traffic Load table stays as it is used in my work today. If possible, what changes should I make

Thank you !

psmartins avatar Jan 31 '18 16:01 psmartins

Hi psmartins

The easy way to make the Traffic Load table similar, edit section palette in mapname.yaml

palette:               
- '#908C8C'       # RGB color arrow for down link
- '#FFFFFF'       # 0-1%
- '#8000FF'       # 1-10%
- '#0000FF'       # 10-25%
- '#00EAEA'       # 25-40%
- '#00FF00'       # etc ...
- '#FFFF00'
- '#FF9933'
- '#FF0000'

For blue 0-10%, set one colour for 0-1% and 1-10% For green 10-40%, set one colour for 10-25% and 25-40%

The other way edit source code in mapping.py:

  1. class Palette - change RGB colours
  2. class Table - change function draw_table -> range(0, 6), fix self.text, ...
  3. class Link -> function _fill_arrow -> tuple switch = ((0, 0, 1), (1, 1, 2), ... (0, 0, 1) - first digit this is index for palette list, last two digit this is interval like 0-0%

Prototype-X avatar Jan 31 '18 20:01 Prototype-X

Thank you

My map is getting really good

psmartins avatar Feb 01 '18 11:02 psmartins