nagios为监控图像添加图片
2015-09-21 14:45
573 查看
1、 背景介绍
在监控web页面上显示主机都为问号,如下图所示:本文的主要目的就是将监控的图片添加进去,让监控图像变得美观。
2、 图片的下载地址
图片的下载地址如下:https://exchange.nagios.org/directory/Graphics-and-Logos/Images-and-Logos
图片下载之后,解压缩上传的服务器路径如下:
3、 nagios设置
可以设置图标的配置文件如下:主要可以设置的地方就是定义主机的地方,如下所示:
也可以在模板中进行定义,如下所示:
两个参数的说明的如下:
参数icon_image主要是用来设置鼠标在悬浮状态下信息显示的时候有图标出现
参数statusmap_image主要用来设置在map选项界面中的图标,如下所示:
4、 重启nagios
在进行设置完成之后,重启nagios服务即可:5、几个需要注意的地方
statusmap_image:此图标用来定义在状态图的时候的图标,可以使用的格式为JPEG,PNG和GIF,在使用这些格式的时候,会占用大量的CPU时间,从而推荐使用gd2格式的图形。
icon_image:
此图标可以使用的格式为jpeg,PNG和GIF格式图形,主要用来显示和主机有关的界面。
icon_image: This variable is used to define the name of a GIF, PNG, orJPG image that should be associated with this host. This image will bedisplayed in the various places in the CGIs. The image will look best if it is40x40 pixels in size.
Images for hosts are assumed to be in the logos/subdirectory in your HTML images directory (i.e. /usr/local/nagios/share/images/logos).
statusmap_image: This variable is used to define the name of an image thatshould be associated with this host in the statusmap CGI.
You can specify a JPEG, PNG, and GIFimage if you want, although I would strongly suggest using a GD2 format image,as other image formats will result in a lot of wasted CPU time when thestatusmap image is generated. GD2 images can be created from PNG images
by usingthe pngtogd2 utility supplied with Thomas Boutell's gd library.
The GD2 images should be created in uncompressed formatin order to minimize CPU load when the statusmap CGI is generating the networkmap image. The image will look best if it is 40x40 pixels in size. You canleave these option blank if you
are not using the statusmap CGI. Images forhosts are assumed to be in the logos/ subdirectory in your HTML imagesdirectory (i.e. /usr/local/nagios/share/images/logos).
相关文章推荐
- //打印iOS 100次 并且后面跟着打印的次数 当次数为4的倍数的时候 //省略次数,只打印iOS
- 如何实现iOS图书动画:第1部分(下)
- iOS学习-压缩图片(改变图片的宽高)
- iOS开发遇到的坑之一: 开发遇见如下错误:Undefined symbols for architecture arm64
- IOS图片缓存
- 如何实现iOS图书动画:第1部分(上)
- 关于页面跳转过程中出现两个界面view出现重叠的处理
- iOS Xcode: linker command failed with exit code 1 (use -v to see invocation) 处理方法
- ios开发日记11 对tableView三种计算动态行高方法的分析
- 自定义iOS的Back按钮(backBarButtonItem)和pop交互手势(interactivepopgesturerecognizer)
- 统一设计,iOS6也玩扁平化
- iOS:hidesBottomBarWhenPushed的正确用法
- iOS-设置状态栏白色以及覆盖状态栏
- iOS 9 xcode7 适配问题
- iOS 如何实现View的复用(以访问相册为例)
- ios NSDictionary\NSMutableDictionary
- iOS 日期格式 星期几 本地
- iOS集成支付宝
- iOSCoreAnimation动画系列教程(一):CABasicAnimation【包会】
- Thinkpad X240修改bios引导方式