Bug 196725 - net-mgmt/nagios-plugins: Fix check_dig on > 10 with IPv6
Summary: net-mgmt/nagios-plugins: Fix check_dig on > 10 with IPv6
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Mathieu Arnold
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-01-14 14:28 UTC by Brad Davis
Modified: 2015-01-19 17:53 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (mat)


Attachments
patch (1.18 KB, patch)
2015-01-14 14:28 UTC, Brad Davis
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brad Davis freebsd_committer freebsd_triage 2015-01-14 14:28:15 UTC
Created attachment 151623 [details]
patch

With IPv6 queries the flags are put in out of order which prevent drill from ever returning:

# /usr/local/libexec/nagios/check_dig -6 -H ::1 -T AAAA -l ns4.example.com -a ::2 -v                                                    
/usr/bin/drill  @::1 -z -p 53 ns4.example.com AAAA -6
Looking for: '::2'
CRITICAL - Plugin timed out while executing system call
#

The patch fixes the flags to be before the query:

# /usr/local/libexec/nagios/check_dig -6 -H ::2 -T AAAA -l ns4.liquidneon.com -a ::2 -v
/usr/bin/drill  @::2 -z -p 53 -6 ns4.example.com AAAA
Looking for: '2607:fc50:1000:8000::2'
;; ANSWER SECTION:
ns4.example.com.     3600    IN      AAAA    ::2
DNS OK - 0.070 seconds response time (ns4.exampe.com. 3600 IN AAAA ::2)|time=0.069712s;;;0.000000
#
Comment 1 Bugzilla Automation freebsd_committer freebsd_triage 2015-01-14 14:28:15 UTC
Auto-assigned to maintainer mat@FreeBSD.org
Comment 2 Brad Davis freebsd_committer freebsd_triage 2015-01-14 14:35:13 UTC
Note this only affects when running check_dig with the -6 argument.
Comment 3 commit-hook freebsd_committer freebsd_triage 2015-01-19 17:53:29 UTC
A commit references this bug:

Author: mat
Date: Mon Jan 19 17:52:58 UTC 2015
New revision: 377447
URL: https://svnweb.freebsd.org/changeset/ports/377447

Log:
  Fix check_dig on > 10 with IPv6

  PR:		196725
  Submitted by:	brd
  Sponsored by:	Absolight

Changes:
  head/net-mgmt/monitoring-plugins/Makefile
  head/net-mgmt/monitoring-plugins/files/extra-patch-dig-to-drill.diff
  head/net-mgmt/nagios-plugins/Makefile
  head/net-mgmt/nagios-plugins/files/extra-patch-dig-to-drill.diff