Zabbix lack of free swap space windows

I have several Windows Server 2012 Virtual Machines, which are monitored by zabbix 2.4. The zabbix throws "Lack of free swap space" for some VMs, but there are disk and memory free on these machine...

That is one solution for the problem. Unfortunately for us, we have many Windows servers and leave their pagefile (swap space) to be managed by Windows.

When Windows manages the pagefile, it leaves the pagefile size alone even sometimes filled with 0 bytes free until some program requests more memory and then if it has space on the pagefile drive, it will grow the size of the pagefile providing more free pagefile space.

This confuses the «simple» Zabbix alarm. It sees, for example, a 1.7GB page file with 0 bytes free and throws an alarm. It didn’t see that Windows was managing the pagefile and the drive had plenty of disk space available for pagefile growth.

It’d be great if Zabbix could (psuedo code follows):
IF «Windows is managing the pagefile» THEN
IF
pagefile free space % is lower than threshold
AND
drive containing pagefile has less free space than 2nd threshold
THEN
throw trigger (send alarm)
ELSE #assumes fixed pagefile size on a drive
IF
pagefile free space % is lower than threshold
THEN
throw trigger (send alarm)
FI

This trigger complexity is beyond my Zabbix skill rating.
If anyone has suggestions on how to implement this it would greatly help.
(We chase 4 to 5 production level swap space alarms each day. Correction, ignore. Which scares us and should scare Zabbix developers. Crying wolf is not a good thing.)

Bill

Farik

(@f-yakhyaev)

Trusted Member

Присоединился: 4 года назад

Сообщения: 71

Topic starter
19.11.2018 13:10  

Добрый день знатоки данного форума. Нуждаюсь в вашей помощи. 

Есть zabbix сервер. Относительно недавно познакомился с данной системой мониторинга. 

Есть так же сервер Unit на нем 5 виртуалок крутится.

И на каждой ВМ агенты забикс стоят.

Сегодня сообщение на одном из сереверов в забикс высветилось. 

Lack of free swap space on Server name

Заранее погуглив понял, что файл подкачки закончился. Полазив на сервере, всё гуд. Место на диске хватает. ОПеративка минимум 8гигов указана + динамическое расширение. занято примерно 5 гигов. 

Что, куда копать, что бы эту ошибку убрать? 

Прилагаю скрин события ТУТ

Помогите пж

Тема была редактированна 4 года назад от Farik

Zerox

(@zerox)

Prominent Member Admin

Присоединился: 9 лет назад

Сообщения: 806

19.11.2018 15:41  

Это не обязательно ошибка. Я частенько триггер на свап вообще отключаю, если не возникает проблем с тем, что свап кончился. Это информационное оповещение. 

Содержание

  1. «Lack of free swap space» on Windows Server
  2. 3 Answers 3
  3. Нехватка памяти на сервере
  4. High swap space usage less than 20 free windows

«Lack of free swap space» on Windows Server

I have several Windows Server 2012 Virtual Machines, which are monitored by zabbix 2.4. The zabbix throws «Lack of free swap space» for some VMs, but there are disk and memory free on these machines, and the Virtual Memory is set to OS Control on Windows.

What means «Lack of free swap space» on Windows Server? It’s disk space? RAM? Virtual Memory?

How can I resolve it?

photo

3 Answers 3

I have just resolved my item with the same error. It is related to the windows page file and in my case it was configured to be automatically managed by windows.

That is one solution for the problem. Unfortunately for us, we have many Windows servers and leave their pagefile (swap space) to be managed by Windows.

When Windows manages the pagefile, it leaves the pagefile size alone even sometimes filled with 0 bytes free until some program requests more memory and then if it has space on the pagefile drive, it will grow the size of the pagefile providing more free pagefile space.

This confuses the «simple» Zabbix alarm. It sees, for example, a 1.7GB page file with 0 bytes free and throws an alarm. It didn’t see that Windows was managing the pagefile and the drive had plenty of disk space available for pagefile growth.

It’d be great if Zabbix could (psuedo code follows): IF «Windows is managing the pagefile» THEN IF pagefile free space % is lower than threshold AND drive containing pagefile has less free space than 2nd threshold THEN throw trigger (send alarm) ELSE #assumes fixed pagefile size on a drive IF pagefile free space % is lower than threshold THEN throw trigger (send alarm) FI

This trigger complexity is beyond my Zabbix skill rating. If anyone has suggestions on how to implement this it would greatly help. (We chase 4 to 5 production level swap space alarms each day. Correction, ignore. Which scares us and should scare Zabbix developers. Crying wolf is not a good thing.)

Источник

Нехватка памяти на сервере

Не так давно я создавал тред, где переживал что апач с одним единственным сайтом из хмтл страничек отжирает всю память на серваке. Меня успокоили, что он отжирает свободную память под кеш, что свободная память все равно никак не используется и как только она понадобится, то апач мне её вернет. Прошло несколько месяцев, сервер никто не трогал. Сегодня установил zabbix и он сразу же выдал мне сообщение о проблеме Lack of free swap space on Zabbix server. Получается память для него так и не освободилась? Как с этим боротся? Не может же быть такого, что apache2 со статическим сайтом + zabbix отжирают 2 гигабайта оперативки?

99263: 1500135053

p

Не ужеле не можете посмотреть, кто сколько памяти отжирает?

7454:1466716480

99263: 1500135053

Апач всё отжирает. Поидее он должен отжирать неиспользуемую память для убыстрения работы, но вот сейчас память нужна, а он её не отдает

56330: 1401494366

Lack of free swap space (Отсутствие свободного пространства подкачки)

Не может же быть такого, что apache2 со статическим сайтом + zabbix отжирают 2 гигабайта оперативки?

Вот сколько памяти у тебя занято приложениями.

99263: 1500135053

Странно, VPS машину создали без свапа получается? теперь вручную его пилить

Источник

High swap space usage less than 20 free windows

Windows CPU by Zabbix agent active

For Zabbix version: 5.4 and higher

Refer to the vendor documentation.

No specific Zabbix configuration is required.

The critical threshold of the % Interrupt Time counter.

The threshold of the % Privileged Time counter.

The threshold of the Processor Queue Length counter.

The critical threshold of the CPU utilization in %.

There are no template links in this template.

CPU utilization in %

The Processor Information% Interrupt Time is the time the processor spends receiving and servicing

hardware interrupts during sample intervals. This value is an indirect indicator of the activity of

devices that generate interrupts, such as the system clock, the mouse, disk drivers, data communication

lines, network interface cards and other peripheral devices. This is an easy way to identify a potential

hardware failure. This should never be higher than 20%.

Context Switches/sec is the combined rate at which all processors on the computer are switched from one thread to another.

Context switches occur when a running thread voluntarily relinquishes the processor, is preempted by a higher priority ready thread, or switches between user-mode and privileged (kernel) mode to use an Executive or subsystem service.

It is the sum of ThreadContext Switches/sec for all threads running on all processors in the computer and is measured in numbers of switches.

There are context switch counters on the System and Thread objects. This counter displays the difference between the values observed in the last two samples, divided by the duration of the sample interval.

The Processor Information% Privileged Time counter shows the percent of time that the processor is spent

executing in Kernel (or Privileged) mode. Privileged mode includes services interrupts inside Interrupt

Service Routines (ISRs), executing Deferred Procedure Calls (DPCs), Device Driver calls and other kernel-mode

functions of the Windows® Operating System.

Processor DPC time is the time that a single processor spent receiving and servicing deferred procedure

calls (DPCs). DPCs are interrupts that run at a lower priority than standard interrupts. % DPC Time is a

component of % Privileged Time because DPCs are executed in privileged mode. If a high % DPC Time is

sustained, there may be a processor bottleneck or an application or hardware related issue that can

significantly diminish overall system performance.

The Processor Information% User Time counter shows the percent of time that the processor(s) is spent executing

The number of logical processors available on the computer.

The Processor Queue Length shows the number of threads that are observed as delayed in the processor Ready Queue

and are waiting to be executed.

Group Name Description Type Key and additional info
CPU CPU utilization ZABBIX_ACTIVE perf_counter_en[«Processor Information(_total)% Interrupt Time»]
CPU Context switches per second ZABBIX_ACTIVE perf_counter_en[«SystemContext Switches/sec»]
CPU CPU privileged time ZABBIX_ACTIVE perf_counter_en[«Processor Information(_total)% Privileged Time»]
CPU CPU DPC time ZABBIX_ACTIVE perf_counter_en[«Processor Information(_total)% DPC Time»]
CPU CPU user time ZABBIX_ACTIVE perf_counter_en[«Processor Information(_total)% User Time»]
CPU Number of cores ZABBIX_ACTIVE wmi.get[root/cimv2,»Select NumberOfLogicalProcessors from Win32_ComputerSystem»]
CPU CPU queue length ZABBIX_ACTIVE perf_counter_en[«SystemProcessor Queue Length»]

CPU utilization is too high. The system might be slow to respond.

«The CPU Interrupt Time in the last 5 minutes exceeds <$CPU.INTERRUPT.CRIT.MAX>%.»

The Processor Information% Interrupt Time is the time the processor spends receiving and servicing

hardware interrupts during sample intervals. This value is an indirect indicator of the activity of

devices that generate interrupts, such as the system clock, the mouse, disk drivers, data communication

lines, network interface cards and other peripheral devices. This is an easy way to identify a potential

hardware failure. This should never be higher than 20%.

Depends on:

— High CPU utilization (over <$CPU.UTIL.CRIT>% for 5m)

The CPU privileged time in the last 5 minutes exceeds <$CPU.PRIV.CRIT.MAX>%.

Depends on:

— CPU interrupt time is too high (over <$CPU.INTERRUPT.CRIT.MAX>% for 5m)

— High CPU utilization (over <$CPU.UTIL.CRIT>% for 5m)

The CPU Queue Length in the last 5 minutes exceeds <$CPU.QUEUE.CRIT.MAX>. According to actual observations, PQL should not exceed the number of cores * 2. To fine-tune the conditions, use the macro <$CPU.QUEUE.CRIT.MAX >.

Depends on:

— High CPU utilization (over <$CPU.UTIL.CRIT>% for 5m)

Please report any issues with the template at https://support.zabbix.com

Windows memory by Zabbix agent active

For Zabbix version: 5.4 and higher

Refer to the vendor documentation.

No specific Zabbix configuration is required.

The warning threshold of the Memory Pages/sec counter.

The warning threshold of the Free System Page Table Entries counter.

The warning threshold of the Memory util item.

The warning threshold of the minimum free swap.

There are no template links in this template.

Name Description Expression Severity Dependencies and additional info
High CPU utilization (over <$CPU.UTIL.CRIT>% for 5m) min(/Windows CPU by Zabbix agent active/system.cpu.util,5m)> WARNING
CPU interrupt time is too high (over <$CPU.INTERRUPT.CRIT.MAX>% for 5m) min(/Windows CPU by Zabbix agent active/perf_counter_en[«Processor Information(_total)% Interrupt Time»],5m)> WARNING min(/Windows CPU by Zabbix agent active/perf_counter_en[«Processor Information(_total)% Privileged Time»],5m)> WARNING

Used memory in Bytes

Total memory in Bytes

Memory utilization in %

Cache Bytes is the sum of the MemorySystem Cache Resident Bytes, MemorySystem Driver Resident Bytes,

MemorySystem Code Resident Bytes, and MemoryPool Paged Resident Bytes counters. This counter displays

the last observed value only; it is not an average.

The free space of swap volume/file in bytes.

The total space of swap volume/file in bytes.

This indicates the number of page table entries not currently in use by the system. If the number is less

than 5,000, there may well be a memory leak or you running out of memory.

Page Faults/sec is the average number of pages faulted per second. It is measured in number of pages

faulted per second because only one page is faulted in each fault operation, hence this is also equal

to the number of page fault operations. This counter includes both hard faults (those that require

disk access) and soft faults (where the faulted page is found elsewhere in physical memory.) Most

processors can handle large numbers of soft faults without significant consequence. However, hard faults,

which require disk access, can cause significant delays.

This measures the rate at which pages are read from or written to disk to resolve hard page faults.

If the value is greater than 1,000, as a result of excessive paging, there may be a memory leak.

