Using Subversion v1.8.4 to checkout repositories FAILs @ name-resolution if using a URL-target, rather than an IP-address-target, when resolvers in /etc/resolv.conf point to nameservers @ addresses.
I raised this issue @ Subversion ML (http://news.gmane.org/gmane.comp.version-control.subversion.user), and was advised to bring it to dev@apr.apache.org: "It is either an APR issue, or a packaging issue. APR's apr_sockaddr_info_get function, which Subversion uses to resolve a hostname, does not have a flag to enable or disable IPv6 DNS lookups. All your list above proves is that your APR does not support DNS lookups to IPv6 name servers. I don't know whether this is a general limitation of APR, or whether your particular version of APR is too old, or compiled in a way that those lookups are disabled. In any case, I suggest you take that question to the APR developers; it's dev@apr.apache.org. But please be prepared to give a bit more information about your environment, starting with your OS version and APR version." In summary: (1) if resolv.conf -> IPv4, packaged svn co @ URL-target ====> OK (2) if resolv.conf -> IPv6, packaged svn co @ URL-target ====> FAIL (3) if resolv.conf -> IPv4, built-from-src svn co @ URL-target ====> OK (4) if resolv.conf -> IPv6, built-from-src svn co @ URL-target ====> FAIL (5) if resolv.conf -> IPv4, packaged svn co @ IPv4-address-target ====> OK (6) if resolv.conf -> IPv6, packaged svn co @ IPv4-address-target ====> OK (7) if resolv.conf -> IPv4, built-from-src svn co @ IPv6-address-target ====> OK (8) if resolv.conf -> IPv6, built-from-src svn co @ IPv6-address-target ====> OK Q: Is this an APR bug or other config issue? --darx Details: uname -a Linux darxdev.int 3.7.10-1.16-desktop #1 SMP PREEMPT Fri May 31 20:21:23 UTC 2013 (97c14ba) x86_64 x86_64 x86_64 GNU/Linux With each/either of 2 subversion+apr instances: (1) distro-packaged rpm -qa | egrep -i "apr|subversion" libapr1-devel-1.4.8-48.1.x86_64 libapr-util1-devel-1.5.2-39.1.x86_64 libapr1-1.4.8-48.1.x86_64 libapr-util1-1.5.2-39.1.x86_64 subversion-1.8.4-127.1.x86_64 /usr/bin/svn --version --verbose /usr/bin/apr-1-config --version 1.4.8 /usr/bin/apr-1-config --cppflags --cflags --ldflags --libs -DLINUX -D_REENTRANT -D_GNU_SOURCE -pthread -lpthread -ldl /usr/bin/svn --version --verbose svn, version 1.8.4 (r1534716) Copyright (C) 2013 The Apache Software Foundation. This software consists of contributions made by many people; see the NOTICE file for more information. Subversion is open source software, see http://subversion.apache.org/ The following repository access (RA) modules are available: * ra_svn : Module for accessing a repository using the svn network protocol. - with Cyrus SASL authentication - handles 'svn' scheme * ra_local : Module for accessing a repository on local disk. - handles 'file' scheme * ra_serf : Module for accessing a repository via WebDAV protocol using serf. - using serf 1.3.2 - handles 'http' scheme - handles 'https' scheme System information: * running on x86_64-unknown-linux-gnu - openSUSE 12 (Dartmout) [Linux 3.7.10-1.16-xen] * linked dependencies: - APR 1.4.8 (compiled with 1.4.6) - APR-Util 1.5.2 (compiled with 1.4.1) - SQLite 3.7.15.1 (static) ldd /usr/bin/svn | egrep -i apr libaprutil-1.so.0 => /usr/lib64/libaprutil-1.so.0 (0x00007fa1753da000) libapr-1.so.0 => /usr/lib64/libapr-1.so.0 (0x00007fa1751ab000) (2) locally built cd /home/darxSVN_TEST wget http://download.nextag.com/apache/apr/apr-1.4.8.tar.gz wget http://download.nextag.com/apache/apr/apr-util-1.5.2.tar.gz wget http://psg.mtu.edu/pub/apache/subversion/subversion-1.8.4.tar.gz tar zxvf apr-1.4.8.tar.gz tar zxvf apr-util-1.5.2.tar.gz tar zxvf subversion-1.8.4.tar.gz cd apr-1.4.8 ./configure \ --prefix=/home/darxSVN_TEST/apr1 \ --libdir=/home/darxSVN_TEST/apr1/lib64 \ --enable-ipv6 make -j4 make install cd ../apr-util-1.5.2 ./configure \ --prefix=/home/darxSVN_TEST/apr1 \ --libdir=/home/darxSVN_TEST/apr1/lib64 \ --with-apr=/home/darxSVN_TEST/apr1/bin/apr-1-config make -j4 make install cd .. ls -al ./apr1/lib64/*.so lrwxrwxrwx 1 root root 17 Nov 2 11:50 ./apr1/lib64/libapr-1.so -> libapr-1.so.0.4.8* lrwxrwxrwx 1 root root 21 Nov 2 11:50 ./apr1/lib64/libaprutil-1.so -> libaprutil-1.so.0.5.2* cd ./subversion-1.8.4 LDFLAGS="-L/home/darxSVN_TEST/apr1/lib64 -Wl,-rpath,/home/darxSVN_TEST/apr1/lib64 -laprutil-1 -lapr-1" LIBS="-laprutil-1 -lapr-1" make clean ./configure \ --prefix=/home/darxSVN_TEST/svn184 \ --libdir=/home/darxSVN_TEST/svn184/lib64 \ --with-apr=/home/darxSVN_TEST/apr1/bin/apr-1-config \ --with-apr-util=/home/darxSVN_TEST/apr1/bin/apu-1-config \ --with-gnu-ld \ --with-serf make -j4 make install ldd /home/darxSVN_TEST/svn184/bin/svn | grep apr libaprutil-1.so.0 => /home/darxSVN_TEST/apr1/lib64/libaprutil-1.so.0 (0x00007f5cdec92000) libapr-1.so.0 => /home/darxSVN_TEST/apr1/lib64/libapr-1.so.0 (0x00007f5cde83b000) /home/darxSVN_TEST/apr1/bin/apr-1-config --version 1.4.8 /home/darxSVN_TEST/apr1/bin/apr-1-config --cppflags --cflags --ldflags --libs -DLINUX -D_REENTRANT -D_GNU_SOURCE -pthread -luuid -lrt -lcrypt -lpthread -ldl /home/darxSVN_TEST/svn184/bin/svn --version --verbose svn, version 1.8.4 (r1534716) compiled Nov 2 2013, 12:31:46 on x86_64-unknown-linux-gnu Copyright (C) 2013 The Apache Software Foundation. This software consists of contributions made by many people; see the NOTICE file for more information. Subversion is open source software, see http://subversion.apache.org/ The following repository access (RA) modules are available: * ra_svn : Module for accessing a repository using the svn network protocol. - with Cyrus SASL authentication - handles 'svn' scheme * ra_local : Module for accessing a repository on local disk. - handles 'file' scheme * ra_serf : Module for accessing a repository via WebDAV protocol using serf. - using serf 1.3.2 - handles 'http' scheme - handles 'https' scheme System information: * running on x86_64-unknown-linux-gnu - openSUSE 12 (Dartmout) [Linux 3.7.10-1.16-xen] * linked dependencies: - APR 1.4.8 (compiled with 1.4.8) - APR-Util 1.5.2 (compiled with 1.5.2) - SQLite 3.8.1 (compiled with 3.8.1) with resolvers set to IPv4 cat /etc/resolv.conf nameserver 74.207.241.5 nameserver 74.207.242.5 options rotate checking hosts dig A www.nlnetlabs.nl +short 213.154.224.1 dig AAAA www.nlnetlabs.nl +short 2001:7b8:206:1::1 no problems with resolver. testing SVN co's S="www.nlnetlabs.nl" T="svn/nsd/tags/NSD_4_0_0_REL/tpkg/manual" OK rm -rf test /usr/bin/svn co http://$S/$T test ... Checked out revision 4089. OK rm -rf test /usr/bin/svn co http://213.154.224.1/$T test ... Checked out revision 4089. OK rm -rf test /usr/bin/svn co http://[2001:7b8:206:1::1]/$T test ... Checked out revision 4089. OK rm -rf test /home/darxSVN_TEST/svn184/bin/svn co http://$S/$T test ... Checked out revision 4089. OK rm -rf test /home/darxSVN_TEST/svn184/bin/svn co http://213.154.224.1/$T test ... Checked out revision 4089. OK rm -rf test /home/darxSVN_TEST/svn184/bin/svn co http://[2001:7b8:206:1::1]/$T test ... Checked out revision 4089. switching to resolvers set to IPv6 cat /etc/resolv.conf nameserver 2600:3c01::2 nameserver 2600:3c01::3 options rotate checking hosts dig A www.nlnetlabs.nl +short 213.154.224.1 dig AAAA www.nlnetlabs.nl +short 2001:7b8:206:1::1 no problems with resolver repeat testing SVN co's rm -rf test FAIL /usr/bin/svn co http://$S/$T test svn: E670002: Unable to connect to a repository at URL 'http://www.nlnetlabs.nl/svn/nsd/tags/NSD_4_0_0_REL/tpkg/manual' svn: E670002: Name or service not known OK rm -rf test /usr/bin/svn co http://213.154.224.1/$T test ... Checked out revision 4089. OK rm -rf test /usr/bin/svn co http://[2001:7b8:206:1::1]/$T test ... Checked out revision 4089. FAIL rm -rf test /home/darxSVN_TEST/svn184/bin/svn co http://$S/$T test svn: E670002: Unable to connect to a repository at URL 'http://www.nlnetlabs.nl/svn/nsd/tags/NSD_4_0_0_REL/tpkg/manual' svn: E670002: Name or service not known OK rm -rf test /home/darxSVN_TEST/svn184/bin/svn co http://213.154.224.1/$T test ... Checked out revision 4089. OK rm -rf test /home/darxSVN_TEST/svn184/bin/svn co http://[2001:7b8:206:1::1]/$T test ... Checked out revision 4089.