IPv4 & IPv6
B.R.
reallfqq-nginx at yahoo.fr
Sat Apr 6 00:02:11 UTC 2013
I have indeed several virtual servers.
I have a specific one which serves different content whether a client
connects in HTTP or HTTPS (basically the HTTP content provides directions
for the HTTPS setup).
I also have one virtual server which I want listening on IPv4 only, not
IPv6.
That's why I prefer managing the listen directives in virtual servers
rather than in the 'http' directive block.
Is there no other mean than using global 'listen' directives?
---
*B. R.*
On Fri, Apr 5, 2013 at 6:21 PM, Maxim Dounin <mdounin at mdounin.ru> wrote:
> Hello!
>
> On Fri, Apr 05, 2013 at 06:07:23PM -0400, B.R. wrote:
>
> > Hello,
> >
> > @Maxim
> > I tried the duplicate configuration entries:
> > listen 80;
> > listen [::]:80 ipv6only=on;
> >
> > I has the following error:
> > nginx: [emerg] duplicate listen options for [::]:80 in
> > /etc/nginx/conf.d/***.conf:3
>
> If you have multiple virtual server{}s with the same listening
> sockets used, you have to specify listening options in a single listen
> directive only.
>
> That is, add "ipv6only=on" to a listen directive in first/default
> server in your configuration. This will do the trick.
>
> --
> Maxim Dounin
> http://nginx.org/en/donation.html
>
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20130405/34a4456a/attachment.html>
More information about the nginx
mailing list