Icinga2 perfdata目录溢出

我已经在虚拟机上安装了icinga2,用于监视其他5个graphics和icingaweb2作为接口的石墨支持。 最近在我的networking界面,我得到了以下结果:

Fatal error: Uncaught exception 'ErrorException' with message 'session_start(): open(/var/lib/php5/sess_3aabfsu76vcdj2hd2u3teofta5dvanpn, O_RDWR) failed: No space left on device (28)' in /usr/share/php/Icinga/Web/Session/PhpSession.php:105 Stack trace: #0 [internal function]: Icinga\Application\ApplicationBootstrap->Icinga\Application\{closure}(2, 'session_start()...', '/usr/share/php/...', 105, Array) #1 /usr/share/php/Icinga/Web/Session/PhpSession.php(105): session_start() #2 /usr/share/php/Icinga/Web/Session/PhpSession.php(215): Icinga\Web\Session\PhpSession->open() #3 /usr/share/php/Icinga/Authentication/Auth.php(344): Icinga\Web\Session\PhpSession->refreshId() #4 /usr/share/php/Icinga/Authentication/Auth.php(166): Icinga\Authentication\Auth->persistCurrentUser() #5 /usr/share/php/Icinga/Authentication/Auth.php(262): Icinga\Authentication\Auth->setAuthenticated(Object(Icinga\User)) #6 /usr/share/php/Icinga/Authentication/Auth.php(93): Icinga\Authentication\Auth->authExternal() #7 /usr/share/php/Icinga/Application/Web. in /usr/share/php/Icinga/Web/Session/PhpSession.php on line 105 Fatal error: Uncaught exception 'ErrorException' with message 'Unknown: open(/var/lib/php5/sess_3aabfsu76vcdj2hd2u3teofta5dvanpn, O_RDWR) failed: No space left on device (28)' in Unknown:0 Stack trace: #0 [internal function]: Icinga\Application\ApplicationBootstrap->Icinga\Application\{closure}(2, 'Unknown: open(/...', 'Unknown', 0, Array) #1 {main} thrown in Unknown on line 0 

要检查发生了什么,我试图在磁盘空间中find问题:

 # df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/hostname--vg-root 6.5G 4.8G 1.4G 78% / tmpfs 201M 412K 200M 1% /run ... ... /dev/sda1 236M 154M 70M 69% /boot 

问题发生在履行的节点:

 #df -i Filesystem Inodes IUsed IFree IUse% Mounted on /dev/mapper/hostname--vg-root 441504 441504 0 100% / ... ... /dev/sda1 62248 318 61930 1% /boot 

要检查我所做的小文件的最大部分在哪里:

 #for i in /*; do echo $i; find $i |wc -l; done 

并发现这一点在/ usr/ var / spool / icinga2 / perfdata /目录下

 /usr 177882 /var/spool/icinga2/perfdata 229326 

问题在于为什么icinga2不清理性能数据,以及如何手动清理而不损坏。 谢谢。

Icinga 2不会清理旋转的性能数据文件。 它希望外部守护进程/应用程序在处理后删除这些文件。 例如,如果您使用PNP,则NPCD守护进程将收集旋转的文件,然后处理并将其删除。

您还需要在监视中添加一个带有inode阈值的“磁盘”检查,以便事先了解这些问题。