Turns out that since the export file was over 512k, Mod Security was balking it. To fix it, I just adjusted the filesize on the following rule:
SecResponseBodyLimit 1572864
今天上传图片,发现超过100K的文件就会出现403错误,Request entity too large, Post size exceed.之类的。总之就是文件太大,超过POST方法的限制。我的php.ini限制放的很宽松,所以以为是ajax使用的post方法有限制,查了google,大多数人都提到了在Http.conf里调整LimitRequestBody的方法,但是对我没用。突然想到,限制POST SIZE,肯定是为了防止服务器被攻击,和安全性有关,仔细看了看mod_security2的配置文件,发现正是这几个参数限制引起的
# Maximum request body size we will
# accept for buffering
SecRequestBodyLimit 131072
# Store up to 128 KB in memory
SecRequestBodyInMemoryLimit 131072
# Buffer response bodies of up to
# 512 KB in length
SecResponseBodyLimit 524288
把上面这几个值调大一些,上传文件就不会再超过限制了。