Commit Graph

4860 Commits

Author SHA1 Message Date
Alexander A. Klimov 203482a675 Config parser: save some memory allocations 2019-08-29 10:54:54 +02:00
Michael Friedrich b75e1585d6
Merge pull request #7449 from Icinga/feature/warn-set-global-var
DSL: warn on x=y if x is a global variable
2019-08-27 14:53:29 +02:00
Michael Friedrich 9d6ee44e71
Merge pull request #7346 from Icinga/feature/check-plugins-code-page-7110
DaemonCommand#Run(): set code page to UTF-8
2019-08-27 14:51:30 +02:00
Alexander A. Klimov 429080ee1c DSL: warn on x=y if x is a global variable 2019-08-27 13:30:02 +02:00
Alexander A. Klimov efc7f2cf8d Correct current_concurrent_checks to actually running checks
refs #7416
2019-08-15 13:39:01 +02:00
Michael Friedrich c2e1d023e2
Merge pull request #7421 from Icinga/feature/threadpool-metric
Expose metric current_pending_callbacks
2019-08-15 10:51:31 +02:00
Michael Friedrich 2760748d78 Fix and improve logging for runtime object sync
config::UpdateObject would create a new object, but this may
have been silently ignored with 'ignore_on_error' - downtimes, etc.
Since we cannot simply fetch the error from inside the config compiler,
we'd just check whether there's a config object created at this stage.
This happens synchronously, and once there is, log something.

The previous code always logged the creation, even if the downtime
was ignored, e.g. when the first master sent one for local host objects.

This commit also adds more details: identity, endpoint, zone to extract
the MessageOrigin details into log messages for better troubleshooting
and debugging.

refs #7198
2019-08-15 09:29:05 +02:00
Alexander A. Klimov 448a991404 Expose metric current_pending_callbacks 2019-08-14 17:22:27 +02:00
Alexander A. Klimov a58a5feee3 Introduce ThreadPool#GetPending() 2019-08-14 17:12:59 +02:00
Michael Friedrich 43ea6fb636
Merge pull request #7419 from Icinga/bugfix/downtime-loop-activate-origin
Fix object create/delete config object cluster loop (missing message origin)
2019-08-14 16:29:08 +02:00
Michael Friedrich 5b36ff0787 Properly parse the Icinga version for minimum version in the 'icinga' check
fixes #7415
2019-08-14 13:15:05 +02:00
Michael Friedrich 96f62d2d34 Add Utility::ParseVersion() and unit tests
This now uses a regex to extract the short version
similar to how Icinga Web 2 does it.

Additional unit tests prove the rule.
2019-08-14 11:22:55 +02:00
Michael Friedrich 7c1f716dad Fix cookie with ActivateItems 2019-08-13 16:09:26 +02:00
Michael Friedrich c30edd0a34 Fix message origin for runtime created config object (create/delete events) 2019-08-13 15:05:47 +02:00
Michael Friedrich f9812ee1aa
Merge pull request #7404 from Icinga/bugfix/livestatus-interval
Explicitly write the 1.x legacy attribute 'interval_length' for Livestatus
2019-08-07 17:32:38 +02:00
Michael Friedrich d8400699f9
Merge pull request #7353 from Icinga/bugfix/influxdbwriter-skip-tags-7341
InfluxdbWriter: skip non-resolvable tags
2019-08-07 17:15:24 +02:00
Michael Friedrich 3f18741c41 Explicitly write the 1.x legacy attribute 'interval_length' for Livestatus
fixes #7402
2019-08-07 15:23:04 +02:00
Michael Friedrich 686f5d8ca7
Merge pull request #7397 from Icinga/bugfix/umbrella-logging-systemd-7394
icinga2 daemon --close-stdio: keep console log open during first config validation
2019-08-07 13:44:07 +02:00
Michael Friedrich 01fe243f23 Log a hint after failed config validation for systemd users 2019-08-07 12:03:17 +02:00
Michael Friedrich 59081c4f82
Merge pull request #7400 from Icinga/bugfix/cib-stats-concurrent-checks
Fix missing stats for current_concurrent_checks via REST API
2019-08-06 15:25:44 +02:00
Michael Friedrich 550a92f077 Fix missing stats for current_concurrent_checks via REST API
It was added inside the 'icinga' check task, but not for the REST API.
Thanks for asking, @Thomas-Gelf
2019-08-06 14:51:10 +02:00
Michael Friedrich 743dcad35d Improve logging for downtime/ack events (add, remove, expire)
fixes #7374
2019-08-06 13:28:58 +02:00
Alexander A. Klimov 6418c2ebb7 icinga2 daemon --close-stdio: keep console log open during first config validation
refs #7394
2019-08-05 18:30:45 +02:00
Michael Friedrich ac4f92ca69
Merge pull request #7391 from Icinga/feature/cluster-sync-avoid-non-utf-8
Cluster sync: Only sync valid UTF8 content (text config, no binaries)
2019-08-05 16:48:49 +02:00
Michael Friedrich 8d071c8d30 DB IDO: Fix upgrade script for 2.11.0 (drop index only if existing)
fixes #7393
2019-08-05 13:03:38 +02:00
Michael Friedrich c42a2583f0 Cluster sync: Only sync valid UTF8 content (text config, no binaries)
- *.conf files are sanitized automatically.
- Other files detect sanitizing and treat that as unsupported type

