美文网首页
一次线程下载卡死排查

一次线程下载卡死排查

作者: 小龙虾0o0 | 来源:发表于2019-12-15 11:28 被阅读0次

    线程下载nginx静态文件内容,写的逻辑是只有下载完毕才会退出,否则就无限重试,用的是requests 流下载,每个线程负责一个zip包的下载
    发现的问题是有的线程在下载过程中卡死

    1. 程序发现这个问题后,我在每一次调用线程去下载文件时,会将文件名标为线程名,并打印当前进程下所有线程信息,如下
    [<_MainThread(MainThread, started 140512161621824)>, 
    <Thread(Thread-1, started daemon 140511855638272)>, 
    <Thread(Thread-2, started daemon 140511847245568)>, 
    <Thread(Thread-3, started daemon 140511838852864)>, 
    <Thread(/media/disks/html_zip/us/_20190904234.zip, started 140511457306368)>, 
    <Thread(/media/disks/html_zip/us/_20190906004.zip, started 140511432128256)>, 
    <Thread(/media/disks/html_zip/us/_20190906005.zip, started 140511812888320)>]
    
    1. 使用gstack打印指定进程的执行堆栈,gstack会将进程下所有线程也打印出来,Log较长,只贴3条,Thread11 正常执行,Thread10/9为异常线程。如下:

    排查:发现异常线程的栈信息都卡在了 recv () from /lib64/libpthread.so.0 这的函数上,这是从socket缓冲区拿数据,我查看了本地下载进程的描述符状况,发现确实对应着正在下载的文件(包括了卡死的下载任务),然而服务端的nginx却没有占用卡死状态的socket描述符,这里就不知道怎么再排查下去。TODO

    解决方案:既然是卡死在接收数据上,那就设置一个超时参数,外层捕捉错误再断点续传

    Thread 11 (Thread 0x7fcb763dd700 (LWP 5256)):
    #0  0x00007fcb891646fd in read () from /lib64/libpthread.so.0
    #1  0x00000000005399fc in _Py_read (fd=fd@entry=7, buf=0x7fcb776157d0, count=count@entry=4) at Python/fileutils.c:1407
    #2  0x000000000053bb93 in os_read_impl (module=<optimized out>, length=4, fd=7) at ./Modules/posixmodule.c:8043
    #3  os_read (module=<optimized out>, args=<optimized out>, nargs=<optimized out>) at ./Modules/clinic/posixmodule.c.h:3625
    #4  0x0000000000463616 in _PyMethodDef_RawFastCallKeywords (kwnames=0x0, nargs=<optimized out>, args=<optimized out>, self=<optimized out>, method=0x8a3ea0 <posix_methods+2848>) at Objects/call.c:651
    #5  _PyCFunction_FastCallKeywords (func=func@entry=0x7fcb897221f8, args=<optimized out>, nargs=<optimized out>, kwnames=kwnames@entry=0x0) at Objects/call.c:730
    #6  0x00000000004fb790 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4568
    #7  _PyEval_EvalFrameDefault (f=f@entry=0x7fcb7a344d68, throwflag=throwflag@entry=0) at Python/ceval.c:3124
    #8  0x000000000050171f in PyEval_EvalFrameEx (throwflag=0, f=0x7fcb7a344d68) at Python/ceval.c:547
    #9  _PyEval_EvalCodeWithName (_co=0x7fcb77605540, globals=<optimized out>, locals=locals@entry=0x0, args=<optimized out>, argcount=argcount@entry=2, kwnames=0x0, kwargs=0x7fcb77700e98, kwcount=<optimized out>, kwstep=kwstep@entry=1, defs=defs@entry=0x7fcb77609d80, defcount=1, kwdefs=kwdefs@entry=0x0, closure=closure@entry=0x0, name=<optimized out>, qualname=qualname@entry=0x7fcb775fddb0) at Python/ceval.c:3930
    #10 0x000000000046338a in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7760cf28, stack=<optimized out>, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/call.c:433
    #11 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #12 _PyEval_EvalFrameDefault (f=f@entry=0x7fcb77700cf8, throwflag=throwflag@entry=0) at Python/ceval.c:3110
    #13 0x000000000050171f in PyEval_EvalFrameEx (throwflag=0, f=0x7fcb77700cf8) at Python/ceval.c:547
    #14 _PyEval_EvalCodeWithName (_co=0x7fcb77605660, globals=<optimized out>, locals=locals@entry=0x0, args=<optimized out>, argcount=argcount@entry=1, kwnames=0x0, kwargs=0x7fcb783fdc20, kwcount=<optimized out>, kwstep=kwstep@entry=1, defs=defs@entry=0x7fcb775fee60, defcount=1, kwdefs=kwdefs@entry=0x0, closure=closure@entry=0x0, name=<optimized out>, qualname=qualname@entry=0x7fcb775fded0) at Python/ceval.c:3930
    #15 0x000000000046338a in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb776110d0, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:433
    #16 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #17 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #18 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=1, globals=<optimized out>) at Objects/call.c:283
    #19 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7760cbf8, stack=<optimized out>, stack@entry=0x7fcb6c000f00, nargs=<optimized out>, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #20 0x00000000004f739f in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #21 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3124
    #22 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb775e6660, args=<optimized out>, args@entry=0x29ed078, nargs=nargs@entry=3, globals=globals@entry=0x7fcb7765ae10) at Objects/call.c:283
    #23 0x0000000000467c0a in _PyFunction_FastCallDict (kwargs=0x7fcb7761dc60, nargs=3, args=0x29ed078, func=0x7fcb775f5ae8) at Objects/call.c:322
    #24 PyObject_Call (callable=callable@entry=0x7fcb775f5ae8, args=args@entry=0x7fcb77618f78, kwargs=kwargs@entry=0x7fcb7761dc60) at Objects/call.c:226
    #25 0x00000000004f8e46 in do_call_core (kwdict=0x7fcb7761dc60, callargs=0x7fcb77618f78, func=0x7fcb775f5ae8) at Python/ceval.c:4645
    #26 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3191
    #27 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=1, globals=<optimized out>) at Objects/call.c:283
    #28 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb817fd400, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #29 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #30 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #31 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=1, globals=<optimized out>) at Objects/call.c:283
    #32 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb817fd620, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #33 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #34 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #35 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb817f06f0, args=<optimized out>, args@entry=0x7fcb763dcd90, nargs=nargs@entry=1, globals=<optimized out>) at Objects/call.c:283
    #36 0x000000000046613d in _PyFunction_FastCallDict (kwargs=0x0, nargs=1, args=0x7fcb763dcd90, func=0x7fcb817fd488) at Objects/call.c:322
    #37 _PyObject_FastCallDict (kwargs=0x0, nargs=1, args=0x7fcb763dcd90, callable=0x7fcb817fd488) at Objects/call.c:98
    #38 _PyObject_Call_Prepend (callable=0x7fcb817fd488, obj=<optimized out>, args=<optimized out>, kwargs=0x0) at Objects/call.c:904
    #39 0x0000000000467b25 in PyObject_Call (callable=0x7fcb7da2be88, args=<optimized out>, kwargs=0x0) at Objects/call.c:245
    #40 0x00000000005c14b3 in t_bootstrap (boot_raw=boot_raw@entry=0x7fcb77615738) at ./Modules/_threadmodule.c:994
    #41 0x00000000005b1af4 in pythread_wrapper (arg=<optimized out>) at Python/thread_pthread.h:174
    #42 0x00007fcb8915ddd5 in start_thread () from /lib64/libpthread.so.0
    #43 0x00007fcb8877dead in clone () from /lib64/libc.so.6
    
    
    Thread 10 (Thread 0x7fcb5f7fe700 (LWP 9437)):
    #0  0x00007fcb89164a8b in recv () from /lib64/libpthread.so.0
    #1  0x00007fcb811245df in sock_recv_impl (data=<synthetic pointer>, s=0x7fcb75b769a8) at /root/Python-3.7.3/Modules/socketmodule.c:3255
    #2  sock_call_ex (timeout=-1000000000, err=0x0, connect=0, data=<synthetic pointer>, sock_func=0x7fcb81120f88 <sock_recv_impl>, writing=0, s=0x7fcb75b769a8) at /root/Python-3.7.3/Modules/socketmodule.c:884
    #3  sock_call (data=<synthetic pointer>, func=0x7fcb81120f88 <sock_recv_impl>, writing=0, s=0x7fcb75b769a8) at /root/Python-3.7.3/Modules/socketmodule.c:936
    #4  sock_recv_guts (flags=0, len=8192, cbuf=0x7fcb4c001870 ")OF\313\021GYkdˋ\262\233'\261_\233\027\376\244Y\031\361O\352\350u\004d\361\351o\322\322\r\320\366[\264\023t\322\350\265ԽK\324\332͞/*UT\006@g\257\271\225\353\n\263\255\307\316^\037\373EcZ\364\001!\026\tr\275u\241p\210\257Ϸ#\362ɕk@\177-\277", s=0x7fcb75b769a8) at /root/Python-3.7.3/Modules/socketmodule.c:3287
    #5  sock_recv_into (s=0x7fcb75b769a8, args=<optimized out>, kwds=<optimized out>) at /root/Python-3.7.3/Modules/socketmodule.c:3382
    #6  0x00000000004642b4 in _PyMethodDef_RawFastCallKeywords (method=0x7fcb81332fc0 <sock_methods+384>, self=self@entry=0x7fcb75b769a8, args=args@entry=0x2b64ae8, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:690
    #7  0x000000000056da15 in _PyMethodDescr_FastCallKeywords (descrobj=descrobj@entry=0x7fcb810f2948, args=args@entry=0x2b64ae0, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/descrobject.c:288
    #8  0x00000000004fbdca in call_function (kwnames=0x0, oparg=2, pp_stack=<synthetic pointer>) at Python/ceval.c:4593
    #9  _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #10 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb817de420, args=<optimized out>, args@entry=0x7fcb5f7fc900, nargs=nargs@entry=2, globals=<optimized out>) at Objects/call.c:283
    #11 0x000000000046613d in _PyFunction_FastCallDict (kwargs=0x0, nargs=2, args=0x7fcb5f7fc900, func=0x7fcb810f4730) at Objects/call.c:322
    #12 _PyObject_FastCallDict (kwargs=0x0, nargs=2, args=0x7fcb5f7fc900, callable=0x7fcb810f4730) at Objects/call.c:98
    #13 _PyObject_Call_Prepend (callable=0x7fcb810f4730, obj=<optimized out>, args=<optimized out>, kwargs=0x0) at Objects/call.c:904
    #14 0x0000000000466a6e in _PyObject_FastCallDict (kwargs=0x0, nargs=<optimized out>, args=0x7fcb5f7fc9f0, callable=0x7fcb7da2bdc8) at Objects/call.c:125
    #15 object_vacall (callable=callable@entry=0x7fcb7da2bdc8, vargs=vargs@entry=0x7fcb5f7fca58) at Objects/call.c:1198
    #16 0x0000000000466ff3 in PyObject_CallMethodObjArgs (callable=0x7fcb7da2bdc8, name=<optimized out>) at Objects/call.c:1223
    #17 0x0000000000555111 in _bufferedreader_raw_read (len=8192, start=<optimized out>, self=0x7fcb75b215c8) at ./Modules/_io/bufferedio.c:1479
    #18 _bufferedreader_fill_buffer (self=self@entry=0x7fcb75b215c8) at ./Modules/_io/bufferedio.c:1511
    #19 0x00000000005560fc in _buffered_readinto_generic (buffer=<optimized out>, buffer=<optimized out>, readinto1=0 '\000', self=0x7fcb75b215c8) at ./Modules/_io/bufferedio.c:1016
    #20 _io__Buffered_readinto_impl (buffer=0x7fcb5f7fcbd0, self=0x7fcb75b215c8) at ./Modules/_io/bufferedio.c:1062
    #21 _io__Buffered_readinto (self=0x7fcb75b215c8, arg=<optimized out>) at ./Modules/_io/clinic/bufferedio.c.h:189
    #22 0x0000000000464130 in _PyMethodDef_RawFastCallKeywords (method=0x8ca360 <bufferedreader_methods+384>, self=self@entry=0x7fcb75b215c8, args=args@entry=0x2b6ee48, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:644
    #23 0x000000000056da15 in _PyMethodDescr_FastCallKeywords (descrobj=descrobj@entry=0x7fcb8971a3a8, args=args@entry=0x2b6ee40, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/descrobject.c:288
    #24 0x00000000004fbdca in call_function (kwnames=0x0, oparg=2, pp_stack=<synthetic pointer>) at Python/ceval.c:4593
    #25 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #26 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=2, globals=<optimized out>) at Objects/call.c:283
    #27 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7c832bf8, stack=<optimized out>, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #28 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #29 _PyEval_EvalFrameDefault (f=f@entry=0x2b58668, throwflag=throwflag@entry=0) at Python/ceval.c:3110
    #30 0x000000000050171f in PyEval_EvalFrameEx (throwflag=0, f=0x2b58668) at Python/ceval.c:547
    #31 _PyEval_EvalCodeWithName (_co=0x7fcb7c8f5f60, globals=<optimized out>, locals=locals@entry=0x0, args=<optimized out>, argcount=argcount@entry=2, kwnames=0x0, kwargs=0x2b6cac0, kwcount=<optimized out>, kwstep=kwstep@entry=1, defs=defs@entry=0x7fcb7c8fa958, defcount=1, kwdefs=kwdefs@entry=0x0, closure=closure@entry=0x0, name=<optimized out>, qualname=qualname@entry=0x7fcb81561150) at Python/ceval.c:3930
    #32 0x000000000046338a in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7c832b70, stack=<optimized out>, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/call.c:433
    #33 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #34 _PyEval_EvalFrameDefault (f=f@entry=0x2b6c908, throwflag=throwflag@entry=0) at Python/ceval.c:3110
    #35 0x000000000050171f in PyEval_EvalFrameEx (throwflag=0, f=0x2b6c908) at Python/ceval.c:547
    #36 _PyEval_EvalCodeWithName (_co=0x7fcb7c75a300, globals=<optimized out>, locals=locals@entry=0x0, args=<optimized out>, argcount=argcount@entry=1, kwnames=0x7fcb7c7c2420, kwargs=0x2b6d2c0, kwcount=<optimized out>, kwstep=kwstep@entry=1, defs=defs@entry=0x7fcb7c7b3408, defcount=3, kwdefs=kwdefs@entry=0x0, closure=closure@entry=0x0, name=<optimized out>, qualname=qualname@entry=0x7fcb7c7b3f60) at Python/ceval.c:3930
    #37 0x000000000046338a in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7c75bc80, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x7fcb7c7c2408) at Objects/call.c:433
    #38 0x00000000004f859f in call_function (kwnames=0x7fcb7c7c2408, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #39 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3139
    #40 0x000000000056e775 in gen_send_ex (closing=0, exc=0, arg=0x0, gen=0x7fcb75b69570) at Objects/genobject.c:221
    #41 gen_iternext (gen=0x7fcb75b69570) at Objects/genobject.c:542
    #42 0x00000000004f7926 in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:2809
    #43 0x000000000056e775 in gen_send_ex (closing=0, exc=0, arg=0x0, gen=0x7fcb75b69750) at Objects/genobject.c:221
    #44 gen_iternext (gen=0x7fcb75b69750) at Objects/genobject.c:542
    #45 0x00000000004f7926 in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:2809
    #46 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb7a378c90, args=<optimized out>, args@entry=0x288e2e8, nargs=nargs@entry=3, globals=globals@entry=0x7fcb7a36aab0) at Objects/call.c:283
    #47 0x0000000000467c0a in _PyFunction_FastCallDict (kwargs=0x7fcb75b2aa68, nargs=3, args=0x288e2e8, func=0x7fcb7a29f730) at Objects/call.c:322
    #48 PyObject_Call (callable=callable@entry=0x7fcb7a29f730, args=args@entry=0x7fcb75b84c18, kwargs=kwargs@entry=0x7fcb75b2aa68) at Objects/call.c:226
    #49 0x00000000004f8e46 in do_call_core (kwdict=0x7fcb75b2aa68, callargs=0x7fcb75b84c18, func=0x7fcb7a29f730) at Python/ceval.c:4645
    #50 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3191
    #51 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=1, globals=<optimized out>) at Objects/call.c:283
    #52 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb817fd400, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #53 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #54 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #55 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=1, globals=<optimized out>) at Objects/call.c:283
    #56 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb817fd620, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #57 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #58 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #59 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb817f06f0, args=<optimized out>, args@entry=0x7fcb5f7fdd90, nargs=nargs@entry=1, globals=<optimized out>) at Objects/call.c:283
    #60 0x000000000046613d in _PyFunction_FastCallDict (kwargs=0x0, nargs=1, args=0x7fcb5f7fdd90, func=0x7fcb817fd488) at Objects/call.c:322
    #61 _PyObject_FastCallDict (kwargs=0x0, nargs=1, args=0x7fcb5f7fdd90, callable=0x7fcb817fd488) at Objects/call.c:98
    #62 _PyObject_Call_Prepend (callable=0x7fcb817fd488, obj=<optimized out>, args=<optimized out>, kwargs=0x0) at Objects/call.c:904
    #63 0x0000000000467b25 in PyObject_Call (callable=0x7fcb75b471c8, args=<optimized out>, kwargs=0x0) at Objects/call.c:245
    #64 0x00000000005c14b3 in t_bootstrap (boot_raw=boot_raw@entry=0x7fcb7a35dc60) at ./Modules/_threadmodule.c:994
    #65 0x00000000005b1af4 in pythread_wrapper (arg=<optimized out>) at Python/thread_pthread.h:174
    #66 0x00007fcb8915ddd5 in start_thread () from /lib64/libpthread.so.0
    #67 0x00007fcb8877dead in clone () from /lib64/libc.so.6
    
    Thread 9 (Thread 0x7fcb5dffb700 (LWP 2227)):
    #0  0x00007fcb89164a8b in recv () from /lib64/libpthread.so.0
    #1  0x00007fcb811245df in sock_recv_impl (data=<synthetic pointer>, s=0x7fcb75b762e8) at /root/Python-3.7.3/Modules/socketmodule.c:3255
    #2  sock_call_ex (timeout=-1000000000, err=0x0, connect=0, data=<synthetic pointer>, sock_func=0x7fcb81120f88 <sock_recv_impl>, writing=0, s=0x7fcb75b762e8) at /root/Python-3.7.3/Modules/socketmodule.c:884
    #3  sock_call (data=<synthetic pointer>, func=0x7fcb81120f88 <sock_recv_impl>, writing=0, s=0x7fcb75b762e8) at /root/Python-3.7.3/Modules/socketmodule.c:936
    #4  sock_recv_guts (flags=0, len=8192, cbuf=0x7fcb60001840 "]\300\034\330V\250'\335x\375\351\002[\347m\224\r\306\343q6`\b\360,[", s=0x7fcb75b762e8) at /root/Python-3.7.3/Modules/socketmodule.c:3287
    #5  sock_recv_into (s=0x7fcb75b762e8, args=<optimized out>, kwds=<optimized out>) at /root/Python-3.7.3/Modules/socketmodule.c:3382
    #6  0x00000000004642b4 in _PyMethodDef_RawFastCallKeywords (method=0x7fcb81332fc0 <sock_methods+384>, self=self@entry=0x7fcb75b762e8, args=args@entry=0x7fcb75b9a9d8, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:690
    #7  0x000000000056da15 in _PyMethodDescr_FastCallKeywords (descrobj=descrobj@entry=0x7fcb810f2948, args=args@entry=0x7fcb75b9a9d0, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/descrobject.c:288
    #8  0x00000000004fbdca in call_function (kwnames=0x0, oparg=2, pp_stack=<synthetic pointer>) at Python/ceval.c:4593
    #9  _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #10 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb817de420, args=<optimized out>, args@entry=0x7fcb5dff9900, nargs=nargs@entry=2, globals=<optimized out>) at Objects/call.c:283
    #11 0x000000000046613d in _PyFunction_FastCallDict (kwargs=0x0, nargs=2, args=0x7fcb5dff9900, func=0x7fcb810f4730) at Objects/call.c:322
    #12 _PyObject_FastCallDict (kwargs=0x0, nargs=2, args=0x7fcb5dff9900, callable=0x7fcb810f4730) at Objects/call.c:98
    #13 _PyObject_Call_Prepend (callable=0x7fcb810f4730, obj=<optimized out>, args=<optimized out>, kwargs=0x0) at Objects/call.c:904
    #14 0x0000000000466a6e in _PyObject_FastCallDict (kwargs=0x0, nargs=<optimized out>, args=0x7fcb5dff99f0, callable=0x7fcb75b3ac08) at Objects/call.c:125
    #15 object_vacall (callable=callable@entry=0x7fcb75b3ac08, vargs=vargs@entry=0x7fcb5dff9a58) at Objects/call.c:1198
    #16 0x0000000000466ff3 in PyObject_CallMethodObjArgs (callable=0x7fcb75b3ac08, name=<optimized out>) at Objects/call.c:1223
    #17 0x0000000000555111 in _bufferedreader_raw_read (len=8192, start=<optimized out>, self=0x7fcb75b21468) at ./Modules/_io/bufferedio.c:1479
    #18 _bufferedreader_fill_buffer (self=self@entry=0x7fcb75b21468) at ./Modules/_io/bufferedio.c:1511
    #19 0x00000000005560fc in _buffered_readinto_generic (buffer=<optimized out>, buffer=<optimized out>, readinto1=0 '\000', self=0x7fcb75b21468) at ./Modules/_io/bufferedio.c:1016
    #20 _io__Buffered_readinto_impl (buffer=0x7fcb5dff9bd0, self=0x7fcb75b21468) at ./Modules/_io/bufferedio.c:1062
    #21 _io__Buffered_readinto (self=0x7fcb75b21468, arg=<optimized out>) at ./Modules/_io/clinic/bufferedio.c.h:189
    #22 0x0000000000464130 in _PyMethodDef_RawFastCallKeywords (method=0x8ca360 <bufferedreader_methods+384>, self=self@entry=0x7fcb75b21468, args=args@entry=0x2b73cb8, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:644
    #23 0x000000000056da15 in _PyMethodDescr_FastCallKeywords (descrobj=descrobj@entry=0x7fcb8971a3a8, args=args@entry=0x2b73cb0, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/descrobject.c:288
    #24 0x00000000004fbdca in call_function (kwnames=0x0, oparg=2, pp_stack=<synthetic pointer>) at Python/ceval.c:4593
    #25 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #26 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=2, globals=<optimized out>) at Objects/call.c:283
    #27 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7c832bf8, stack=<optimized out>, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #28 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #29 _PyEval_EvalFrameDefault (f=f@entry=0x2b6fbd8, throwflag=throwflag@entry=0) at Python/ceval.c:3110
    #30 0x000000000050171f in PyEval_EvalFrameEx (throwflag=0, f=0x2b6fbd8) at Python/ceval.c:547
    #31 _PyEval_EvalCodeWithName (_co=0x7fcb7c8f5f60, globals=<optimized out>, locals=locals@entry=0x0, args=<optimized out>, argcount=argcount@entry=2, kwnames=0x0, kwargs=0x2b78b30, kwcount=<optimized out>, kwstep=kwstep@entry=1, defs=defs@entry=0x7fcb7c8fa958, defcount=1, kwdefs=kwdefs@entry=0x0, closure=closure@entry=0x0, name=<optimized out>, qualname=qualname@entry=0x7fcb81561150) at Python/ceval.c:3930
    #32 0x000000000046338a in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7c832b70, stack=<optimized out>, nargs=nargs@entry=2, kwnames=kwnames@entry=0x0) at Objects/call.c:433
    #33 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #34 _PyEval_EvalFrameDefault (f=f@entry=0x2b78978, throwflag=throwflag@entry=0) at Python/ceval.c:3110
    #35 0x000000000050171f in PyEval_EvalFrameEx (throwflag=0, f=0x2b78978) at Python/ceval.c:547
    #36 _PyEval_EvalCodeWithName (_co=0x7fcb7c75a300, globals=<optimized out>, locals=locals@entry=0x0, args=<optimized out>, argcount=argcount@entry=1, kwnames=0x7fcb7c7c2420, kwargs=0x7fcb44004f50, kwcount=<optimized out>, kwstep=kwstep@entry=1, defs=defs@entry=0x7fcb7c7b3408, defcount=3, kwdefs=kwdefs@entry=0x0, closure=closure@entry=0x0, name=<optimized out>, qualname=qualname@entry=0x7fcb7c7b3f60) at Python/ceval.c:3930
    #37 0x000000000046338a in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb7c75bc80, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x7fcb7c7c2408) at Objects/call.c:433
    #38 0x00000000004f859f in call_function (kwnames=0x7fcb7c7c2408, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #39 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3139
    #40 0x000000000056e775 in gen_send_ex (closing=0, exc=0, arg=0x0, gen=0x7fcb75b698b8) at Objects/genobject.c:221
    #41 gen_iternext (gen=0x7fcb75b698b8) at Objects/genobject.c:542
    #42 0x00000000004f7926 in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:2809
    #43 0x000000000056e775 in gen_send_ex (closing=0, exc=0, arg=0x0, gen=0x7fcb75b69f48) at Objects/genobject.c:221
    #44 gen_iternext (gen=0x7fcb75b69f48) at Objects/genobject.c:542
    #45 0x00000000004f7926 in _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:2809
    #46 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb7a378c90, args=<optimized out>, args@entry=0x2b71ec8, nargs=nargs@entry=3, globals=globals@entry=0x7fcb7a36aab0) at Objects/call.c:283
    #47 0x0000000000467c0a in _PyFunction_FastCallDict (kwargs=0x7fcb75b34870, nargs=3, args=0x2b71ec8, func=0x7fcb7a29f730) at Objects/call.c:322
    #48 PyObject_Call (callable=callable@entry=0x7fcb7a29f730, args=args@entry=0x7fcb742dcee8, kwargs=kwargs@entry=0x7fcb75b34870) at Objects/call.c:226
    #49 0x00000000004f8e46 in do_call_core (kwdict=0x7fcb75b34870, callargs=0x7fcb742dcee8, func=0x7fcb7a29f730) at Python/ceval.c:4645
    #50 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3191
    #51 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=1, globals=<optimized out>) at Objects/call.c:283
    #52 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb817fd400, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #53 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #54 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #55 0x0000000000462d3a in function_code_fastcall (co=<optimized out>, args=<optimized out>, nargs=1, globals=<optimized out>) at Objects/call.c:283
    #56 0x0000000000463318 in _PyFunction_FastCallKeywords (func=func@entry=0x7fcb817fd620, stack=<optimized out>, nargs=nargs@entry=1, kwnames=kwnames@entry=0x0) at Objects/call.c:415
    #57 0x00000000004f76c7 in call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetic pointer>) at Python/ceval.c:4616
    #58 _PyEval_EvalFrameDefault (f=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:3110
    #59 0x0000000000462d3a in function_code_fastcall (co=co@entry=0x7fcb817f06f0, args=<optimized out>, args@entry=0x7fcb5dffad90, nargs=nargs@entry=1, globals=<optimized out>) at Objects/call.c:283
    #60 0x000000000046613d in _PyFunction_FastCallDict (kwargs=0x0, nargs=1, args=0x7fcb5dffad90, func=0x7fcb817fd488) at Objects/call.c:322
    #61 _PyObject_FastCallDict (kwargs=0x0, nargs=1, args=0x7fcb5dffad90, callable=0x7fcb817fd488) at Objects/call.c:98
    #62 _PyObject_Call_Prepend (callable=0x7fcb817fd488, obj=<optimized out>, args=<optimized out>, kwargs=0x0) at Objects/call.c:904
    #63 0x0000000000467b25 in PyObject_Call (callable=0x7fcb7771e708, args=<optimized out>, kwargs=0x0) at Objects/call.c:245
    #64 0x00000000005c14b3 in t_bootstrap (boot_raw=boot_raw@entry=0x7fcb75bdc738) at ./Modules/_threadmodule.c:994
    #65 0x00000000005b1af4 in pythread_wrapper (arg=<optimized out>) at Python/thread_pthread.h:174
    #66 0x00007fcb8915ddd5 in start_thread () from /lib64/libpthread.so.0
    #67 0x00007fcb8877dead in clone () from /lib64/libc.so.6
    

    相关文章

      网友评论

          本文标题:一次线程下载卡死排查

          本文链接:https://www.haomeiwen.com/subject/oosbyctx.html