Am 30.08.2015 um 15:20 schrieb Dewangga Bachrul Alam:
Hello!

Yes, I use first method and its works, but it's so many lines on
configuration file (each partition/disk have each configuration), that
could be defined on array. Any hints to simplify the configuration?

Isn't the default example configuration with service-apply-for rules
what you're looking for?

http://docs.icinga.org/icinga2/latest/doc/module/icinga2/chapter/configuring-icinga2-first-steps#services-conf

https://github.com/Icinga/icinga2/blob/master/etc/icinga2/conf.d/hosts.conf#L38
https://github.com/Icinga/icinga2/blob/master/etc/icinga2/conf.d/services.conf#L65

That way you may pass additional custom attributes as command parameters
(such as thresholds) directly from the host object itself.

Kind regards,
Michael


On 08/30/2015 05:32 PM, Assaf Flatto wrote:
Hi

You have two options: 1) write individual checks for each disk.
2) you the flags of the check_disk plugin :


Konsole output
-l, --local
    Only check local filesystems
-L, --stat-remote-fs
    Only check local filesystems against thresholds. Yet call stat on
remote filesystems
    to test if they are accessible (e.g. to detect Stale NFS Handles)
-M, --mountpoint
    Display the mountpoint instead of the partition
-m, --megabytes
    Same as '--units MB'
-A, --all
    Explicitly select all paths. This is equivalent to -R '.*'

and that can give you the answer you seek .

Assaf

On 29/08/15 21:28, Dewangga Bachrul Alam wrote:
Hello!

I got stuck for monitoring all available partition / disk on my linux
server, got clue from there
https://github.com/Icinga/icinga2/blob/master/doc/3-monitoring-basics.md, but
still got nothing.

The output on icingaweb2 should be print all on array
`disk_partitions = [ "/", "/tmp", "/var", "/home" ]` [1]

But, the output only show "/", the rest are gone.

Trying, second alternatives using `vars.disks["disk"] = {}`, got nothing
too, I got `DISK CRITICAL - /sys/kernel/config is not accessible:
Permission denied`. I've tried to disabling selinux on permissive mode,
it's not help.

My goal is want to monitor all available disk/partition on linux server,
and/or monitor the list of partition on `disk_partitions` array.

[1]
http://docs.icinga.org/icinga2/latest/doc/module/icinga2/chapter/plugin-check-commands
-- The partition(s). Multiple partitions must be defined as array.

Any help are appreciated.
Thank you.
_______________________________________________
icinga-users mailing list
icinga-users@lists.icinga.org
https://lists.icinga.org/mailman/listinfo/icinga-users


_______________________________________________
icinga-users mailing list
icinga-users@lists.icinga.org
https://lists.icinga.org/mailman/listinfo/icinga-users

_______________________________________________
icinga-users mailing list
icinga-users@lists.icinga.org
https://lists.icinga.org/mailman/listinfo/icinga-users


-- 
Michael Friedrich, DI (FH)
Senior Developer

NETWAYS GmbH | Deutschherrnstr. 15-19 | D-90429 Nuernberg
Tel: +49 911 92885-0 | Fax: +49 911 92885-77
GF: Julian Hein, Bernd Erk | AG Nuernberg HRB18461
http://www.netways.de | michael.friedr...@netways.de

** OSBConf 2015 - September - osbconf.org **
** OSMC 2015 - November - netways.de/osmc **
_______________________________________________
icinga-users mailing list
icinga-users@lists.icinga.org
https://lists.icinga.org/mailman/listinfo/icinga-users

Reply via email to