Django Apache Mod Wsgi Internal Server Error
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta mod_wsgi 500 internal server error Discuss the workings and policies of this site About Us Learn
You Don't Have Permission To Access / On This Server Django
more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack wsgi 500 error Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, django apache 500 helping each other. Join them; it only takes a minute: Sign up Apache2 mod_wsgi, 500 Internal Server Error up vote 3 down vote favorite 4 I setup, django App with Apache2, 1) Virtual host:
Flask Mod_wsgi Internal Server Error
/media/ /var/www/mysite/media/
here for a quick overview of the site Help Center Detailed answers to any internal server error django nginx questions you might have Meta Discuss the workings and policies mod_wsgi error log of this site About Us Learn more about Stack Overflow the company Business Learn more about
500 Internal Server Error Django
hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow http://stackoverflow.com/questions/5713689/apache2-mod-wsgi-500-internal-server-error is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Internal Server Error 500 using Apache, Django and mod_wsgi up vote 0 down vote favorite I'm trying to run a Django application on port 8000 of a server. (port 80 http://stackoverflow.com/questions/37147161/internal-server-error-500-using-apache-django-and-mod-wsgi is occupied by WordPress) And I'm getting an internal server error when I visit :8000 extension of the website. Here is the wsgi.py located at /var/www/admin # wsgi.py import os import sys import site # Add the site-packages of the chosen virtualenv to work with site.addsitedir('home/ubuntu/DjangoApp/env/local/lib/python2.7/site-packages') # Add the app's directory to the PYTHONPATH sys.path.append('/home/DjangoApp/tnttauburn') sys.path.append('/home/DjangoApp/tnttauburn/tnttauburn') os.environ['DJANGO_SETTINGS_MODULE'] = 'tnttauburn.settings' # Activate your virtual env activate_env=os.path.expanduser("home/ubuntu/DjangoApp/env/bin/activate_this.py") execfile(activate_env, dict(__file__=activate_env)) import django.core.handlers.wsgi application = django.core.handlers.wsgi.WSGIHandler() Here is the apache config file at /etc/apache2/sites-available/admin.conf Listen 8000
I went through the tutorial, but in the end I got a 500 server error. Changing my settings.py DEBUG to true, I still just see this server error. I checked the error https://community.webfaction.com/questions/13747/mod_wsgi-and-500-server-error log, and it's telling me: [notice] caught SIGTERM, shutting down [warn] mod_wsgi: Compiled for Python/2.7.3. [warn] mod_wsgi: Runtime using Python/2.7.5. [notice] Apache/2.2.17 (Unix) mod_wsgi/3.4 Python/2.7.5 configured -- resuming normal operations That led me to this article: http://code.google.com/p/modwsgi/wiki/InstallationIssues#Python_Patch_Level_Mismatch , which says "The warning is indicating that a newer version of Python is now being used than what mod_wsgi was originally compiled for." I don't really know how to proceed after internal server this point. Any help is greatly appreciated. mod_wsgi asked 17 Jun '13, 16:20 edsherry 1●1●2 accept rate: 0% One Answer: active answersoldest answersnewest answerspopular answers 1 The mod_wsgi mismatch is not a problem. My guess is that you have a syntax error in settings.py or wsgi.py. Try to run: python2.7 settings.py python2.7 wsgi.py Both should return with no output. permanent link answered 18 Jun '13, 00:09 DS1 11●2 accept internal server error rate: 0% Thank you DS1. I just tried your suggestion but both returned with no output. I'll dig around and see if I made a syntax error in some other file. (18 Jun '13, 07:45) edsherry I did some digging around and it was a syntax error in the ALLOWED_HOSTS setting, and your post had me looking in the right place. Thanks again DS1. (18 Jun '13, 10:19) edsherry Your answer toggle preview community wiki: Follow this questionBy Email:Once you sign in you will be able to subscribe for any updates hereBy RSS: Answers Answers and Comments Markdown Basics *italic* or _italic_ **bold** or __bold__ link:[text](http://url.com/ "title") image?![alt text](/path/img.jpg "title") numbered list: 1. Foo 2. Bar to add a line break simply add two spaces to where you would like the new line to be. basic HTML tags are also supported learn more about Markdown Question tags: mod_wsgi ×50 question asked: 17 Jun '13, 16:20 question was seen: 2,597 times last updated: 18 Jun '13, 10:19 Related questions Django WSGI path/import problems Increase mod_wsgi processes Deploying Flask on Webfaction – cannot get mod_wsgi's WSGIScriptAlias nor Alias function to work How to enter Werkzeug debug mode with mod_wsgi Existing django project New django app fails w