[uwsgi-body-read] Error reading 65536 bytes. Content-Length: 560903 consumed: 0 left: 560903 message
使用uwsgi报以上错误,原因是上传文件是,文件稍大,首先上传时间长会引起timeout,然后上传文件需要保存到uwsgi的缓冲区,缓冲区超大小,解决方法是设置两个参数.
1.socket-timeout
上传文件时接收文件的超时时间,也就是说如果你设置socket-timeout为10s, 而10s到了文件还没有上传完,就会timeout的错.
socket-timeout
argument: required_argument
shortcut: -z
parser: uwsgi_opt_set_int
help: set internal sockets timeout
2.post-buffering
argument: required_argument
parser: uwsgi_opt_set_64bit
help: enable post buffering
参数解释:
enable http body buffering. uWSGI will save to disk all HTTP body bigger than the limit specified
post-buffering = 8192
will save to disk all the HTTP body bigger than 8K. This option is required for Rack applications as they require a rewindable input stream.
3.post-buffering-bufsize
argument: required_argument
parser: uwsgi_opt_set_64bit
help: set buffer size for read() in post buffering mode
参数解释:
set the internal buffer size during post buffering (this is the memory allocated to read chunks of the socket stream)
post-buffering-bufsize 65536
will allocate 64k as the buffer for socket recv(). For a 128k body two cycle/syscall will be used.
This is a very advanced option you will probably never need to touch
Refs:
1.http://simple-is-better.com/news/301
2.http://pythonic.zoomquiet.io/data/20110523113355/index.html
3.https://github.com/unbit/uwsgi/issues/363
[uwsgi-body-read] Error reading 65536 bytes. Content-Length: 560903 consumed: 0 left: 560903 message相关推荐
- spotlight soo5072:there was an error reading the tnsnames.ora
我使用spotlight的软件版本是spotlight 4.0.468,可是说版本比较老了.测试的数据库为LINUX AS4.0下10G:红旗LINUX下10G和WINDOWS下10G. 如果将服务器 ...
- vss error reading from file 解决方法
vss error reading from file 解决方法 参考文章: (1)vss error reading from file 解决方法 (2)https://www.cnblogs.co ...
- InnoDB: Error: log file .\ib_logfile0 is of different size 0 10485760 bytes
启动WAMP Server的时候报例如以下的错误: 140618 23:12:32 [Note] Plugin 'FEDERATED' is disabled. 140618 23:12:32 Inn ...
- The maximum string content length quota (8192) has been exceeded while reading XML data
原文: The maximum string content length quota (8192) has been exceeded while reading XML data 问题场景:在我们 ...
- 成功解决CondaError: Error reading file, file should be a text file containing packages conda create --he
成功解决CondaError: Error reading file, file should be a text file containing packages conda create --he ...
- ERROR manager.SqlManager: Error reading from database: java.sql.SQLException: Streaming result set
问题 在使用sqoop导入数据时,报如下错误: ERROR manager.SqlManager: Error reading from database: java.sql.SQLException ...
- IllegalStateException: Error reading delta file hdfs://xxx/spark/xx/state/0/11/1.delta
1. 背景 执行执行spark structured sql程序报错 19/08/26 15:17:15 WARN scheduler.TaskSetManager: Lost task 11.0 i ...
- Mac解压Linux平台tar包报错:tar: Error reading Truncated input file
1.报错:tar: Error reading Truncated input fileMac使用tar命令解压Linux平台tar包报错,需要安装gnu-tar来解压. 2.解决 # brew in ...
- 运行tomcat 时报错,提示无法找到相关的jar包 Publishing failed with multiple errors Error reading file
1.问题描述:运行tomcat 时报错,提示无法找到相关的jar包,如下 Publishing failed with multiple errors Error reading file C:\Us ...
- SparkOutOfMemoryError: Unable to acquire 65536 bytes of memory, got 0
Caused by: org.apache.spark.memory.SparkOutOfMemoryError: Unable to acquire 65536 bytes of memory, g ...
最新文章
- Zookeeper工作原理
- 智能车竞赛技术报告 | 智能车视觉 - 中南林业科技大学 - 弃车人队
- cytoscape使用方法_7种方法 ,订制你的专属venn图!-代谢组学/蛋白组学研究
- .net html转为pdf,.NET使用DinkToPdf将HTML转成PDF的示例代码
- Kotlin——初级篇(二):变量、常量、注释
- Gradle配置国内源
- HDU3930(离散对数与原根)
- 说说 Android 的 Material Design 设计(四)——卡片式布局
- excel引用指定单元格数据_数据、运算符及单元格引用
- 咨询的真相5:咨询业的“前世今生”
- 机器翻译是否能替代人工翻译?从前世今生说起
- Office办公 如何打印顺丰发票
- java 改变图片某个坐标点的颜色,并返回给前台显示
- 数据治理:数据质量管理策略!
- 用AnLink可以用鼠标同时操作电脑和手机
- 详细说明VScode设置中文,主题更改,文件图标及字体设置
- 并注册烧写钩子 获取启动介质类型_一种基于USB烧写的数据传输方法与流程
- 民族列表JSON(可直接复制)
- Tk应用程序之place界面布局
- 适配 iPhone13、iPhone13 pro、iPhone13 proMax