This is a translation of the original English documentation page. Help us make it better.

1 Креирање ставке

Преглед

Да бисте креирали ставку на Zabbix корисничком интерфејсу, урадите следеће:

  • Идите на: Прикупљање податакаДомаћини
  • Кликните на Ставке у реду домаћина
  • Кликните на Креирај ставку у горњем десном углу екрана
  • Унесите параметре ставке у форму

Ставку можете креирати и отварањем постојеће, притиском на Дугме Клонирај, а затим сачувајте под другим именом.

Configuration

The Item tab contains general item attributes.

All mandatory input fields are marked with a red asterisk.

Parameter Description
Name Item name.
User macros are supported.
Type Item type. See individual item type sections.
Key Item key (up to 2048 characters).
The supported item keys can be found in individual item type sections.
The key must be unique within a single host.
If key type is 'Zabbix agent', 'Zabbix agent (active)' or 'Simple check', the key value must be supported by Zabbix agent or Zabbix server.
See also: the correct key format.
Type of information Type of data as stored in the database after performing conversions, if any.
Numeric (unsigned) - 64-bit unsigned integer
Note that a floating point value, if received for an integer item, will be trimmed from its decimal part.
Numeric (float) - 64-bit floating point number
This type will allow precision of approximately 15 digits and range from approximately -1.79E+308 to 1.79E+308 (with exception of PostgreSQL 11 and earlier versions).
Receiving values in scientific notation is also supported. E.g. 1.23E+7, 1e308, 1.1E-4.
Character - short text data
Log - long text data with optional log related properties (timestamp, source, severity, logeventid)
Text - long text data. See also text data limits.
Binary - binary number (supported for dependent items only). A binary number will be resolved to a static "binary value" string in Latest data; {ITEM.VALUE}, {ITEM.LASTVALUE} and expression macros will resolve to UNKNOWN.
For item keys that return data only in one specific format, matching type of information is selected automatically.
Host interface Select the host interface. This field is available when editing an item on the host level.
Units If a unit symbol is set, Zabbix will add postprocessing to the received value and display it with the set unit postfix.
By default, if the raw value exceeds 1000, it is divided by 1000 and displayed accordingly. For example, if you set bps and receive a value of 881764, it will be displayed as 881.76 Kbps.
The JEDEC memory standard is used for processing B (byte), Bps (bytes per second) units, which are divided by 1024. Thus, if units are set to B or Bps Zabbix will display:
1 as 1B/1Bps
1024 as 1KB/1KBps
1536 as 1.5KB/1.5KBps
Special processing is used if the following time-related units are used:
unixtime - translated to "yyyy.mm.dd hh:mm:ss". To translate correctly, the received value must be a Numeric (unsigned) type of information.
uptime - translated to "hh:mm:ss" or "N days, hh:mm:ss"
For example, if you receive the value as 881764 (seconds), it will be displayed as "10 days, 04:56:04"
s - translated to "yyy mmm ddd hhh mmm sss ms"; parameter is treated as number of seconds.
For example, if you receive the value as 881764 (seconds), it will be displayed as "10d 4h 56m"
Only 3 upper major units are shown, like "1m 15d 5h" or "2h 4m 46s". If there are no days to display, only two levels are displayed - "1m 5h" (no minutes, seconds or milliseconds are shown). Will be translated to "< 1 ms" if the value is less than 0.001.
Note that if a unit is prefixed with !, then no unit prefixes/processing is applied to item values. See unit conversion.
Update interval Retrieve a new value for this item every N seconds. Maximum allowed update interval is 86400 seconds (1 day).
Time suffixes are supported, e.g., 30s, 1m, 2h, 1d.
User macros are supported.
A single macro has to fill the whole field. Multiple macros in a field or macros mixed with text are not supported.
Note: The update interval can only be set to '0' if custom intervals exist with a non-zero value. If set to '0', and a custom interval (flexible or scheduled) exists with a non-zero value, the item will be polled during the custom interval duration.
Note that the first item poll after the item became active or after update interval change might occur earlier than the configured value.
New items will be checked within 60 seconds of their creation, unless they have Scheduling or Flexible update interval and the Update interval is set to 0.
An existing passive item can be polled for value immediately by pushing the Execute now button.
Custom intervals You can create custom rules for checking the item:
Flexible - create an exception to the Update interval (interval with different frequency)
Scheduling - create a custom polling schedule.
For detailed information see Custom intervals.
Time suffixes are supported in the Interval field, e.g., 30s, 1m, 2h, 1d.
User macros are supported.
A single macro has to fill the whole field. Multiple macros in a field or macros mixed with text are not supported.
Timeout Set the item check timeout (available for supported item types). Select the timeout option:
Global - proxy/global timeout is used (displayed in the grayed out Timeout field);
Override - custom timeout is used (set in the Timeout field; allowed range: 1 - 600s). Time suffixes, e.g. 30s, 1m, and user macros are supported.
Clicking the Timeouts link allows you to configure proxy timeouts or global timeouts (if a proxy is not used). Note that the Timeouts link is visible only to users of Super admin type with permissions to AdministrationGeneral or AdministrationProxies frontend sections.
History Select either:
Do not store - item history is not stored. Useful for master items if only dependent items need to keep history.
This setting cannot be overridden by global housekeeper settings.
Store up to - specify the duration of keeping detailed history in the database (1 hour to 25 years). Older data will be removed by the housekeeper. Stored in seconds.
Time suffixes are supported, e.g., 2h, 1d. User macros are supported.
The Store up to value can be overridden globally in Administration → Housekeeping.
If a global overriding setting exists, a green info icon is displayed. If you position your mouse on it, a warning message is displayed, e.g., Overridden by global housekeeper settings (1d).
It is recommended to keep the recorded values for the smallest possible time to reduce the size of value history in the database. Instead of storing a long history of values, you can store longer data of trends.
See also History and trends.
Trends Select either:
Do not store - trends are not stored.
This setting cannot be overridden by global housekeeper settings.
Store up to - specify the duration of keeping aggregated (hourly min, max, avg, count) history in the database (1 day to 25 years). Older data will be removed by the housekeeper. Stored in seconds.
Time suffixes are supported, e.g., 24h, 1d. User macros are supported.
The Store up to value can be overridden globally in Administration → Housekeeping.
If a global overriding setting exists, a green info icon is displayed. If you position your mouse on it, a warning message is displayed, e.g., Overridden by global housekeeper settings (7d).
Note: Keeping trends is not available for non-numeric data - character, log and text.
See also History and trends.
Value mapping Apply value mapping to this item. Value mapping does not change received values, it is for displaying data only.
It works with Numeric(unsigned), Numeric(float) and Character items.
For example, "Windows service states".
Log time format Available for items of type Log only. Supported placeholders:
* y: Year (1970-2038)
* M: Month (01-12)
* d: Day (01-31)
* h: Hour (00-23)
* m: Minute (00-59)
* s: Second (00-59)
If left blank, the timestamp will not be parsed.
For example, consider the following line from the Zabbix agent log file:
" 23480:20100328:154718.045 Zabbix agent started. Zabbix 1.8.2 (revision 11211)."
It begins with six character positions for PID, followed by date, time, and the rest of the line.
Log time format for this line would be "pppppp:yyyyMMdd:hhmmss".
Note that "p" and ":" chars are just placeholders and can be anything but "yMdhms".
Populates host inventory field You can select a host inventory field that the value of item will populate. This will work if automatic inventory population is enabled for the host.
This field is not available if Type of information is set to 'Log'.
Description Enter an item description. User macros are supported.
Enabled Mark the checkbox to enable the item so it will be processed.
Latest data Click on the link to view the latest data for the item.
This link is only available when editing an already existing item.

