禁用 mod_python 错误和追踪信息
我想要关闭 mode_python 的错误提示、错误追踪、模块缓存的详细信息以及其他任何警告通知!
我在使用简单的 mod_python 模块,运行在 Ubuntu 服务器上,搭配 Apache,没有使用任何框架(比如 Django 等等)。
我在 GOOGLE 上搜索了很多,但没有人提到这个 :)
我想要一个类似于 error_reporting(0);
在 PHP 中的替代方法,或者在服务器端进行任何配置更改。
提前谢谢你!
2 个回答
0
嘿,
如果你在用Ubuntu,可以这样做:
输入命令:sudo a2dismod mod_python
然后再输入:sudo /etc/init.d/apache2 restart
希望这能帮到你 :)
0
这里是答案:
vi /etc/apache2/sites-available/default
修改为:
PythonDebug On
变成:
PythonDebug Off
然后
service apache2 restart
完成了;)