Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 352868

Summary: net-misc/samba-3.5.6: Request for ipv6 use flag
Product: Gentoo Linux Reporter: Martin Mokrejš <mmokrejs>
Component: Current packagesAssignee: Gentoo's SAMBA Team <samba>
Status: RESOLVED WONTFIX    
Severity: normal CC: bkohler, harrisl
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: samba-3.5.6_disable_ipv6.ebuild.patch

Description Martin Mokrejš 2011-01-26 22:33:27 UTC
Samba's configure automatically detects IPv6-capable operating system. Unfortunately, there is no --disable-ipv6 option. Users often face messages like:

matchname: host name/address mismatch: ::ffff:192.168.0.2 != my.foo.bar

and are instructed to place an entry into /etc/hosts. That is impractical on large networks to catch every such a case in advance. Alternatively, hope is that forcing samba to bind only to IPv4 interfaces (using "interfaces = " line)) avoids the problem or that possibly omitting the "hosts allow = " line does not escalate the resolving issue. All of that is ugly.

This patch desperately patches the generated config.status and overwrites the value with zero, thus disabling IPv6 support in samba (provided USE=-ipv6).
Now, my var/log/messages and /var/log/samaba/log.* files are without these messages again.

The USE=-ipv6 could be useful to bug #283809.
Comment 1 Martin Mokrejš 2011-01-26 22:33:57 UTC
Created attachment 260818 [details, diff]
samba-3.5.6_disable_ipv6.ebuild.patch
Comment 2 Víctor Ostorga (RETIRED) gentoo-dev 2011-06-29 17:43:23 UTC
This is a curious bug, a while ago people were asking for ipv6 support ( bug 187905 ) and now you don't like it :)

Anyway, you'll be able to disable ipv6 in samba by adding to smb.conf :
bind interfaces only = yes
interfaces = 127.0.0.1 ip_address

To have it as a USE flag it's needed to mess with source3/configure.in and company, in other words, patching autoconf process

Patches are welcome