Item type specific fields are described on corresponding pages.

When editing an existing template level item on a host level, a number of fields are read-only. You can use the link in the form header and go to the template level and edit them there, keeping in mind that the changes on a template level will change the item for all hosts that the template is linked to.

The Tags tab allows to define item-level tags.

Предобрада вредности ставке

Картица Предобрада омогућава дефинисање правила трансформације за примљене вредности.

Тестирање

Да бисте извршили тестирање ставки, уверите се да је системско време на серверу и проксију синхронизовано. У случају да време сервера касни, тестирање ставки може вратити поруку о грешци "Задатак је истекао". Међутим, подешавање различитих временских зона на серверу и проксију неће утицати на резултат тестирања.

Могуће је тестирати ставку и, ако је правилно конфигурисано, добити стварну вредност заузврат. Тестирање се може обавити чак и пре него што се ставка сачува.

Тестирање је доступно за ставке домаћина и шаблона, прототипове ставки и правила откривања ниског нивоа. Тестирање није доступно за активне ставке.

Тестирање ставки је доступно за следеће типове пасивних ставки:

  • Zabbix агент
  • SNMP агент (v1, v2, v3)
  • IPMI агент
  • SSH провере
  • Telnet провере
  • JMX агент
  • Једноставне провере (осим icmpping*, vmware.* ставки)
  • Zabbix интерне
  • Израчунате ставке
  • Спољашње провере
  • Монитор базе података
  • HTTP агент
  • Скрипта
  • Прегледач

