簡體   English   中英

Apache錯誤地配置了httpd.conf

[英]Apache misconfiguring httpd.conf

我將暫存django服務器的httpd.conf文件上傳到實時服務器,然后重新啟動它,這使站點癱瘓了。 返回正確的文件后,重新啟動它並停止登台服務器,在顯示top_menu缺少信息的頁面上,每隔5次刷新,我大top_menu一次內部服務器錯誤

[Fri Nov 13 11:38:41.793432 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]     result = block.nodelist.render(context)
[Fri Nov 13 11:38:41.793440 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]   File "/home/kbuzz/lib/python2.7/django/template/base.py", line 844, in render
[Fri Nov 13 11:38:41.793452 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]     bit = self.render_node(node, context)
[Fri Nov 13 11:38:41.793461 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]   File "/home/kbuzz/lib/python2.7/django/template/base.py", line 858, in render_node
[Fri Nov 13 11:38:41.793473 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]     return node.render(context)
[Fri Nov 13 11:38:41.793481 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]   File "/home/kbuzz/webapps/django/lib/python2.7/mptt/templatetags/mptt_tags.py", line 284, in render
[Fri Nov 13 11:38:41.793495 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]     queryset = self.queryset_var.resolve(context)
[Fri Nov 13 11:38:41.793504 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]   File "/home/kbuzz/lib/python2.7/django/template/base.py", line 734, in resolve
[Fri Nov 13 11:38:41.793516 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]     value = self._resolve_lookup(context)
[Fri Nov 13 11:38:41.793524 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]   File "/home/kbuzz/lib/python2.7/django/template/base.py", line 780, in _resolve_lookup
[Fri Nov 13 11:38:41.793537 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256]     (bit, current))  # missing attribute
[Fri Nov 13 11:38:41.793580 2015] [wsgi:error] [pid 130327:tid 139718655588096] [remote 127.0.0.1:25256] VariableDoesNotExist: Failed lookup for key [top_menu] in u"[{'False': False, 'None': None, 'True': True}, {}]"

轉到此上下文處理程序'top_menu':Page.objects.filter(top_menu=True, visible=True),並從外殼程序運行時正確返回信息。

>>> from pages.models import *
>>> Page.objects.filter(top_menu=True, visible=True)
[<Page: Home>, <Page: What’s On>, <Page: What’s On :: Today>, <Page: What’s On :
: This Weekend>, <Page: What’s On :: This Month>, <Page: Movies>, <Page: Movies
:: Now Showing>, <Page: Lifestyle>, <Page: Biz Directory>, <Page: Buy&Sell >, <P
age: Galleries>, <Page: Newsletters>]
>>>

我想重置apache服務器以立即開始正常工作。

我發現錯誤是由於wsgi中的sys路徑指向錯誤的路徑,重新啟動服務器導致錯誤開始出現。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM