Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

356
Views
cómo resolver el error interno del servidor 500 mod_wsgi apache "importerror: ningún módulo llamado 'django'

He estado tratando de resolver este error pero no he podido resolverlo, estoy totalmente frustrado porque he intentado todas las respuestas a estas preguntas relacionadas, cualquier ayuda sería apreciada.

Mi configuración de servidor VPS

 Ubuntu 18.04 django 2.2.5 apache 2.4.49 python 3.6(virtualenv) libapache2-mod-wsgi-py3

Mi estructura de carpetas es:

 /var/www/dataforze/prediction_project/venv (virtualenv folder) bin include lib /var/www/dataforze/prediction_project |- manage.py static venv prediction_project |__init__.py |settings.py |urls.py |wsgi.py

000-default.conf código de archivo

 <VirtualHost *:80> <Directory /var/www/dataforze/prediction_project/prediction_project> Require all granted </Directory> <Directory /var/www/dataforze/prediction_project/prediction_project> <Files wsgi.py> Require all granted </Files> </Directory> WSGIDaemonProcess prediction_project python-path=/var/www/dataforze/prediction_project python-home=/var/www/dataforze/prediction_project/venv WSGIProcessGroup prediction_project WSGIScriptAlias / /var/www/dataforze/prediction_project/prediction_project/wsgi.py ErrorLog ${APACHE_LOG_DIR}/mysite_error.log LogLevel warn </VirtualHost>

mi sistema operativo de importación de código de archivo wsgi.py

de django.core.wsgi importar get_wsgi_application

 sys.path.append('/var/www/dataforze/prediction_project/prediction_project') # add the virtualenv site-packages path to the sys.path sys.path.append('/var/www/dataforze/prediction_project/venv/lib/site-packages') os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'prediction_project.settings') application = get_wsgi_application()

Mis registros del servidor

 [Wed Mar 18 17:29:01.003624 2020] [wsgi:error] [pid 82169:tid 140431942575872] mod_wsgi (pid=82169): Target WSGI script '/var/www/dataforze/prediction_project/prediction_project/wsgi.py' cannot be loaded as Python module. [Wed Mar 18 17:29:01.003722 2020] [wsgi:error] [pid 82169:tid 140431942575872] mod_wsgi (pid=82169): Exception occurred processing WSGI script '/var/www/dataforze/prediction_project/prediction_project/wsgi.py'. [Wed Mar 18 17:29:01.003823 2020] [wsgi:error] [pid 82169:tid 140431942575872] Traceback (most recent call last): [Wed Mar 18 17:29:01.003844 2020] [wsgi:error] [pid 82169:tid 140431942575872] File "/var/www/dataforze/prediction_project/prediction_project/wsgi.py", line 12, in <module> [Wed Mar 18 17:29:01.003849 2020] [wsgi:error] [pid 82169:tid 140431942575872] from django.core.wsgi import get_wsgi_application [Wed Mar 18 17:29:01.003864 2020] [wsgi:error] [pid 82169:tid 140431942575872] ModuleNotFoundError: No module named 'django'
over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!