refs #7382
2019-08-02 16:06:32 +02:00
Michael Friedrich f58d1ef7f7 Revert "API: Improve error handling for 'schedule-downtime' action"
This reverts commit 8ca38302fc.
2019-08-01 14:03:44 +02:00
Michael Friedrich 8f3a1335dc Revert "API: Don't be so strict with the downtime start_time"
This reverts commit 3b7cf5b9b5.
2019-08-01 14:03:40 +02:00
Michael Friedrich ebd6735c70 TLS Ciphers: Add compatibility suites for older agents (el7) 2019-07-30 10:55:29 +02:00
Alexander A. Klimov d7b1127730 InfluxdbWriter: skip non-resolvable tags
refs #7341
2019-07-23 18:21:38 +02:00
Michael Friedrich 0fd2fc0a4f Only include SSL_CTX_set_ecdh_auto for OpenSSL < 1.1.0 2019-07-23 17:39:02 +02:00
Michael Friedrich 647348fbca CLI: Rename client -> agent 2019-07-20 12:53:19 +02:00
Alexander A. Klimov d7e52824c8 DaemonCommand#Run(): set code page to UTF-8
refs #7110
2019-07-19 18:00:46 +02:00
Michael Friedrich 844e821cd1
Merge pull request #7320 from Icinga/feature/foreground-5230
Rework reload handling on *nix
2019-07-18 18:24:22 +02:00
Michael Friedrich f9f86e3f22
Merge pull request #7272 from Icinga/feature/notification-logging
Improve type logging for notifications
2019-07-17 15:16:45 +02:00
Michael Friedrich 71cf491a3b
Merge pull request #7331 from Icinga/bugfix/unit-tests-packaging-7327
Shutdown timers cleanly on exit
2019-07-17 15:16:04 +02:00
Alexander A. Klimov 80d976fed6 Shutdown timers cleanly on exit
refs #7327
2019-07-17 13:53:43 +02:00
Michael Friedrich 8098f4d54d Improve type logging for notifications 2019-07-16 13:46:16 +02:00
Alexander A. Klimov 31e5394fe9 Fix style
refs #5230
2019-07-16 11:45:23 +02:00
Alexander A. Klimov c385355c38 DaemonCommand: make the atomics a bit more atomic
Just to be sure.

refs #5230
2019-07-16 11:39:09 +02:00
Alexander A. Klimov 4ee9ac16b4 Fix missing comments
refs #5230
2019-07-16 11:11:10 +02:00
Alexander A. Klimov 372ecd8a72 Forward SIGUSR1
refs #5230
2019-07-15 18:36:34 +02:00
Alexander A. Klimov 3584ad97d8 Fix missing log messages
refs #5230
2019-07-15 18:29:15 +02:00
Alexander A. Klimov ac29b3b93a Adjust sd_notify()
refs #5230
2019-07-15 17:04:55 +02:00
Alexander A. Klimov 06b504f291 Adjust PID file management
refs #5230
2019-07-15 17:04:53 +02:00
Alexander A. Klimov 368ebf4fbf Catch programming errors
refs #5230
2019-07-15 15:24:07 +02:00
Alexander A. Klimov 37a3e7e4d5 Application::RunEventLoop(): forward restart requests to umbrella process
refs #5230
2019-07-15 15:23:37 +02:00
Alexander A. Klimov 249408209d Reload on SIGHUP
refs #5230
2019-07-15 15:23:34 +02:00
Alexander A. Klimov c303d08c24 Do the actual work in a separate process on *nix
refs #5230
2019-07-15 15:18:31 +02:00
Michael Friedrich f4942fd359
Merge pull request #7318 from Icinga/bugfix/tls-options
TLS: Ensure to specify options in one place
2019-07-15 15:08:58 +02:00