账号密码登录
微信安全登录
微信扫描二维码登录

登录后绑定QQ、微信即可实现信息互通

手机验证码登录
找回密码返回
邮箱找回 手机找回
注册账号返回
其他登录方式
分享
  • 收藏
    X
    django+uwsgi上传大文件失败
    33
    0

    uwsgi的log是这样的

    [uwsgi-body-read] Error reading 49152 bytes. Content-Length: 14582139 consumed: 6373376 left: 8208763 message: Client closed connection
    Internal Server Error: /temrule/uploadocrpdf/
    Traceback (most recent call last):
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/request.py", line 331, in read
        return self._stream.read(*args, **kwargs)
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 53, in read
        result = self.buffer + self._read_limited(size - len(self.buffer))
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 41, in _read_limited
        result = self.stream.read(size)
    OSError: error during read(65536) on wsgi.input
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/exception.py", line 41, in inner
        response = get_response(request)
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/base.py", line 187, in _get_response
        response = self.process_exception_by_middleware(e, request)
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/base.py", line 185, in _get_response
        response = wrapped_callback(request, *callback_args, **callback_kwargs)
      File "/home/serverend/comengine/templaterule/views/ocrpdf_views.py", line 51, in upload_ocr_pdf
        sessionid = request.POST.get('sessionid')
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 126, in _get_post
        self._load_post_and_files()
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/request.py", line 299, in _load_post_and_files
        self._post, self._files = self.parse_file_upload(self.META, data)
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/request.py", line 258, in parse_file_upload
        return parser.parse()
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/multipartparser.py", line 238, in parse
        for chunk in field_stream:
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/multipartparser.py", line 384, in __next__
        output = next(self._producer)
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/multipartparser.py", line 517, in __next__
        for bytes in stream:
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/multipartparser.py", line 384, in __next__
        output = next(self._producer)
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/multipartparser.py", line 448, in __next__
        data = self.flo.read(self.chunk_size)
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/http/request.py", line 333, in read
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 53, in read
        result = self.buffer + self._read_limited(size - len(self.buffer))
      File "/home/yangtao/miniconda3/envs/compoengine/lib/python3.6/site-packages/django/core/handlers/wsgi.py", line 41, in _read_limited
        result = self.stream.read(size)
    django.http.request.UnreadablePostError: error during read(65536) on wsgi.input
    Fri Jan  5 19:25:45 2018 - SIGPIPE: writing to a closed pipe/socket/fd (probably the client disconnected) on request /temrule/uploadocrpdf/ (ip 192.168.10.3) !!!
    Fri Jan  5 19:25:45 2018 - uwsgi_response_write_body_do(): Broken pipe [core/writer.c line 331] during POST /temrule/uploadocrpdf/ (192.168.10.3)
    OSError: write error
    

    这是怎么回事?怎么解决?

    0
    打赏
    收藏
    点击回答
        全部回答
    • 0
    更多回答
    扫一扫访问手机版

    回答动态

    师傅被妖怪抓走了:发布了悬赏问题火爆全网的“元宇宙”到底是什么?预计能赚取 1积分收益
    酒后略带风情:发布了悬赏问题Android内存中Graphics与Code占用过高预计能赚取 10积分收益
    扛起拖把扫天下:发布了悬赏问题typescript如何导出接口配置?求解,谢谢!预计能赚取 10积分收益
    发布了悬赏问题Vue 如何改变返回页面的路径?如让B页面只能返回到A页面.预计能赚取 11积分收益
    发布了悬赏问题vue H5移动端;底部bottom固定定位,安卓弹起键盘导致页面变形如何解决?预计能赚取 10积分收益
    发布了悬赏问题请问为什么tomcat8.5 GET请求中文正常,POST请求还需要设置UTF-8.预计能赚取 10积分收益
    发布了悬赏问题vue2.5+ts创建以及引入jq的方法预计能赚取 11积分收益
    情场浪女:发布了悬赏问题import ggplot时报错module 'pandas' has no attribute 'tslib'预计能赚取 10积分收益
    见心书画许老师18753375161:发布了悬赏问题echarts3 legend禁止点击事件,允许悬浮事件预计能赚取 11积分收益
    aa_92cb0bd09f:发布了悬赏问题codewar上的一个问题预计能赚取 11积分收益