关于Apache如何处理文件上传任何文档? [英] Any documentation about how Apache handles file uploads?

查看:113
本文介绍了关于Apache如何处理文件上传任何文档?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经花了几个小时谷歌搜索,以及搜索Apache的网站,我无法找到关于Apache如何处理文件上传任何文件 - 特别是路数。我读过传闻reports ,PHP是没有参与,直到上载完成,这是我的期望。但就在上载过程中有什么做的Apache,我找不到任何东西。

I've spent hours googling, as well as searching the Apache site, and I can't find any documentation about how Apache handles file uploads — particularly large ones. I've read anecdotal reports that PHP isn't involved until the upload is complete, which is what I'd expect. But as far as what Apache does during the upload, I can't find anything.

我是火爆文档的原因是,Apache是​​完全上传存储在内存中,而不是将它们分流到磁盘。 的httpd 将使用可用内存的每个字节我使用,直到它崩溃的服务器上。通常的物理内存占用量的3倍文件的大小被上传,并增加在5 MB /秒(远不及我的上传速度)附近。

The reason I'm hot for documentation is that Apache is storing uploads entirely in memory, instead of streaming them to disk. httpd will use every byte of available memory on the server I'm using until it crashes. Typically the amount of physical memory consumed is 3x the size of the file being uploaded, and increases in the vicinity of 5 MB/s (nowhere near my upload speed).

我已经测试过我在使用其他LAMP堆栈同样的请求,Apache的内存使用量并不整个上传的过程中有任何变化。

I've tested this same request on another LAMP stack I'm using, and Apache memory usage doesn't change at all throughout the course of the upload.

任何人都可以向我解释的Apache如何处理相同的上传如此不同的两个不同的服务器?任何想法大大AP preciated。

Can anyone explain to me how Apache could handle the same upload so differently on two different servers? Any thought greatly appreciated.

推荐答案

答案是不令人满意的。我从来没有发现任何文件。

The answer is unsatisfying. I never found any documentation.

我继续在黑暗中闲逛,终于跌跌撞撞在 mod_fcgid 升级(2.2到2.3.6)该做的伎俩。或许有一个bug 2.2。

I continued poking around in the dark, finally stumbling on a mod_fcgid upgrade (from 2.2 to 2.3.6) that did the trick. Perhaps there was a bug in 2.2.

内存使用量仍然上升在2.3.6,但远不是那么显着。只有几兆的〜100 MB的文件。 (然而,当上传完成后,文件被移动时,内存使用量瞬间拍摄最多〜100-200 MB,但后来似乎被立即释放。)

The memory usage still goes up in 2.3.6, but far less dramatically. Only a few megabytes for a ~100 MB file. (However, when the upload finishes and the file is moved, memory usage instantly shoots up ~100-200 MB, but then seems to be immediately released.)

这篇关于关于Apache如何处理文件上传任何文档?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