This measures the size, in bytes, of the non-paged pool. This is an area of system memory for objects

that cannot be written to disk but instead must remain in physical memory as long as they are allocated.

There is a possible memory leak if the value is greater than 175MB (or 100MB with the /3GB switch).

A typical Event ID 2019 is recorded in the system event log.

Group Name Description Type Key and additional info
Memory Used memory CALCULATED vm.memory.util

Expression:

last(//vm.memory.size[used]) / last(//vm.memory.size[total]) * 100

Memory Cache bytes ZABBIX_ACTIVE perf_counter_en[«MemoryCache Bytes»]
Memory Free swap space CALCULATED system.swap.free

Expression:

The free space of swap volume/file in percent.

DEPENDENT system.swap.pfree

Preprocessing:

The used space of swap volume/file in percent.

ZABBIX_ACTIVE perf_counter_en[«Paging file(_Total)% Usage»]
Memory Total swap space ZABBIX_ACTIVE system.swap.size[,total]
Memory Free system page table entries ZABBIX_ACTIVE perf_counter_en[«MemoryFree System Page Table Entries»]
Memory Memory page faults per second ZABBIX_ACTIVE perf_counter_en[«MemoryPage Faults/sec»]
Memory Memory pages per second ZABBIX_ACTIVE perf_counter_en[«MemoryPages/sec»]
Memory Memory pool non-paged ZABBIX_ACTIVE perf_counter_en[«MemoryPool Nonpaged Bytes»]

The system is running out of free memory.

This trigger is ignored, if there is no swap configured

Depends on:

— High memory utilization (><$MEMORY.UTIL.MAX>% for 5m)

The Memory Free System Page Table Entries is less than <$MEM.PAGE_TABLE_CRIT.MIN>for 5 minutes. If the number is less than 5,000, there may well be a memory leak.

Depends on:

— High memory utilization (><$MEMORY.UTIL.MAX>% for 5m)

The Memory Pages/sec in the last 5 minutes exceeds <$MEM.PAGE_SEC.CRIT.MAX>. If the value is greater than 1,000, as a result of excessive paging, there may be a memory leak.

Depends on:

— High memory utilization (><$MEMORY.UTIL.MAX>% for 5m)

Please report any issues with the template at https://support.zabbix.com

Windows filesystems by Zabbix agent active

For Zabbix version: 6.0 and higher

Refer to the vendor documentation.

No specific Zabbix configuration is required.

This macro is used in filesystems discovery. Can be overridden on the host or linked template level.

This macro is used in filesystems discovery. Can be overridden on the host or linked template level.

This macro is used in filesystems discovery. Can be overridden on the host or linked template level.

This macro is used in filesystems discovery. Can be overridden on the host or linked template level.

This macro is used in filesystems discovery. Can be overridden on the host or linked template level.

This macro is used in filesystems discovery. Can be overridden on the host or linked template level.

The critical threshold of the filesystem utilization in percent.

The warning threshold of the filesystem utilization in percent.

There are no template links in this template.

Name Description Expression Severity Dependencies and additional info
High memory utilization (><$MEMORY.UTIL.MAX>% for 5m) min(/Windows memory by Zabbix agent active/vm.memory.util,5m)> AVERAGE
High swap space usage (less than <$SWAP.PFREE.MIN.WARN>% free) max(/Windows memory by Zabbix agent active/perf_counter_en[«MemoryFree System Page Table Entries»],5m) WARNING min(/Windows memory by Zabbix agent active/perf_counter_en[«MemoryPages/sec»],5m)> WARNING

Discovery of file systems of different types.

Name Description Type Key and additional info
Mounted filesystem discovery ZABBIX_ACTIVE vfs.fs.discovery

Filter:

Used storage in Bytes

Total space in Bytes

Space utilization in % for

Group Name Description Type Key and additional info
Filesystems <#FSLABEL>(<#FSNAME>): Used space ZABBIX_ACTIVE vfs.fs.size[<#FSNAME>,pused]

Two conditions should match: First, space utilization should be above <$VFS.FS.PUSED.MAX.CRIT:»<#FSNAME>«>.

Second condition should be one of the following:

— The disk free space is less than 5G.

— The disk will be full in less than 24 hours.

Two conditions should match: First, space utilization should be above <$VFS.FS.PUSED.MAX.WARN:»<#FSNAME>«>.

Second condition should be one of the following:

— The disk free space is less than 10G.

— The disk will be full in less than 24 hours.

Depends on:

Please report any issues with the template at https://support.zabbix.com

Windows physical disks by Zabbix agent active

For Zabbix version: 5.4 and higher

Refer to the vendor documentation.

No specific Zabbix configuration is required.

This macro is used in physical disks discovery. Can be overridden on the host or linked template level.

This macro is used in physical disks discovery. Can be overridden on the host or linked template level.

Disk read average response time (in s) before the trigger would fire.

The warning threshold of disk time utilization in percent.

Disk write average response time (in s) before the trigger would fire.

There are no template links in this template.

Name Description Expression Severity Dependencies and additional info
<#FSLABEL>(<#FSNAME>): Disk space is critically low (used > <$VFS.FS.PUSED.MAX.CRIT:»<#FSNAME>«>%) last(/Windows filesystems by Zabbix agent active/vfs.fs.size[<#FSNAME>,pused])><$VFS.FS.PUSED.MAX.CRIT:»<#FSNAME>«> and ((last(/Windows filesystems by Zabbix agent active/vfs.fs.size[<#FSNAME>,total])-last(/Windows filesystems by Zabbix agent active/vfs.fs.size[<#FSNAME>,used])) AVERAGE last(/Windows filesystems by Zabbix agent active/vfs.fs.size[<#FSNAME>,pused])><$VFS.FS.PUSED.MAX.WARN:»<#FSNAME>«> and ((last(/Windows filesystems by Zabbix agent active/vfs.fs.size[<#FSNAME>,total])-last(/Windows filesystems by Zabbix agent active/vfs.fs.size[<#FSNAME>,used])) WARNING

Discovery of installed physical disks.

Name Description Type Key and additional info
Physical disks discovery ZABBIX_ACTIVE perf_instance_en.discovery[PhysicalDisk]

Preprocessing:

Filter:

Rate of read operations on the disk.

Rate of write operations on the disk.

Current average disk queue, the number of requests outstanding on the disk at the time the performance data is collected.

This item is the percentage of elapsed time that the selected disk drive was busy servicing read or writes requests.

The average time for read requests issued to the device to be served. This includes the time spent by the requests in queue and the time spent servicing them.

The average time for write requests issued to the device to be served. This includes the time spent by the requests in queue and the time spent servicing them.

Average disk read queue, the number of requests outstanding on the disk at the time the performance data is collected.

Average disk write queue, the number of requests outstanding on the disk at the time the performance data is collected.

Group Name Description Type Key and additional info
Storage <#DEVNAME>: Disk read rate ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)Disk Reads/sec»,60]
Storage <#DEVNAME>: Disk write rate ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)Disk Writes/sec»,60]
Storage <#DEVNAME>: Disk average queue size (avgqu-sz) ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)Current Disk Queue Length»,60]
Storage <#DEVNAME>: Disk utilization ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)% Disk Time»,60]
Storage <#DEVNAME>: Disk read request avg waiting time ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)Avg. Disk sec/Read»,60]
Storage <#DEVNAME>: Disk write request avg waiting time ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)Avg. Disk sec/Write»,60]
Storage <#DEVNAME>: Average disk read queue length ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)Avg. Disk Read Queue Length»,60]
Storage <#DEVNAME>: Average disk write queue length ZABBIX_ACTIVE perf_counter_en[«PhysicalDisk(<#DEVNAME>)Avg. Disk Write Queue Length»,60]

The disk appears to be under heavy load

Depends on:

— <#DEVNAME>: Disk read request responses are too high (read > <$VFS.DEV.READ.AWAIT.WARN:»<#DEVNAME>«>s for 15m

— <#DEVNAME>: Disk write request responses are too high (write > <$VFS.DEV.WRITE.AWAIT.WARN:»<#DEVNAME>«>s for 15m)

This trigger might indicate disk <#DEVNAME>saturation.

This trigger might indicate disk <#DEVNAME>saturation.

Please report any issues with the template at https://support.zabbix.com

Windows generic by Zabbix agent active

For Zabbix version: 5.4 and higher

Refer to the vendor documentation.

No specific Zabbix configuration is required.

The threshold for difference of system time in seconds.

There are no template links in this template.

Name Description Expression Severity Dependencies and additional info
<#DEVNAME>: Disk is overloaded (util > <$VFS.DEV.UTIL.MAX.WARN>% for 15m) min(/Windows physical disks by Zabbix agent active/perf_counter_en[«PhysicalDisk(<#DEVNAME>)% Disk Time»,60],15m)> WARNING min(/Windows physical disks by Zabbix agent active/perf_counter_en[«PhysicalDisk(<#DEVNAME>)Avg. Disk sec/Read»,60],15m) > <$VFS.DEV.READ.AWAIT.WARN:»<#DEVNAME>«> WARNING min(/Windows physical disks by Zabbix agent active/perf_counter_en[«PhysicalDisk(<#DEVNAME>)Avg. Disk sec/Write»,60],15m) > <$VFS.DEV.WRITE.AWAIT.WARN:»<#DEVNAME>«> WARNING

System local time of the host.

Operating system architecture of the host.

Group Name Description Type Key and additional info
General System local time ZABBIX_ACTIVE system.hostname

Preprocessing:

System description of the host.

ZABBIX_ACTIVE system.uname

Preprocessing:

The number of processes.

The number of threads used by all running processes.

ZABBIX_ACTIVE perf_counter_en[«SystemThreads»]
Inventory Operating system architecture ZABBIX_ACTIVE system.sw.arch

Preprocessing:

System uptime in ‘N days, hh:mm:ss’ format.

ZABBIX_ACTIVE system.uptime

The host system time is different from the Zabbix server time.

System name has changed. Ack to close.

Please report any issues with the template at https://support.zabbix.com

Windows network by Zabbix agent active

For Zabbix version: 5.4 and higher

Refer to the vendor documentation.

No specific Zabbix configuration is required.

This macro is used in Network interface discovery. Can be overridden on the host or linked template level.

This macro is used in Network interface discovery. Can be overridden on the host or linked template level.

This macro is used in Network interface discovery. Can be overridden on the host or linked template level.

This macro is used in Network interface discovery. Can be overridden on the host or linked template level.

This macro is used in Network interface discovery. Can be overridden on the host or linked template level.

This macro is used in Network interface discovery. Can be overridden on the host or linked template level.

There are no template links in this template.

Name Description Expression Severity Dependencies and additional info
System time is out of sync (diff with Zabbix server > <$SYSTEM.FUZZYTIME.MAX>s) fuzzytime(/Windows generic by Zabbix agent active/system.localtime,<$SYSTEM.FUZZYTIME.MAX>)=0 WARNING last(/Windows generic by Zabbix agent active/system.hostname,#1)<>last(/Windows generic by Zabbix agent active/system.hostname,#2) and length(last(/Windows generic by Zabbix agent active/system.hostname))>0 INFO
Host has been restarted (uptime last(/Windows generic by Zabbix agent active/system.uptime) WARNING

Discovery of installed network interfaces.

Name Description Type Key and additional info
Network interfaces discovery DEPENDENT net.if.discovery

Preprocessing:

— JAVASCRIPT: The text is too long. Please see the template.

Filter:

Incoming traffic on the network interface.

Group Name Description Type Key and additional info
Network_interfaces Interface <#IFNAME>(<#IFALIAS>): Bits received ZABBIX_ACTIVE net.if.in[«<#IFGUID>«]

Preprocessing:

Outgoing traffic on the network interface.

ZABBIX_ACTIVE net.if.out[«<#IFGUID>«]

Preprocessing:

The number of incoming packets dropped on the network interface.

ZABBIX_ACTIVE net.if.in[«<#IFGUID>«,dropped]

Preprocessing:

The number of outgoing packets dropped on the network interface.

ZABBIX_ACTIVE net.if.out[«<#IFGUID>«,dropped]

Preprocessing:

The number of incoming packets with errors on the network interface.

ZABBIX_ACTIVE net.if.in[«<#IFGUID>«,errors]

Preprocessing:

The number of outgoing packets with errors on the network interface.

ZABBIX_ACTIVE net.if.out[«<#IFGUID>«,errors]

Preprocessing:

Estimated bandwidth of the network interface if any.

DEPENDENT net.if.speed[«<#IFGUID>«]

Preprocessing:

The type of the network interface.

DEPENDENT net.if.type[«<#IFGUID>«]

Preprocessing:

The operational status of the network interface.

DEPENDENT net.if.status[«<#IFGUID>«]

Preprocessing:

Raw data of win32_networkadapter.

ZABBIX_ACTIVE wmi.getall[rootcimv2,»select Name,Description,NetConnectionID,Speed,AdapterTypeId,NetConnectionStatus,GUID from win32_networkadapter where PhysicalAdapter=True and NetConnectionStatus>0″]

Preprocessing:

The network interface utilization is close to its estimated maximum bandwidth.

Depends on:

Recovers when below 80% of <$IF.ERRORS.WARN:»<#IFNAME>«> threshold

Depends on:

This Ethernet connection has transitioned down from its known maximum speed. This might be a sign of autonegotiation issues. Ack to close.

Depends on:

This trigger expression works as follows:

1. Can be triggered if operations status is down.

No new trigger will be fired if this interface is down.

Please report any issues with the template at https://support.zabbix.com

Windows services by Zabbix agent active

For Zabbix version: 5.4 and higher
Special version of services template that is required for Windows OS.

Refer to the vendor documentation.

No specific Zabbix configuration is required.

This macro is used in Service discovery. Can be overridden on the host or linked template level.

This macro is used in Service discovery. Can be overridden on the host or linked template level.

This macro is used in Service discovery. Can be overridden on the host or linked template level.

This macro is used in Service discovery. Can be overridden on the host or linked template level.

There are no template links in this template.

Name Description Expression Severity Dependencies and additional info
Interface <#IFNAME>(<#IFALIAS>): High bandwidth usage (><$IF.UTIL.MAX:»<#IFNAME>«>%) (avg(/Windows network by Zabbix agent active/net.if.in[«<#IFGUID>«],15m)>(<$IF.UTIL.MAX:»<#IFNAME>«>/100)*last(/Windows network by Zabbix agent active/net.if.speed[«<#IFGUID>«]) or avg(/Windows network by Zabbix agent active/net.if.out[«<#IFGUID>«],15m)>(<$IF.UTIL.MAX:»<#IFNAME>«>/100)*last(/Windows network by Zabbix agent active/net.if.speed[«<#IFGUID>«])) and last(/Windows network by Zabbix agent active/net.if.speed[«<#IFGUID>«])>0

avg(/Windows network by Zabbix agent active/net.if.in[«<#IFGUID>«],15m)

WARNING min(/Windows network by Zabbix agent active/net.if.in[«<#IFGUID>«,errors],5m)><$IF.ERRORS.WARN:»<#IFNAME>«> or min(/Windows network by Zabbix agent active/net.if.out[«<#IFGUID>«,errors],5m)><$IF.ERRORS.WARN:»<#IFNAME>«>

max(/Windows network by Zabbix agent active/net.if.in[«<#IFGUID>«,errors],5m)

WARNING change(/Windows network by Zabbix agent active/net.if.speed[«<#IFGUID>«]) 0 and last(/Windows network by Zabbix agent active/net.if.status[«<#IFGUID>«])=2 INFO <$IFCONTROL:»<#IFNAME>«>=1 and last(/Windows network by Zabbix agent active/net.if.status[«<#IFGUID>«])<>2 and (last(/Windows network by Zabbix agent active/net.if.status[«<#IFGUID>«],#1)<>last(/Windows network by Zabbix agent active/net.if.status[«<#IFGUID>«],#2))

last(/Windows network by Zabbix agent active/net.if.status[«<#IFGUID>«])=2 or <$IFCONTROL:»<#IFNAME>«>=0

AVERAGE

Discovery of Windows services of different types as defined in template’s macros.

Name Description Type Key and additional info
Windows services discovery ZABBIX_ACTIVE service.discovery

Filter:

Group Name Description Type Key and additional info
Services State of service «<#SERVICE.NAME>» (<#SERVICE.DISPLAYNAME>) ZABBIX_ACTIVE service.info[«<#SERVICE.NAME>«,state]

The service has a state other than «Running» for the last three times.

Name Description Expression Severity Dependencies and additional info
«<#SERVICE.NAME>» (<#SERVICE.DISPLAYNAME>) is not running (startup type <#SERVICE.STARTUPNAME>) min(/Windows services by Zabbix agent active/service.info[«<#SERVICE.NAME>«,state],#3)<>0 AVERAGE

Please report any issues with the template at https://support.zabbix.com

Windows by Zabbix agent active

For Zabbix version: 5.4 and higher
New official Windows template. Requires agent of Zabbix 4.4 and newer.

This template was tested on:

Install Zabbix agent on Windows OS according to Zabbix documentation.

No specific Zabbix configuration is required.

Name
Windows CPU by Zabbix agent active
Windows filesystems by Zabbix agent active
Windows generic by Zabbix agent active
Windows memory by Zabbix agent active
Windows network by Zabbix agent active
Windows physical disks by Zabbix agent active
Windows services by Zabbix agent active
Zabbix agent active

Please report any issues with the template at https://support.zabbix.com

You can also provide a feedback, discuss the template or ask for help with it at ZABBIX forums.

You can’t perform that action at this time.

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.

Источник

Читайте также:  код ошибки 0x000021a windows 10

Adblock
detector

Перейти к содержимому

Поставил как-то на новый Linux сервер Zabbix и сразу начало отображаться следующее предупреждение:

Lack of Free Swap Space on Zabbix Server

Предупреждение сообщает что нет места в разделе Swap, посмотрев увидел что Swap раздела то нет вообще, странно что при установке Ubuntu 14.04 LTS с указанием опции использовать весь диск он не создался автоматически, оперативной памяти на сервере было 6 Гб всего-то.

По этому решением проблемы в моём случае было создание Swap раздела, после чего предупреждение исчезло.
Смотрите другую мою статью по этому поводу — Как создать SWAP в Linux

Ну а если оперативной памяти очень много, и она свободна в основном, то Swap может и смысла нету создавать, по этому можно просто отключить для этого сервера триггер создающий уведомление. Для этого откроем панель Zabbix, перейдем во вкладку «Настройка» — «Узлы сети», напротив данного сервера нажмём «Триггеры» и деактивируем триггер создающий это предупреждение.

Все.

Проверка отправки списка процессов

Теперь проверим, как все это будет работать. Для этого идем на целевой сервер и нагружаем его чем-нибудь. Я для примера запустил в двух разных консолях по команде:

# cat /dev/zero | bzip2 -c > /dev/null
# md5sum /dev/urandom

Они достаточно быстро нагрузили единственное ядро тестового сервера, так что оставалось только подождать активации триггера. Через 5 минут это случилось.

Иду в раздел Последние данные и вижу там список процессов, которые нагрузили мой сервер.

Что мне в итоге и требовалось. Теперь нет нужды каким-то образом проверять, что конкретно нагружает сервер. В момент пиковой нагрузки я получу список запущенных процессов в отдельный айтем. Для полного списка процессов все делается по аналогии.

What is this Zabbix Free Disk Space Is Less Than 20 On Volume alert?

In general, Zabbix greatly helps in monitoring the servers. Zabbix triggers alerts to indicate upcoming problems on the server.

One such alert is this free disk space less alert.

The trigger gives this alert when the disk space is less than 20%  on the volume. Here, the Zabbix allows customization on the threshold at which the system triggers the alert.

Moreover, based on the purpose of the server, we see some customers set it at even low values like 10%. A snippet of Zabbix dashboard with such alerts show up as:

In such situations, we firstly find out what is consuming the disk space and take action accordingly.

Let’s see how our Engineers found a fix for this Zabbix message.

Zabbix: Отсутствие свободного места для подкачки на решении Zabbix server

s http-equiv=»Content-Type» content=»text/html;charset=UTF-8″>tyle=»clear:both;»>

проблема

При использовании Zabbix для мониторинга некоторых облачных хостов вы можете столкнуться с:

Lack of free swap space on Zabbix server1

Используйте команду:

free -m

видеть:

Общие, использованные и свободные значения свопа равны 0. Это потому, что Zabbix не учитывает пользователей облачного хоста.

Этапы обработки:

1. Управление-шаблон-шаблон ОС Linux-Trigger

2. Выберите «Отсутствие свободного места для подкачки на {HOST.NAME}».

3. Изменить выражение

{Template OS Linux:system.swap.size.last(0)}<501

превратиться в

{Template OS Linux:system.swap.size.last(0)}<50 and {Template OS Linux:system.swap.size.last(0)}<>0

Нажмите «Обновить», чтобы сохранить, подождите некоторое время, оно станет «Решено», подтвердите

Перепечатано по адресу: https://blog.51cto.com/9499607/2163615

Интеллектуальная рекомендация

Глава первая: Причина В большинстве анекдотов в Интернете говорится, что программисты относительно тупые, плохие слова и в основном мужчины. Я один из тысяч программистов. Обычно я не знаю, как правил…

Всегда был спрос, надеясь увидеть в реальном времени рейтинг моего сайта в Baidu Я использовал некоторые инструменты, либо медленный ответ, либо результаты не точные или в режиме реального времени Поэ…

Алгоритм обнаружения характерных точек Обнаружение угла Харриса                                 Обнаружение функции SIFT…

По просьбе пользователей сети напишите пример использования Selenium Grid для управления несколькими системами и несколькими браузерами для параллельного выполнения тестов. Поскольку у меня здесь две …

Эта проблема возникает, когда используется openrowset. Просто выполните следующий код:           http://www.cnblogs.com/wayne-ivan/archive/2008/01/07/1028759.html…

Вам также может понравиться

В проекте .net я часто сталкиваюсь с необходимостью автоматически делать скриншот кадра после загрузки видео. Вот метод использования ffmpeg для автоматического создания скриншота Сначала загрузите фа…

Ленивая загрузка не удалась, потому что @Responsebobode JSON преобразует Getroles по умолчанию, которая заканчивается пользователем, поэтому ленивая загрузка недействительна. Если вы предоставляете TO…

virtualenv установка Основное использование Создайте виртуальную среду для проекта: virtualenv venv создаст папку в текущем каталоге, содержащую исполняемые файлы Python и копию библиотеки pip, чтобы …

Java.io.fileNotfoundException: файл: d: Code xml-load target xx.jar! Xxx (имя файла, имя каталога или синтаксис громкости неверно.) 1. При использовании Spring Boot для применения к JAR не…

Облачный сервер zabbix server сообщил об ошибке: Отсутствие бесплатного свопа на Zabbix сервере

s http-equiv=»Content-Type» content=»text/html;charset=UTF-8″>tyle=»clear:both;»>

1. Проблема

Lack of free swap space on Zabbix server

Такая ситуация часто возникает при мониторинге облачных хостов. Хотя память в основном бесполезна, появляется это сообщение. Поскольку zabbix не учитывает облачный хост, облачный хост не имеет подкачки. Когда физической памяти системы недостаточно, раздел подкачки освободит часть физической памяти для текущей операции. Использование программы. Это означает, что должна быть физическая память Сообщение об ошибке: Решение:

Этапы обработки:

  1. Администрирование-Шаблон-Шаблон ОС Linux-Триггер
  2. Выберите «Отсутствие свободного места для подкачки» на {HOST.NAME}.
  3. Изменить выражение

превратиться в

Нажмите «Обновить», чтобы сохранить, подождите некоторое время, он станет «Решенным», подтвердите

Если вышеперечисленное не помогло, проверьте следующие методы:

Как добавить раздел SWAP на облачный сервер

Как увеличить своп?

1. Проверьте, включен ли раздел подкачки в текущей системе.

2. Если функция раздела подкачки не включена, создайте специальный файл для раздела подкачки.

Примечание: dd: скопируйте файл с блоком указанного размера и выполните указанное преобразование при копировании, если = имя входного файла, то есть укажите исходный файл, of = имя выходного файла, то есть укажите файл назначения. Размер этого файла равен размеру count, умноженному на размер bs, размер указанной выше команды составляет 4294971392, что составляет 4 ГБ

Наш тест не должен быть таким большим

3. Используйте команду mkswap, чтобы превратить вновь созданный файл в раздел подкачки.

4. Проверьте, равно ли значение параметра ядра vm.swappiness 0, если оно равно 0, отрегулируйте его до 30 или 60 в соответствии с фактическими потребностями.

Команда настройки

Примечание: если вы хотите изменить его навсегда, отредактируйте файл /etc/sysctl.conf

5. Включите функцию подкачки этого раздела подкачки.

6. Просмотрите добавленный эффект.

Ссылка для справки:

Zabbix: Отсутствие свободного места для подкачки на сервере Zabbix решение: https://blog.51cto.com/9499607/2163615

Ссылка для ссылки: https://blog.csdn.net/windle89/article/details/77771483 тревога zabbix Отсутствие свободного места подкачки на zabbix

Ссылка для справки: https://yq.aliyun.com/articles/52098 Хост Alibaba Cloud Cloud добавляет раздел подкачки и оптимизацию производительности подкачки

Интеллектуальная рекомендация

Глава первая: Причина В большинстве анекдотов в Интернете говорится, что программисты относительно тупые, плохие слова и в основном мужчины. Я один из тысяч программистов. Обычно я не знаю, как правил…

Всегда был спрос, надеясь увидеть в реальном времени рейтинг моего сайта в Baidu Я использовал некоторые инструменты, либо медленный ответ, либо результаты не точные или в режиме реального времени Поэ…

Алгоритм обнаружения характерных точек Обнаружение угла Харриса                                 Обнаружение функции SIFT…

По просьбе пользователей сети напишите пример использования Selenium Grid для управления несколькими системами и несколькими браузерами для параллельного выполнения тестов. Поскольку у меня здесь две …

Эта проблема возникает, когда используется openrowset. Просто выполните следующий код:           http://www.cnblogs.com/wayne-ivan/archive/2008/01/07/1028759.html…

Вам также может понравиться

В проекте .net я часто сталкиваюсь с необходимостью автоматически делать скриншот кадра после загрузки видео. Вот метод использования ffmpeg для автоматического создания скриншота Сначала загрузите фа…

Ленивая загрузка не удалась, потому что @Responsebobode JSON преобразует Getroles по умолчанию, которая заканчивается пользователем, поэтому ленивая загрузка недействительна. Если вы предоставляете TO…

virtualenv установка Основное использование Создайте виртуальную среду для проекта: virtualenv venv создаст папку в текущем каталоге, содержащую исполняемые файлы Python и копию библиотеки pip, чтобы …

Java.io.fileNotfoundException: файл: d: Code xml-load target xx.jar! Xxx (имя файла, имя каталога или синтаксис громкости неверно.) 1. При использовании Spring Boot для применения к JAR не…

Zabbix 4 на CentOS 7

Считаем, что у нас есть установленный и предварительно минимально настроенный CentOS 7. В качестве web-сервера для Zabbix будет использоваться nginx.

Подключаем репозиторий nginx и устанавливаем его:

Запускаем nginx и добавляем в автозагрузку.

Дальше устанавливаем менеджер процессов FastCGI (FPM) – php-fpm. Для этого подключаем репозиторий remi

Устанавливаем php 7.1 и модули к нему

Запускаем и добавляем в автозагрузку php-fpm

Проверяем, запустился ли он.

Все в порядке, но запустим его через unix сокет. Для этого правим конфиг

Перезапустим php-fpm проверим, запущенный сокет

Дальше установим свежую версию сервера баз данных MariaDB. Подключаем нужный репозиторий – Идем сюда и выбираем нужные параметры операционки

Устанавливаем сервер баз данных

Запускаем mariadb и добавляем в автозагрузку

Запустим скрипт начальной конфигурации mysql и создадим пароль для root. Все остальное можно оставить по-умолчанию.

Сделаем свой конфиг для mariadb, оптимизированный под zabbix

Перезапустим mariadb и убедимся, что он запустился

Приступим к установке Zabbix Server 4.0, первым делом нужно подключить репозиторий

Теперь запускаем установку Zabbix-server

После установки, создаём базу данных zabbix, пользователя zabbix и заполняем базу

Отредактируем файл конфигурации сервера zabbix, этих минимальных настроек достаточно, для работы сервера

Запустим zabbix и добавим его в автозагрузку

Можно проверить лог файл на наличие ошибок

Остается сделать конфиг nginx для работы web интерфейса zabbix. В моем случае nginx работает на том же сервере, где сам zabbix, а других виртуальных хостов нет, правим дефолтный конфиг

Проверим конфиг на ошибки и перезапустим nginx

Важный нюанс – необходимо изменить права доступа и назначить владельцем nginx

Этот нужно будет проделывать после каждого обновления php или zabbix. По-умолчанию zabbix идет в комплекте с apache и рассчитан на работу с ним. После установки или обновления, он делает его владельцем директории /etc/zabbix/web.

С серверной частью всё, продолжаем установку zabbix сервера через Zabbix Frontend. На одном из этапов указываем параметры доступа к базе данных. После завершения установки, авторизуемся на сервере со стандартной учетной записью

Изменение стандартных шаблонов мониторинга

В шаблоне Template App Zabbix Agent отключаем триггер Version of zabbix_agent(d) was changed on . В шаблоне Template OS Linux меняем в триггере Disk I/O is overloaded on значение со стандартных 20% до 50%. В этом же шаблоне в правиле обнаружения Mounted filesystem discovery добавим еще один прототип триггера, скопировав Free disk space is less than 20% on volume

В новом шаблоне вместо 20% указываем 5% и ставим важность «Высокая». В этом же шаблоне в триггере Lack of free swap space on меняем порог срабатывания с 50% до 20%

В шаблоне Template OS Windows отключаем Правило обнаружения Windows service discovery. Если нужен мониторинг какой-то службы windows, для этого можно сделать отдельный шаблон.

Общие настройки

В общих настройках zabbix server, которые располагаются в разделе Администрирование -> Общие меняем следующие параметры:

В разделе Рабочее время выставляем актуальные рабочие часы. В разделе Опции отображения триггеров меняем значения Отображать триггеры в состоянии ОК в течении и Мигание триггеров при изменении состояния на 1 минуту. В разделе Прочее меняю Обновление неподдерживаемых элементов данных на 1 минуту. Это актуально во время отладки новых шаблонов.

Настройки оповещений в Telegram описаны тут.

Давайте посмотрим на типовые ситуации и к чему они приводят при наличии и отсутствии swap. О метриках «конкуренции за память» я рассказываю в докладе про cgroup v2 .

Без конкуренции или с малой конкуренцией за память

  • При наличии swap : мы можем положить в swap анонимную память, которая редко используется и нужна только в небольшой части жизненного цикла процесса. Это позволяет использовать данную память для улучшения коэффициента попаданий в кэш и других оптимизаций.
  • Без swap : не можем складывать в swap редко используемую анонимную память, поскольку она вынуждена храниться только в памяти. Не факт, что это сразу приведёт к проблеме, однако в некоторых рабочих нагрузках производительность может упасть из-за устаревших анонимных страниц, забирающих место у более важных задач.

С умеренной или высокой конкуренцией за память

  • При наличии swap : у всех типов памяти одинаковая вероятность высвобождения. Это означает большую вероятность успешного высвобождения страниц — мы можем высвобождать страницы, которые не будут быстро снова приводить к отказу (к пробуксовке ).
  • Без swap : анонимные страницы ограничены памятью, т.к. не имеют альтернатив для хранения. Вероятность успешного долгосрочного высвобождения страниц ниже, поскольку оно доступно только для некоторых типов памяти. Риск пробуксовки страниц выше. Случайный читатель может подумать, что так всё равно будет лучше, поскольку не случится нагрузки на ввод/вывод диска, но это не так: мы попросту переносим disk I/O из-за swapping’а на сброс горячего страничного кэша и сегментов кода, которые нам скоро понадобятся.

При временных всплесках в потреблении памяти

  • При наличии swap : устойчивость к временным всплескам выше, однако в случае резкой нехватки памяти время между пробуксовкой и работой OOM killer может вырасти. Нам лучше видны причины нагрузки на память и мы можем более рационально повлиять на них, можем осуществить контролируемое вмешательство.
  • Без swap : OOM killer вызывается быстрее, поскольку анонимные страницы ограничены памятью и не могут быть высвобождены. Мы скорее столкнёмся с пробуксовкой, однако время между ней и OOMing’ом сократится. Будет лучше или хуже — зависит от конкретного приложения. Например, основанное на очередях приложение может захотеть потребовать такого быстрого перехода от пробуксовки к OOMing’у. Тем не менее, всё равно уже слишком поздно для полезных действий — OOM killer вызывается только в случаях резкой нехватки памяти. Вместо того, чтобы полагаться на такое поведение, в первую очередь лучше позаботиться о более оппортунистическом подходе (т.е. направленном на следование своим интересам —прим. перев.) к убиванию процессов при достижении состояния конкуренции за память.

Окей, я хочу системный swap, но как его настроить для конкретных приложений?

Вы же не думали, что в этой статье не будет упоминаний использования cgroup v2?

Очевидно, что общему эвристическому алгоритму тяжело не ошибаться всё время, поэтому важно иметь возможность дать необходимые инструкции ядру. Исторически единственной настройкой, которую можно было применить на системном уровне, являлась vm.swappiness

У неё две проблемы: vm.swappiness крайне сложно разумно применять, потому что она является лишь маленькой частью гораздо большей эвристической системы, и она применима лишь ко всей системе, но не к ограниченному набору процессов.

Можно также использовать mlock для фиксации страниц в памяти, но такой подход требует либо модификации кода программы и забав с LD_PRELOAD, либо ужасных танцев с отладчиком во время исполнения приложения. В языках, основанных на виртуальных машинах, всё это тоже не так-то хорошо работает, поскольку у вас обычно нет возможности контролировать распределение памяти и приходится делать mlockall, у которого нет точных настроек для тех страниц, что действительно важны.

В cgroup v2 есть определяемая на каждую cgroup настройка memory.low, которая позволяет сказать ядру отдавать предпочтение другим приложениям для высвобождения до достижения определённого порога используемой памяти. Нет гарантий, что ядро предотвратит swapping частей приложения, однако оно будет предпочитать высвобождение для других приложений в случае конкуренции за память. В нормальных условиях логика swap’а в ядре в целом достаточно хороша, так что разрешение оппортунистически выносить в swap страницы в общем случае повышает системную производительность. Пробуксовка swap’а в условиях сильной конкуренции за память не идеальна, но это скорее просто особенность ситуации нехватки памяти, чем проблема swapper’а. В ситуациях, когда давление на память начинает расти, вы обычно хотите быстрого завершения работы некритических процессов посредством их «самоубийства».

И в этом вопросе нельзя просто положиться на OOM killer. Потому что OOM killer вызывается только в самых критичных ситуациях, когда система уже оказалась в значительно нездоровом состоянии и, возможно, находилась в нём некоторое время. Необходимо самостоятельно и оппортунистически разрешить ситуацию ещё до того, как задумываться об OOM killer’е.

Тем не менее, выявить давление на память достаточно трудно с помощью традиционных счётчиков памяти в Linux. Нам доступно нечто, что каким-то образом относится к проблеме, однако скорее по касательной: потребление памяти, количество операций сканирования страниц и т.п. — и по одним этим метрикам очень трудно отличить эффективную конфигурацию памяти от той, что приводит к конкуренции за память. У нас есть группа в Facebook, возглавляемая Johannes’ом и работающая над новыми метриками, упрощающими демонстрацию давления на память, — это должно помочь нам в будущем. Больше информации об этом можно получить из моего доклада про cgroup v2, где я начинаю подробнее рассказывать об одной из метрик.

Понравилась статья? Поделить с друзьями:
  • Zabbix agent не устанавливается windows 7
  • Zabbix agent windows server 2012 r2
  • Zabbix agent is not available for 3m windows
  • Your windows license supports only one display language как русифицировать
  • Your windows license support only one display language перевод