Да бисте тестирали ставку, кликните на дугме Тестирај на дну форме за конфигурацију ставке. Имајте на уму да ће дугме Тестирај бити онемогућено за ставке које се не могу тестирати (као што су активне провере, искључене једноставне провере).

Образац за тестирање ставке има поља за потребне параметре домаћина (адреса домаћина, порт, тест са сервером/проксијем (име проксија)) и детаље специфичне за ставку (као што су SNMPv2 заједница или SNMPv3 безбедносни акредитиви). Ова поља су контекстуално свесна:

  • Вредности су унапред попуњене када је то могуће, тј. за ставке које захтевају агента, узимањем информација из изабраног интерфејса агента домаћина
  • Вредности се морају ручно попунити за ставке шаблона
  • Вредности макроа у обичном тексту се решавају
  • Поља где је вредност (или део вредности) тајни или Vault макро су празна и морају се унети ручно. Ако било који параметар ставке садржи тајну вредност макроа, приказује се следећа порука упозорења: "Ставка садржи кориснички дефинисане макрое са тајним вредностима. Вредности ових макроа треба унети ручно."
  • Поља су онемогућена када нису потребна у контексту ставке типа (нпр. поље за адресу домаћина и поље за прокси су онемогућена за израчунате ставке)

Да бисте тестирали ставку, кликните на Преузми вредност. Ако се вредност успешно преузме, попуниће се поље Вредност, померајући тренутну вредност (ако постоји) у поље Претходна вредност, а истовремено ће се израчунати и поље Претх. време, тј. временска разлика између две вредности (кликови) и покушати да се открије EOL секвенца и пребаци на CRLF ако се открије "\n\r" у преузетој вредности.

Вредности преузете са домаћина и резултати тестирања се скраћују на максималну величину од 512KB када се шаљу на кориснички интерфејс. Ако је резултат скраћен, приказује се икона упозорења. Опис упозорења се приказује када пређете мишем преко њега. Имајте на уму да се подаци већи од 512KB и даље у потпуности обрађују од стране Zabbix сервера.

Ако је конфигурација нетачна, приказује се порука о грешци која описује могући узрок.

Успешно преузета вредност са домаћином такође се може користити за тестирање корака претходне обраде.

Дугмад форме

Дугмад на дну форме омогућавају извршавање неколико операција.

Додај ставку. Ово дугме је доступно само за нове ставке.
Ажурирај својства ставке.
Креирај другу ставку на основу својстава тренутне ставке.
Одмах изврши проверу нове вредности ставке. Подржано само за пасивне провере (погледајте више детаља).
Напомена да се приликом тренутне провере вредности кеш конфигурације не ажурира, па вредност неће одражавати најновије измене конфигурације ставке.
Тестирајте да ли је конфигурација ставке исправна добијањем вредности.
Обришите историју и трендове ставке.
Обришите ставку.
Откажите уређивање својстава ставке.

Ограничења текстуалних података

Ограничења текстуалних података зависе од базе података. Пре чувања текстуалних вредности у бази података, оне се скраћују да би се подударале са ограничењем типа вредности базе података:

Database Type of information
Character Log Text
MySQL 255 characters 65536 bytes 65536 bytes
PostgreSQL 255 characters 65536 characters 65536 characters
SQLite (only Zabbix proxy) 255 characters 65536 characters 65536 characters

Ограничење прилагођене скрипте

Доступна дужина прилагођене скрипте зависи од коришћене базе података:

Database Limit in characters Limit in bytes
MySQL 65535 65535
PostgreSQL 65535 not limited
SQLite (only Zabbix proxy) 65535 not limited

Неподржане ставке

Неподржане ставке се пријављују као ставке са статусом Није подржано и поново се проверавају у свом стандардном Интервалу ажурирања.

Ставка постаје неподржана ако се њена вредност не може преузети из неког разлога (нпр. грешка у повезивању, нема конфигурисаних анкетара за обраду ставке). Поред тога, ставке које не примају историјске податке остају у статусу Није подржано. Ово је очекивано понашање — ставка прелази у статус Нормално само када прими нове, валидне историјске податке.

Као и проблеми, неподржане ставке се поново процењују само када се приме нови подаци — чак и ако више нема доступних историјских података за ту ставку. Другим речима, ставке и окидачи мењају своје стање искључиво након пријема нових података. Међутим, ако израз окидача укључује функцију датум и време и/или nodata(), окидач ће се поново израчунавати сваких 30 секунди (погледајте triggers calculation time за детаље).