Forum: NGINX echo-nginx-module and HTTP2

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Fd3206619c7f3ae986e24c03fa1ae0a7?d=identicon&s=25 A. Schulze (Guest)
on 2016-01-28 10:45
(Received via mailing list)
Hello,

The echo module (https://github.com/openresty/echo-nginx-module / v0.58)
produce segfaults while accessing the following location:

    # echo back the client request
    location /echoback {
      echo_duplicate 1 $echo_client_request_headers;
      echo "\r";

      echo_read_request_body;

      echo_request_body;
    }

that happen only if http2 is enabled (usually at https servers).

...
worker process 20658 exited on signal 11

Andreas
37f3ea777f96500b332a1a89d6027897?d=identicon&s=25 Yichun Zhang (agentzh) (Guest)
on 2016-01-28 20:01
(Received via mailing list)
Hello!

On Thu, Jan 28, 2016 at 1:45 AM, A. Schulze wrote:
>      echo_request_body;
>    }
>
> that happen only if http2 is enabled (usually at https servers).

Yeah, the ngx_echo module does not support the HTTP/2 mode yet (as the
maintainer, I've never tested it anyway). Patches welcome and
volunteers welcome :)

Best regards,
-agentzh
Fd3206619c7f3ae986e24c03fa1ae0a7?d=identicon&s=25 A. Schulze (Guest)
on 2016-01-29 08:20
(Received via mailing list)
Yichun Zhang (agentzh):

> Yeah, the ngx_echo module does not support the HTTP/2 mode yet (as the
> maintainer, I've never tested it anyway). Patches welcome and
> volunteers welcome :)

thanks,

I could not support with patches but would do some beta testing.

Just to have ask:
disabling http2 for a location is not possible, isn't it?

Andreas
37f3ea777f96500b332a1a89d6027897?d=identicon&s=25 Yichun Zhang (agentzh) (Guest)
on 2016-01-29 21:35
(Received via mailing list)
Hello!

On Thu, Jan 28, 2016 at 11:19 PM, A. Schulze wrote:
> I could not support with patches but would do some beta testing.
>

Thanks.

> Just to have ask:
> disabling http2 for a location is not possible, isn't it?
>

Nope.

Regards,
-agentzh
2fd0c3f17efded066208e74d8e7f307e?d=identicon&s=25 Kurt Cancemi (Guest)
on 2016-01-30 05:41
(Received via mailing list)
Hello,

I was doing some debugging and though I haven't found a fix. The problem
is
in the ngx_http_echo_client_request_headers_variable() function
c->buffer
is NULL when http v2 is used for some reason (internal to nginx).

--
Kurt Cancemi
https://www.x64architecture.com
37f3ea777f96500b332a1a89d6027897?d=identicon&s=25 Yichun Zhang (agentzh) (Guest)
on 2016-02-01 23:53
(Received via mailing list)
Hello!

On Fri, Jan 29, 2016 at 8:40 PM, Kurt Cancemi wrote:
> I was doing some debugging and though I haven't found a fix. The problem is
> in the ngx_http_echo_client_request_headers_variable() function c->buffer is
> NULL when http v2 is used for some reason (internal to nginx).
>

This is expected since the HTTP/2 mode of NGINX reads the request
header into a different place. We should branch the code accordingly.

Regards,
-agentzh
5f8a0c2454f126b500d245c7b721a30e?d=identicon&s=25 Prostagotr Housat (prostagotr)
on 2017-02-17 18:25
I also had the segfaults with the echo module.
After googling for a while I solved the issue following this nginx echo
module guide:
https://tutorials.technology/tutorials/31-how-to-i...
This topic is locked and can not be replied to.