voxpupuli / puppet-zabbix

Puppet module for creating and maintaining zabbix components with puppet.
https://forge.puppet.com/puppet/zabbix
Apache License 2.0
79 stars 228 forks source link

Bootstrap agent2 support #824

Closed fe80 closed 2 months ago

fe80 commented 2 years ago

Pull Request (PR) description

This Pr bootstrap a support for zabbix-agent2 It's possible to use agent2 with this configration:

      'agent_configfile_path' => '/etc/zabbix/zabbix_agent2.conf',
      'include_dir'           => '/etc/zabbix/zabbix_agent2.d',
      'pidfile'               => '/var/run/zabbix/zabbix_agentd2.pid',
      'servicename'           => 'zabbix-agent2',
      'zabbix_package_agent'  => 'zabbix-agent2',
      'binary_location'       => '/usr/sbin/zabbix_agent2',

I actually not test with windows kernel (but I need it in few month)

This Pull Request (PR) fixes the following issues

692

fe80 commented 2 years ago

Hello @bastelfreak

I've also included a fix for EnableRemoteCommands, still available on zabbix agentd but not in zabbix agent2.

This fix a bug included in this merge request #767

fe80 commented 1 year ago

Hello @bastelfreak

I've merge your master for fix Ci. I still have an error, but only on Debian 10 and on Zabbix server part. I can't read the full log on the fail only last 10 lines. I can't understand why it's fail.

Henrik-Hansson commented 1 year ago

Hi, I'm very interested in this PR, how can I help to get this merged? BR, Henrik

marek130 commented 1 year ago

Me too, This feature is exactly what I need 👍

ekohl commented 1 year ago

If you go to the action there's a wheel icon on the top right (next to Search logs). There you can view the raw log where it shows this:

2022-09-14T08:00:13.2944101Z   Building dependency tree...
2022-09-14T08:00:13.2944431Z   Reading state information...
2022-09-14T08:00:13.2944867Z   E: Unable to locate package zabbix-sql-scripts
2022-09-14T08:00:13.2981126Z   Error: /Stage[main]/Zabbix::Server/Package[zabbix-sql-scripts]/ensure: change from 'purged' to 'present' failed: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold install zabbix-sql-scripts' returned 100: Reading package lists...
2022-09-14T08:00:13.2982006Z   Building dependency tree...
2022-09-14T08:00:13.2982414Z   Reading state information...
2022-09-14T08:00:13.2982991Z   E: Unable to locate package zabbix-sql-scripts

Now it's also possible this is already failing on the master branch, but I hope it helps.

fe80 commented 1 year ago

I've merge master but it's fail on other spec fix on #850

root-expert commented 1 year ago

@fe80 Please rebase (not merge commit) with master branch to fix the specs and move this forward. Thanks!

root-expert commented 1 year ago

This will need some documentation in README and maybe in REFERENCE using @example so it's transparent to users how to install agent v2 without the need to look at the code.

fe80 commented 1 year ago

Hello @root-expert ,

I added documentation, but rspec is fail since relase v9.0.0 of Apache module (Drop Apache 2.2 support). Do you want I fix this fail or you looking that to another MR ?