Django project troubleshootings

1. 当django project文件夹放到cgi-bin目录下面时会出现下面的错误:

[Wed Jan 09 01:52:52.611690 2019] [core:notice] [pid 15229:tid 140466120317888] AH00094: Command line: '/usr/sbin/apache2'
[Wed Jan 09 01:52:58.777013 2019] [cgi:error] [pid 15233:tid 140465976928000] [client 60.247.80.142:18849] AH01215: (8)Exec format error: exec of '/u
sr/lib/cgi-bin/djangoTest/testdj/testdj/wsgi.py' failed: /usr/lib/cgi-bin/djangoTest/testdj/testdj/wsgi.py
[Wed Jan 09 01:52:58.777271 2019] [cgi:error] [pid 15233:tid 140465976928000] [client 60.247.80.142:18849] End of script output before headers: wsgi.
py

resolution:

  把django project的文件夹移动其他不属于cgi控制的位置。

参照:https://stackoverflow.com/questions/37993270/end-of-script-output-before-headers-wsgi-py

 

posted @ 2019-01-09 10:25  lijavasy  阅读(244)  评论(0编辑  收藏  举报