You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by zwoop <gi...@git.apache.org> on 2017/02/02 17:06:54 UTC

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

GitHub user zwoop opened an issue:

    https://github.com/apache/trafficserver/issues/1412

    Assertion in HttpSM::tunnel_handler_post

    I think we've seen this before, but filing this again to make sure I don't lose the info:
    
    ```
    (gdb) bt
    #0  0x00007ffff4fed1d7 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
    #1  0x00007ffff4fee8c8 in __GI_abort () at abort.c:90
    #2  0x00007ffff7bb89c8 in ink_abort (message_format=0x7ffff7bca590 "%s:%d: failed assertion `%s`") at ink_error.cc:99
    #3  0x00007ffff7bb609e in _ink_assert (expression=0x800058 "(event == VC_EVENT_WRITE_COMPLETE) || (event == VC_EVENT_EOS)", file=0x7fe78c "HttpSM.cc", line=2763) at ink_assert.cc:37
    #4  0x00000000005f58cd in HttpSM::tunnel_handler_post (this=0x2aaabfcbe8f0, event=105, data=0x2aaabf009620) at HttpSM.cc:2763
    #5  0x00000000005f534b in HttpSM::main_handler (this=0x2aaabfcbe8f0, event=105, data=0x2aaabf009620) at HttpSM.cc:2665
    #6  0x000000000051a5c8 in Continuation::handleEvent (this=0x2aaabfcbe8f0, event=105, data=0x2aaabf009620) at /usr/local/src/trafficserver/iocore/eventsystem/I_Continuation.h:153
    #7  0x00000000007a8235 in write_signal_and_update (event=105, vc=0x2aaabf009480) at UnixNetVConnection.cc:176
    #8  0x00000000007ac11a in UnixNetVConnection::mainEvent (this=0x2aaabf009480, event=1, e=0x2aaaab5feb10) at UnixNetVConnection.cc:1289
    #9  0x000000000051a5c8 in Continuation::handleEvent (this=0x2aaabf009480, event=1, data=0x2aaaab5feb10) at /usr/local/src/trafficserver/iocore/eventsystem/I_Continuation.h:153
    #10 0x00000000007a10b6 in NetHandler::_close_vc (this=0x7ffff2409e50, vc=0x2aaabf009480, now=1486031338941225970, handle_event=@0x2aaaab5fec28: 0, closed=@0x2aaaab5fec2c: 0, total_idle_time=@0x2aaaab5fec24: 0, total_idle_count=@0x2aaaab5fec20: 0) at UnixNet.cc:679
    #11 0x00000000007a09a6 in NetHandler::manage_active_queue (this=0x7ffff2409e50, ignore_queue_size=true) at UnixNet.cc:588
    #12 0x00000000007a1cbb in InactivityCop::check_inactivity (this=0x7ffff3ecd100, event=2, e=0x2aaaabc05a00) at UnixNet.cc:94
    #13 0x000000000051a5c8 in Continuation::handleEvent (this=0x7ffff3ecd100, event=2, data=0x2aaaabc05a00) at /usr/local/src/trafficserver/iocore/eventsystem/I_Continuation.h:153
    #14 0x00000000007cc28c in EThread::process_event (this=0x7ffff2406000, e=0x2aaaabc05a00, calling_code=2) at UnixEThread.cc:143
    #15 0x00000000007cc6c7 in EThread::execute (this=0x7ffff2406000) at UnixEThread.cc:225
    #16 0x00000000007cb890 in spawn_thread_internal (a=0x7ffff3ec9040) at Thread.cc:84
    #17 0x00007ffff5a9ddc5 in start_thread (arg=0x2aaaab5ff700) at pthread_create.c:308
    #18 0x00007ffff50af73d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:113
    (gdb) frame 4
    #4  0x00000000005f58cd in HttpSM::tunnel_handler_post (this=0x2aaabfcbe8f0, event=105, data=0x2aaabf009620) at HttpSM.cc:2763
    2763	      ink_assert((event == VC_EVENT_WRITE_COMPLETE) || (event == VC_EVENT_EOS));
    (gdb) print event
    $1 = 105
    ```

----

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by oknet <gi...@git.apache.org>.
Github user oknet commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    @zwoop can u show me the HttpSM.history ?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by zwoop <gi...@git.apache.org>.
Github user zwoop commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    We're still seeing this on Docs, with the current 7.1.x and all the backports.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by oknet <gi...@git.apache.org>.
Github user oknet commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    Can you show me the netvc_context of the UnixNetVConnection ? in order to identify the side of it (client vc or server vc ?)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by bryancall <gi...@git.apache.org>.
Github user bryancall commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    The event is VC_EVENT_INACTIVITY_TIMEOUT (value 105) when it asserts.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by oknet <gi...@git.apache.org>.
Github user oknet commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    PR#1583 merged to fix the issue.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by zwoop <gi...@git.apache.org>.
Github user zwoop commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    @oknet Did any of your commits address this issue?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by oknet <gi...@git.apache.org>.
Github user oknet commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    Maybe I found the reason:
    
    ```
    3480 int
    3481 HttpSM::tunnel_handler_post_ua(int event, HttpTunnelProducer *p)
    3482 {
    3483   STATE_ENTER(&HttpSM::tunnel_handler_post_ua, event);
    3484   client_request_body_bytes = p->init_bytes_done + p->bytes_read;
    3485   int64_t alloc_index, nbytes;
    3486   IOBufferReader *buf_start;
    3487 
    3488   switch (event) {
    3489   case VC_EVENT_INACTIVITY_TIMEOUT:
    3490   case VC_EVENT_ACTIVE_TIMEOUT:
    ...
    3520       p->vc->do_io_write(this, nbytes, buf_start);
    3521       p->vc->do_io_shutdown(IO_SHUTDOWN_READ);
    3522       return 0;   // ----> we do not reset vc's timeout
    3523     }
    ```
    
    InactivityCop will callback again in the next second and the default httpsm handler is tunnel_handler_post().
    
    I think we should handle TIMEOUT event in tunnel_handler_post() since the timeout event get from ua_session.
    
    I will have a details analysis on it and create a PR to fix this issue.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by oknet <gi...@git.apache.org>.
Github user oknet commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    I found a bug related to this issue:
    
    HttpSM::state_request_wait_for_transform_read could receive the VC_EVENT_EOS, VC_EVENT_ERROR from TransformTerminus::handle_event and transfer these 2 events to HttpSM::tunnel_handler_post.
    
    but the p->handler_state is not (may be) set to HTTP_SM_POST_UA_FAIL.
    
    I will create a pr later.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by zwoop <gi...@git.apache.org>.
Github user zwoop commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    I'll see if I can get a core out of this again, for some reason, the box isn't producing core files :/


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by oknet <gi...@git.apache.org>.
Github user oknet commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    and HttpSM::history is needed.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] trafficserver issue #1412: Assertion in HttpSM::tunnel_handler_post

Posted by oknet <gi...@git.apache.org>.
Github user oknet commented on the issue:

    https://github.com/apache/trafficserver/issues/1412
  
    @zwoop Could you have a look on PR #1583 ? I think it is useful for this issue. But I still need your core file to confirm it.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---