zabbix怎么关闭housekeep

zabbix怎么关闭housekeep,第1张

<pre name="code" class="html">Zabbix Housekeeper changes:

使用分区表需要关闭zabbix的history/trends的housekeeper。

Zabbix 2.0.x:

关闭housekeeper需要变更zabbix_server.conf配置文件:DisableHousekeeping=1.关闭了housekeeper,old events, audit entries, and user sessions也无法删除了。

Zabbix 2.2.x:

ZABBIX 2.2引入了更精确的housekeeper。所有的housekeeper配置在zabbix的web端更改,"Administration" ->"General" ,选择"Housekeeping" ,确保history和trends栏的"Enable internal housekeeping"的对勾去掉。

1. 保留历史数据

我们可以通过如下方式来设置保留数据的时长:

监控项(item)配置里

匹配更新监控项(item)

设置Housekeeper tasks

Housekeeper会定期删除过期的数据。如果数据不是特别有意义,建议你把保留时间设置短一些。可能你会说,那我想看我以前的数据图怎么办?好说,老数据一般不用精确到分秒,只要小时的平均数据即可,这样的话,趋势数据保留久一点即可。例如保存历史记录14天,趋势数据5年(5年,你孩子都从小学一年级到五年级了)

备注:如果history设置为0(设置为0的人是不想看历史数据或者硬盘没空间么?)做源,zabbix只会获取item的值,然后用与触发器,然后就没有然后了,不会纯蚂态存到数据库的。物羡

步骤如下:1.复制zabbix源程序misc/init.d/redhat下的启动脚本到/etc/init.d目录下cp/zabbix/zabbix-1.6.6/misc/init.d/redhat/zabbix_server_ctl/etc/init.d/zabbix_servercp/zabbix/zabbix-1.6.6/misc/唯租init.d/redhat/zabbix_agentd_ctl/etc/init.d/zabbix_agentd2.修改启动脚本使其支持redhat的chkconfig,分别在两个脚本的#!/bin/sh后加入如下两行注释,注意要行前要加“#”哦#chkconfig:-9595#description:ZabbixServer3.Zabbixagentd修改启动脚本中BASEDIR和ZABBIX_SUCKERD,制定到zabbix_server和zabbix_agentd的安装位置,如:BASEDIR=/指迟兆usr/旦团local/sbinZABBIX_SUCKERD=$BASEDIR/zabbix_server4.Zabbixagentd使用chkconfig将其加入init的启动服务chkconfig--addzabbix_serverchkconfig--addzabbix_agentdchkconfig--level345zabbix_serveronchkconfig--level345zabbix_agentdon5.使用chkconfig--list检查一下chkconfig--list|grepzabbix输出如下:zabbix_agentd0:off1:off2:off3:on4:on5:on6:offzabbix_server0:off1:off2:off3:on4:on5:on6:off

zabbix_agentd.exe  -d

c:\>zabbix_agentd.exe --help

usage:

  zabbix_agentd.exe [-c config-file]

  zabbix_agentd.exe [-c config-file] -p

  zabbix_agentd.exe [-c config-file] -t item-key

  zabbix_agentd.exe [-c config-file] -i [-m]

  zabbix_agentd.exe [-c config-file] -d [-m]

  zabbix_agentd.exe [-c config-file] -s [-m]

  zabbix_agentd.exe [-c config-file] -x [-m]

  zabbix_agentd.exe -h

  zabbix_agentd.exe -V

A Zabbix daemon for monitoring of various server parameters.

Options:

  -c --config config-file        Path to the configuration file

                                 (default: "C:\zabbix_agentd.conf")

  -f --foreground                Run Zabbix agent in foreground

  -p --print                     Print known items and exit

  -t --test item-key             Test specified item and exit

  -m --multiple-agents           For -i -d -s -x functions service name will

                         神数棚        include Hostname parameter specified in

                                 configuration file

Functions:

  -i --install                   Install Zabbix agent as service

  -d --uninstall        毕败         Uninstall Zabbix agent from service

  -s --start                     Start Zabbix agent service

  -x --stop                      Stop Zabbix agent service

  -h --help                   游则   Display this help message

  -V --version                   Display version number


欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/yw/8200210.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2023-04-14
下一篇 2023-04-14

发表评论

登录后才能评论

评论列表(0条)

保存