Giter Club home page Giter Club logo

rabe-zabbix's People

Contributors

chrono-meter avatar cweiland avatar dependabot[bot] avatar hairmare avatar ka2er avatar paraenggu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rabe-zabbix's Issues

ipmi-sensor-discovery.sh: 47: set: Illegal option -o pipefail

Hallo,
discovered your work on share.zabbix.com.
I downloaded the script and tried to run if from shell, but it fails immediately. Any idea why this happens?
Thank you!

EDIT: I'm on Debian 9 Stretch amd64 with Zabbix 3.4.x
If I comment out line 47 the script seems to work.

zabbix-agent can't sudo with selinux-policy-3.13.1-229.el7_6.6

Some new policy seems to have been enforced and sudo (in UserParameters) for things like some app/lvm template are getting denied.

The new(?) SELinux bools don't seem to work. I tried:

setsebool zabbix_run_sudo=1
setsebool domain_kernel_load_modules=1

The current workaround is to semanage permissive -a zabbix_agent_t until we can fix our rabezbxzabbixagent SELinux module to let the zabbix user use sudo to run things like lvs.

On some investigation I found that this might be specific and due to how our pam stack is configured as the servers are configured as part of a freeipa domain.

I'm preparing a pr to address this and it should be ready after some more testing.

ipmitool dcmi power reading

I couldnt find template for the power reading. For example ipmitool can be used as follows:

# ipmitool dcmi power reading

    Instantaneous power reading:                   197 Watts
    Minimum during sampling period:                175 Watts
    Maximum during sampling period:                242 Watts
    Average power reading over sample period:      190 Watts
    IPMI timestamp:                           Sun Mar  6 15:13:42 2022
    Sampling period:                          00123893 Seconds.
    Power reading state is:                   activated

Is there a way to get this information from your templates?

template import

Template_App_MD-RAID_active.xml
Cannot read XML: (41) Specification mandate value for attribute data-pjax-transient [Line: 43 | Column: 91].

Zabbix 3.4

Value should be a JSON object

When using your script in Zabbix 3.4 it gets the following error: Value should be a JSON object." I don't think the output of your script produces a properly JSON formatted output anymore with the changes in LLD rules now in Zabbix 3.4. This seems to be an issue now with all your scripts, not just this one.

Could you check?

value should be a json object

Faulty drive/degraded state doesn't trigger anything

Hello,

I setup this wonderful plugin successfully. However, there is not alerts triggered even if I manually set a disk to faulty state.

My Zabbix Agent is used in passive mode so I just changed "Zabbix Agent (active)" to "Zabbix Agent" in discovery templates settings.

Here's the output of few debug commands :

su -c 'zabbix_agentd -t rabe.raid.md.raid-device.discovery' -s /bin/bash zabbix
rabe.raid.md.raid-device.discovery [t|{"data":[{"{#MD_RAID_RAID_DEV_NAME}":"md0"}]}]

mdadm -D /dev/md0

/dev/md0:
           Version : 1.2
     Creation Time : Fri Mar 27 19:42:13 2020
        Raid Level : raid5
        Array Size : 3906762752 (3725.78 GiB 4000.53 GB)
     Used Dev Size : 1953381376 (1862.89 GiB 2000.26 GB)
      Raid Devices : 3
     Total Devices : 3
       Persistence : Superblock is persistent

     Intent Bitmap : Internal

       Update Time : Sun Mar 29 13:25:00 2020
             State : clean, degraded 
    Active Devices : 2
   Working Devices : 2
    Failed Devices : 1
     Spare Devices : 0

            Layout : left-symmetric
        Chunk Size : 512K

Consistency Policy : unknown

              Name : scarif:0  (local to host scarif)
              UUID : a54c09d4:af8606cc:97bc4ab1:5d7c5f77
            Events : 23977

    Number   Major   Minor   RaidDevice State
       0       8        1        0      active sync   /dev/sda1
       -       0        0        1      removed
       3       8       33        2      active sync   /dev/satac1

       1       8       17        -      faulty   /dev/satab1

My host's items discovered screenshot
https://i.ibb.co/FVcQpMM/Capture-d-cran-de-2020-03-29-17-04-49.png

My host's triggers for MD RAID active
https://i.ibb.co/g9qs4rj/Capture-d-cran-de-2020-03-29-17-08-21.png

Am I doing anything wrong ?

Thank you :)

LVM unavailable options

Hello! I'm trying to use the LVM app. It looks well thought out and well documented. I got most of it working, like discovery. Many items work fine as well, but some don't.

When I looked into it, it seems my 'lvs' does not support some -o options, specifically: data_user, metadata_free, metadata_free_percent, data_free_percent, data_free. There may be more, but these are the ones I'd like to use.

They also don't show up in lvs -o help. I'm using lvm2 version 2.03 on Ubuntu. I also looked on a Centos server, but it looks like the options aren't there as well.

Are you using a different lvs tool? Do you have any idea how to make this working?

Thanks!

Regarding Debian

I saw that the package is available for CentOS. Do you think it would work on Debian as well? We could really use that, but our system is on Debian.

app/LVM is working fine in Zabbix 4.0 LTS

I don't know if you get that much feedback, I just wanted to point out that the LVM template works like it should in Zabbix 4.0 (on the zabbix-share site of the project it mentioned Zabbix 3.0.x)

Cheers!

  • tschaerni

UserParameter=custom.md.discovery do not parse raid0

So I have ubuntu 20.04 with raid0


 mdadm -D /dev/md0
/dev/md0:
           Version : 1.2
     Creation Time : Mon Sep 28 21:34:49 2020
        Raid Level : raid0
        Array Size : 7813520384 (7451.55 GiB 8001.04 GB)
      Raid Devices : 4
     Total Devices : 4
       Persistence : Superblock is persistent

       Update Time : Mon Sep 28 21:34:49 2020
             State : clean 
    Active Devices : 4
   Working Devices : 4
    Failed Devices : 0
     Spare Devices : 0

            Layout : original
        Chunk Size : 512K

Consistency Policy : none

              Name : ubuntu-server:0
              UUID : b14fa1a1:96da7eba:8fd8a81c:36258895
            Events : 0

    Number   Major   Minor   RaidDevice State
       0       8       34        0      active sync   /dev/sdc2
       1       8       17        1      active sync   /dev/sdb1
       2       8        1        2      active sync   /dev/sda1
       3       8       49        3      active sync   /dev/sdd1

I copied your userparameter_md.conf file into /etc/zabbix/zabbix_agentd.d folder . For the servers that have configured raid1 - this parameter works well:
UserParameter=custom.md.discovery,cat /proc/mdstat | grep -B 1 -E "(U+|_+)" | awk 'BEGIN { printf "{\"data\":["}; /^md/ { printf c"{\"{#MDNAME}\":\""$1"\"}";c=","}; END{ print "]}" }'

But I have raid0 and this grep cat /proc/mdstat | grep -B 1 -E "(U+|_+)" not parsed it. It returned NULL, because it parse UU that is not used for raid0.
And if you try to use this user parameter:
UserParameter=custom.md.discovery,cat /proc/mdstat | awk 'BEGIN { printf "{\"data\":["}; /^md/ { printf c"{\"{#MDNAME}\":\""$1"\"}";c=","}; END{ print "]}" }' - zabbix will parse raid0 devices.

Update MD-RAID template README with instructions on using it in passive mode

I have successfully got your MD-RAID template to work under Zabbix 4.0 but I had to change a few settings to use passive instead of active monitoring. I think the MD-RAID README should be updated with instructions on how to do this because its not at all obvious (to Zabbix newbs) and it took me a while to work it out / remember how to do it.

There may be a better way to do it but I used these steps (after following the existing installation instructions):

Under the Zabbix web interface go to Configuration -> Hosts -> then click 'Discovery' next to the relevant host. Now click 'Item prototypes' next to the 'RAID device (MD) discovery' rule then click on each of the 5 item prototypes and change the Type of all 5 Raid device item prototypes from 'Zabbix agent (active)' to 'Zabbix agent'.

Doesn't work under Zabbix 4.0

I have installed this template under zabbix 4.0 and tested it with a Ubuntu 16.04 client (zabbix-agent) using mdadm raid 10. After installing the client config and resetting the zabbix agent on the client there are no errors in the agent log but I don't see any data relating to mdadm when I check out the "Latest data" page for the mdadm using zabbix client.

Import fails with Zabbix 5.2

Cannot read XML: (41) Specification mandates value for attribute data-pjax-transient [Line: 68 | Column: 89].

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.