Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dev.icinga.com #10513] Add ipv4/ipv6 only to tcp and http CheckCommand #3584

Closed
icinga-migration opened this issue Nov 1, 2015 · 9 comments
Labels
area/itl Template Library CheckCommands enhancement New feature or request
Milestone

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/10513

Created by chrostek on 2015-11-01 15:32:48 +00:00

Assignee: chrostek
Status: Resolved (closed on 2015-11-05 14:40:25 +00:00)
Target Version: 2.4.0
Last Update: 2015-11-12 15:34:48 +00:00 (in Redmine)

Backport?: No
Include in Changelog: 1

check_tcp and check_http have arguments to use ipv4 or ipv6 only. This arguments are missing in ITL.

Attachments

Changesets

2015-11-02 07:32:04 +00:00 by chrostek a2c09a1

Add ipv4/ipv6 only to tcp, udp and http CheckCommand

fixes #10513

Signed-off-by: Gunnar Beutner <gunnar@beutner.name>
@icinga-migration
Copy link
Author

Updated by chrostek on 2015-11-01 15:35:05 +00:00

  • File added 0001-Add-ipv4-ipv6-only-to-tcp-and-http-CheckCommand.patch

Please merge this patch

@icinga-migration
Copy link
Author

Updated by gbeutner on 2015-11-02 07:04:35 +00:00

  • Status changed from New to Feedback
  • Assigned to set to chrostek

This won't work as intended if a host has both IPv4 and IPv6 addresses. $check_address$ would be the IPv4 address in that case - and adding -6 makes little difference. You'll also need to update the "ipv4-or-ipv6" template so that the right IP address is selected.

I'd suggest adding two custom variables in "ipv4-or-ipv6" and pick the right address based on which of these is set:

  • check_ipv4
  • check_ipv6

In the "tcp" command:
vars.check_ipv4 = "$tcp_ipv4$"
vars.check_ipv6 = "$tcp_ipv6$"

... and update the check_address function. :)

@icinga-migration
Copy link
Author

Updated by chrostek on 2015-11-02 07:13:24 +00:00

This works if you have a dyndns host with an ipv4 address :-)

for example:
$check_address$ is "chrostek.net" which is an dyndns host and check_tcp should only check this host with ipv4 (this domain also has an AAAA record)

@icinga-migration
Copy link
Author

Updated by gbeutner on 2015-11-02 07:39:14 +00:00

  • Status changed from Feedback to Assigned
  • Target Version set to 2.4.0

Using DNS names for 'address' and 'address6' is discouraged because it can make analysing problems more difficult (Is my DNS server failing? Or is the service having a problem?). Anyway, I've updated your patch so that Icinga uses 'address' when _ipv4 is set, and 'address6' when _ipv6 is set.

Would you be interested in checking which of the other monitoring plugins support -4/-6 and update those as well?

@icinga-migration
Copy link
Author

Updated by chrostek on 2015-11-02 07:39:25 +00:00

  • Status changed from Assigned to Resolved
  • Done % changed from 0 to 100

Applied in changeset a2c09a1.

@icinga-migration
Copy link
Author

Updated by chrostek on 2015-11-02 08:48:36 +00:00

Thanks! Unfortunately there is no other way with dyndns hosts ...

I will check which of the other monitoring plugins support -4/-6 and update those in the next days.

@icinga-migration
Copy link
Author

Updated by gbeutner on 2015-11-02 16:17:29 +00:00

  • Status changed from Resolved to Feedback

@icinga-migration
Copy link
Author

Updated by gbeutner on 2015-11-05 14:40:25 +00:00

  • Status changed from Feedback to Resolved

Well, ok, we won't be able to merge any further patches for 2.4.0 so I'm closing this ticket. The patches so far have already been merged though. When you find time to work on this (and have a patch) I'd ask that you submit a new ticket. :)

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2015-11-12 15:34:48 +00:00

  • Backport? changed from TBD to No

@icinga-migration icinga-migration added enhancement New feature or request area/itl Template Library CheckCommands labels Jan 17, 2017
@icinga-migration icinga-migration added this to the 2.4.0 milestone Jan 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/itl Template Library CheckCommands enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant