python – 在mod_wsgi下运行Django站点
发布时间:2021-01-12 00:07:42 所属栏目:Python 来源:互联网
导读:我试图运行我的Django网站与mod_wsgi而不是mod_ python(RHEL 5).我试过这个我所有的网站,但得到同样的问题.我配置它是每个人推荐的标准方式,但要求网站只是时间超时. Apache conf: VirtualHost 74.54.144.34 DocumentRoot /wwwclients/thymeandagain ServerN
我试图运行我的Django网站与mod_wsgi而不是mod_ python(RHEL 5).我试过这个我所有的网站,但得到同样的问题.我配置它是每个人推荐的标准方式,但要求网站只是时间超时. Apache conf: <VirtualHost 74.54.144.34> DocumentRoot /wwwclients/thymeandagain ServerName thymeandagain4corners.com ServerAlias www.thymeandagain4corners.com LogFormat "%h %l %u %t "%r" %>s %b "%{Referer}i" "%{User-Agent}i"" combined CustomLog /var/log/httpd/thymeandagain_access_log combined ErrorLog /var/log/httpd/thymeandagain_error_log LogLevel error WSGIScriptAlias / /wwwclients/thymeandagain/wsgi_handler.py WSGIDaemonProcess thymeandagain user=admin group=admin processes=1 threads=16 WSGIProcessGroup thymeandagain </VirtualHost> wsgi_handler.py: import sys import os sys.path.append("/wwwclients") os.environ['DJANGO_SETTINGS_MODULE'] = 'thymeandagain.settings' import django.core.handlers.wsgi application = django.core.handlers.wsgi.WSGIHandler() 守护进程mod_wsgi应该是不存在的,所以请求只是超时,我在日志中收到一堆“无法连接到WSGI守护进程”错误.有没有关于阻止创建守护进程的WSGIDaemonProcess指令?提前感谢任何帮助… 编辑:我在错误日志中得到这个: [WARN@1227228322.174175] mcm_server_readable():2582: timeout: Operation now in progress: select(2) call timed out for read(2)able fds [INFO@1227228322.174263] mcm_get_line():1592 [WARN@1227227903.249626] mcm_server_readable():2582: timeout: Operation now in progress: select(2) call timed out for read(2)able fds [INFO@1227227903.249712] mcm_get_line():1592 [Thu Nov 20 21:18:17 2008] [notice] caught SIGTERM,shutting down [Thu Nov 20 21:18:18 2008] [notice] Digest: generating secret for digest authentication ... [Thu Nov 20 21:18:18 2008] [notice] Digest: done [Thu Nov 20 21:18:18 2008] [notice] mod_python: Creating 4 session mutexes based on 8 max processes and 64 max threads. [Thu Nov 20 21:18:18 2008] [notice] Apache/2.2.3 (Red Hat) mod_python/3.2.8 Python/2.4.3 mod_wsgi/2.1-BRANCH configured -- resuming normal operations 解决方法问题是mod_python与mod_wsgi不一致.几周前我遇到了类似的问题,在我发表mod_python包含之后,一切都开始为我工作.尝试搜索modwsgi.org维基的“mod_python”,我相信有人在评论中谈论这个 (编辑:十堰站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- python – 单元测试(烧瓶 – 静止)GET API调用时获得500内部
- 如何使用python查询mongodb中的不同结果?
- Python中比较特别的除法运算和幂运算介绍
- 如何将我的Telegram Bot加入PUBLIC频道
- Python – 降低niceness值
- python – 如何覆盖BaseHTTPRequestHandler log_message()方
- python – 了解matplotlib xticks语法
- 如何在python 2.7.6中导入_ssl?
- python – TypeError:尝试模拟classmethod时的未绑定方法
- Python3如何通过唯一键连接两个dicts列表
推荐文章
站长推荐
- python – django:django-tables2 DetailView C
- python – SqlAlchemy在保存之前将UTC DateTime转
- python – 加速解决三角线性系统与numpy?
- 根据其属性为python对象生成唯一的ID
- python – 为Linux上的HDMI端口开发
- python – pandas:用loc迭代DataFrame索引
- python – 使用scikit-learn(sklearn),如何处理线
- python – 禁止“程序无法启动因为X.dll丢失”错
- python – 改变Kivy中Button的背景颜色
- python – 如何使用多个服务器进行Flask登录
热点阅读