This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 1021255 - mtr does not work when IPv6 is disabled
mtr does not work when IPv6 is disabled
Product: Fedora
Classification: Fedora
Component: mtr (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Michal Sekletar
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2013-10-20 14:30 EDT by Philippe Troin
Modified: 2016-05-13 17:17 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-05-13 17:17:21 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Disable IPv6 DNS lookups at runtime if not PF_INET6 socket can be created. (2.51 KB, patch)
2013-10-20 14:30 EDT, Philippe Troin
no flags Details | Diff

  None (edit)
Description Philippe Troin 2013-10-20 14:30:16 EDT
Created attachment 814302 [details]
Disable IPv6 DNS lookups at runtime if not PF_INET6 socket can be created.

Description of problem:
When IPv6 is disabled and PF_INET6 sockets are unavaible (eg. by booting with ipv6.disable=1), mtr fails:

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Boot with kernel command line ipv6.disable=1
2. Run mtr localhost

Actual results:
# xmtr localhost       
Unable to allocate IPv6 socket for nameserver communication: Address family not supported by protocol
[1]    31171 exit 255   xmtr localhost

Expected results:
Usual mtr output.

Additional info:
I have attached a patch that fixes the problem.
Comment 1 Bill McGonigle 2014-05-25 16:05:12 EDT
Ah, gee, I should have looked here before fixing this on my own.  My patch, SPEC, SRPM, f19 RPM build here:

The patch referenced on github:

wouldn't apply cleanly on top of the existing fedora patches, so I just manually applied those changes onto a BUILD tree and added that to the SPEC.

mtr works again here.  We don't run an ipv6 stack since we're not currently using it (reducing exposure w/r/t unused code).
Comment 2 Fedora End Of Life 2015-01-09 15:19:21 EST
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 3 Jaroslav Reznik 2015-03-03 10:09:18 EST
This bug appears to have been reported against 'rawhide' during the Fedora 22 development cycle.
Changing version to '22'.

More information and reason for this action is here:
Comment 4 Bill McGonigle 2015-03-12 16:10:26 EDT
supposedly this is fixed in 0.86.  The auto-nag version bug is bug 1172607 .  I suppose this one could depend on that one.

Probably goes without saying, but shipped mtr still doesn't work in f21 in an IPv4 environment.
Comment 5 Philippe Troin 2015-03-16 11:30:08 EDT
Well F20's mtr-0.85-4.fc20.x86_64 does work.

It complains:
Unable to allocate IPv6 socket for nameserver communication: Address family not supported by protocol

but it seems to fallback to PF_INET sockets for DNS traffic, and does the job fine.
Comment 6 tony 2015-03-28 16:11:15 EDT
You may want to try using the 'newdns' branch from the github source.  The newdns branch drops mtr's own resolver routine in favor of the standard libc resolver.  

I'd also like to put in a plug to update the RPMs in RHEL as well since 0.75 is a bit dated and missing several important bugfixes.
Comment 7 Michal Sekletar 2016-05-13 17:17:21 EDT
Doing some late spring cleaning. Seems like this work correctly now.

Note You need to log in before you can comment on or make changes to this bug.