Welcome! Log In Create A New Profile

Advanced

Re: proxy_pass behavior

Jim Popovitch
March 27, 2014 01:52PM
On Thu, Mar 27, 2014 at 1:27 PM, Maxim Dounin <mdounin@mdounin.ru> wrote:
> Hello!
>
> On Thu, Mar 27, 2014 at 01:12:18PM -0400, Jim Popovitch wrote:
>
>> On Thu, Mar 27, 2014 at 12:59 PM, Maxim Dounin <mdounin@mdounin.ru> wrote:
>> > Hello!
>> >
>> > On Thu, Mar 27, 2014 at 12:29:03PM -0400, Jim Popovitch wrote:
>> >
>> >> Should proxy_pass retry ipv4 if ipv6 fails? Currently (1.5.12), it
>> >> does not, and there is no way to force proxy_pass to always use ipv4.
>> >
>> > In no particular order:
>> >
>> > - The proxy_next_upstream is expected to retry by default.
>>
>> Yes, that works if the host name has 2 or more A OR 2 or more AAAA
>> records. proxy_next_upstream does not appear to transition to the
>> next protocol (i.e. from ipv4 to ipv6)
>
> It doesn't care about address family. As long as connect() to
> one address fails, it will try next one.

I will have to do some more tests, but so far 1.5.12 (debian wheezy)
does not appear to try the next one if the next one is a different
protocol family.

>> > - There _is_ a way to force proxy_pass to always use ipv4 - you
>> > should configure your system accordingly, and
>> > getaddrinfo(AI_ADDRCONFIG) as used by nginx will do the right
>> > thing. E.g., on Linux net.ipv6.conf.all.disable_ipv6 can be set
>> > to disable use of ipv6.
>>
>> :-) That's unacceptable!! :-) I don't want people to disable ipv6,
>> I want proxy_pass to use ipv6 and upon failure use ipv4. ;-)
>
> It was you who claimed that "there is no way to force proxy_pass
> to always use ipv4". There is.

What I was trying to claim was that there is no way to run nginx on
ipv4 and ipv6 yet force proxy_pass to use only ipv4. Of course you
can proxy bind to a v4 interface, but that doesn't scale with syncing
configs to multiple servers. Maybe it's time for a proxy_protocol
variable.....

-Jim P.

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

proxy_pass behavior

Jim Popovitch 1003 March 27, 2014 12:30PM

Re: proxy_pass behavior

Maxim Dounin 456 March 27, 2014 01:00PM

Re: proxy_pass behavior

Jim Popovitch 370 March 27, 2014 01:14PM

Re: proxy_pass behavior

Maxim Dounin 365 March 27, 2014 01:28PM

Re: proxy_pass behavior

Jim Popovitch 2371 March 27, 2014 01:52PM

Re: proxy_pass behavior

Jim Popovitch 725 March 27, 2014 08:20PM

Re: proxy_pass behavior

Jim Popovitch 603 March 28, 2014 01:58PM

Re: proxy_pass behavior

Maxim Dounin 522 March 28, 2014 02:38PM

Re: proxy_pass behavior

Jim Popovitch 859 March 28, 2014 02:42PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 246
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready