Questions tagged [mod-wsgi]
mod_wsgi is an easy to use Apache module that can host Python web applications which support the Python WSGI interface.
399
questions
0
votes
0
answers
16
views
Apache mod_wsgi serving rest api and static website on virtualhost
So I have an ec2 instance running debian with apache and mod_wsgi to serve my flask rest api and I also have a static web page using react which makes calls to the api to abstract the database logic.
...
0
votes
0
answers
54
views
How can I enable mod_wsgi in Apache2.4.57.0 on Windows?
Apache/2.4.57 (Win64)
Django 2.4.2
I am new to Django and I tried to connect it with Apache through mod_wsgi but it seems new versions of Apache does not support such kind of module. I installed ...
2
votes
2
answers
9k
views
Error when trying install mod_wsgi using pip
When trying to install mod_wsgi using pip as follows:
pip install mod_wsgi
I get the following error:
4m.so -L/usr/local/lib -L/usr/local/lib/python3.4/config-3.4m
-lpython3.4m
/bin/ld: /...
0
votes
0
answers
252
views
apache mod_wsgi error, randomly: Unable to connect to WSGI daemon process
Recently, our server shut down out of nowhere, this what Apache logs show up:
[wsgi:error] [pid 8837:tid 140646648096512] (2)No such file or directory: [client] mod_wsgi (pid=8837): Unable to connect ...
0
votes
0
answers
79
views
403 FORBIDDEN APACHE django
Apache/2.4.54 (Win64) OpenSSL/1.1.1p PHP/8.1.12 mod_wsgi/4.9.4 Python/3.11 Server at localhost Port 80
I am trying to run my django project on my windows machine.. in apache this the configuration i ...
3
votes
1
answer
292
views
Issues with URL length in Apache/mod_wsgi
I have a python wsgi API in which I process incoming URL payloads of varied length. I believe, but am not absolutely sure, that I may have run into a limitation of URL size.
For a particular payload (...
1
vote
1
answer
2k
views
Restarting or stopping apache results in waiting forever
I have two simple WSGI apps running on top of mod_wsgi and apache2 (worker) on a test development server. There is no mod_python on this machine.
The WSGI configuration is as follows
...
1
vote
1
answer
2k
views
Django, mod_wsgi, pyvenv-3.4 - configuration
I'm trying to deploy my first, simple django website. I have an VPS with Ubuntu 14.07 Server, Apache 2.4.7 with mod_wsgi. So, i added this vhost:
<VirtualHost *:80>
ServerName api.XXX.net
...
1
vote
2
answers
2k
views
Where is WSGI installed on Centos?
I am getting a permissions issue when running django in daemon mode. Reading here https://code.google.com/p/modwsgi/wiki/ConfigurationIssues#Location_Of_UNIX_Sockets I think the solution is to ...
1
vote
1
answer
2k
views
hosting static files with mod_wsgi
I've followed Graham's simple configuration instructions for hosting static files along with a wsgi application mounted at the domain root. And in fact, my site is working.
However, requests for ...
3
votes
1
answer
3k
views
Apache and mod_wsgi returning 504 error when posting specific SVG string
I have a wierd 504 error occuring in Apache + mod_wsgi when I post a specific SVG string. The backend application is Python Flask, but it does not seem to get to the application at all.
Here is one ...
1
vote
1
answer
2k
views
Enabling mod_wsgi in Apache for a Django app on Gentoo
I installed Apache, Django, and mod_wsgi on Gentoo using emerge (on Amazon EC2).
I know that the mod_wsgi is configured in /etc/apache2/modules.d/70_mod_wsgi.conf:
<IfDefine WSGI>
LoadModule ...
0
votes
1
answer
2k
views
Apache mod_wsgi tuning
I have a django site on webfaction that uses apache + mod_wsgi.
Site is getting around 1000 requests per minute.
But it makes some calculations, so request takes about 5-10 seconds.
I use the ...
1
vote
1
answer
2k
views
Django 1.10.3 Apache wsgi - ImportError: cannot import name signals
Overnight django stopped working, possibly because of an automatic package upgrade on the server. Its wsgi script now fails to load in production, but running the development server works fine. What ...
0
votes
1
answer
2k
views
mod_wsgi app in two different ports
I have a WSGI app working in prod and I want a staging app in the same server, So I configured two virtual hosts in different ports, 80 for prod and 9090 for stag, but every time I request port 9090 ...
1
vote
1
answer
115
views
Server returning response for previous requests
It's a really strange problem. I believe it to be a server issue, but it's so strange and hard to reproduce that I'm not entirely sure.
Just as the title says I'm receiving responses for earlier ...
1
vote
1
answer
302
views
Which is Best way to serve multiple wsgi apps using apache2 with different python versions?
Right now I've got a python2 django app deployed in my sever using apache2 and mod-wsgi. Now I want to deploy another one, but this is written in python3. My problem is that mod-wsgi is compiled to ...
0
votes
0
answers
112
views
Apache24 on windows returns 'It works' only instead of the virtual hosts
I have configured Apache 24 with mod_wsgi on windows 2016 server for my Django applications and deployed three websites with different IP addresses. I have also configured ssl certificates for each ...
1
vote
1
answer
4k
views
Compiling mod-wsgi - How to install python3-devel on centos-6.8
I'm trying to deploy Django-1.10 on Centos-6.8 using default apache in centos(version 2.2).
I'm using python 3.4.5.I'm not able to compile mod-wsgi without python3-devel. Centos-6.8 repos doesn't have ...
0
votes
1
answer
2k
views
Unable to install mod_wsgi on CentOS 5.5 VPS
I am trying to install mod_wsgi on my VPS, but it won't work. This is what I am doing:
wget http://modwsgi.googlecode.com/files/mod_wsgi-2.5.tar.gz
tar xzvf mod_wsgi-2.5.tar.gz
cd mod_wsgi-2.5
./...
1
vote
2
answers
5k
views
How to enable/load mod_wsgi in apache server in centos 8 VPS
I am not able to enable/load module mod_wgsi in apache webserver in cent os 8 VPS. It works very easily in ubuntu by running the command sudo apt install libapache2-mod-wsgi-py3 Please Help me getting ...
2
votes
1
answer
2k
views
HTTP 503 errors with Apache and mod_wsgi
I have written a webapp in Django that I host under Apache 2.4 using mod_wsgi.
At first glance, it works fine. However, when the Apache process has been running for a while, the webapp starts ...
1
vote
1
answer
572
views
Why does Apache with mod_wsgi force a download of .py files instad of executing them?
Why does Apache with mod_wsgi force a download of .py files instead of executing them?
I'm trying to run Django, but the first issue I have is .py files not executing.
I'm following the docs here ...
1
vote
1
answer
727
views
Running multiple flask applications with different domain names using mod_wsgi
We are trying to run 2 different flask applications with different domain names from same server using mod_wsgi + Apache2.
This is the settings configured in httpd.conf
# For www.yyy.com
...
1
vote
0
answers
52
views
Determining which Mercurial version which created a repository
I have a rather large Mercurial web server (ie. running under hgweb.wsgi) that's outgrown the distribution it was built-on... which basically means that I've already started doing upgrades of Python, ...
0
votes
1
answer
390
views
Apaches virtual host config suddenly not working anymore; how to debug?
out of the blue my virtual host config doesn't work anymore. So my setup sould be quite easy: On Port 80, I want to deliver two WSGI apps, and that's the .conf file I'm using:
<VirtualHost *:80>
...
2
votes
2
answers
1k
views
Why is Apache2 not finding my WSGI app?
In my previous question, I asked how to make mod_wsgi use a specific Python version. Following the answer from that question, I created a Python 3.9 virtual environment and made WSGI use it. However, ...
6
votes
1
answer
6k
views
How to make mod_wsgi use Python 3.9?
I originally had Python 3.6 installed and working well with WSGI and Apache2 on my Linux server.
Then I created a Flask app that had a dependency needing Python 3.7.
I've successfully (and I think) ...
1
vote
2
answers
7k
views
Error: "module wsgi_module is already loaded, skipping"
Please help me out, I have been trying to resolve this error from a long time.
when i restart Apache and type :sudo /usr/sbin/apachectl -t, I get an output like:
[Fri Aug 24 17:02:58 2012] [warn] ...
0
votes
1
answer
2k
views
Centos7 mod_wsgi python3 django timeout error 504 Gateway error
I have been using apache for a django project. I need to upload a very large file in application. But I am getting Gateway timeout error 504.
I am using Centos7, httpd2.4, mos_wsgi, python3.48
#...
1
vote
0
answers
92
views
Unsuccessful flask app deployment on Amazon EC2 instance
I am trying to deploy a flask app on an Amazon EC2 instance. I have configured everything just fine but the website does not load. It remains stuck on the loading icon as follows:
Website not loading
...
2
votes
0
answers
2k
views
Timeout when reading response headers from daemon process. Python, Flask, Apache
I have a problem with my mod_wsgi configuration. Sometimes, I think when there is a lot of traffic on my website, the page breaks and says "Resource temporarily unavailable..."
Apache logs:
...
0
votes
0
answers
48
views
Coworkers think latest Django 3.1.7 needs a mod_wsgi newer than the 3.4.18 provided by Centos 7.9
My coworkers are asking me why we are using the Centos 7.9 provided apache + mod_wsgi for the sake of Django 3.1.7
VERSUS
hand assembling a custom build of either Centos 7.9's apache or a custom ...
0
votes
1
answer
446
views
service apache2 start causes error in django
On running
apache2 configtest
I get
Syntax error on line 2 of
/etc/apache2/sites-enabled/firstweb.conf: Invalid command
'WSGIScriptAlias', perhaps misspelled or defined by a module not
included in ...
1
vote
0
answers
477
views
How to debug my config file for wsgi
I am trying to install a server for inginious (a program for automatic grading). One step in the installation is configuring Apache2 to use mod_wsgi. Here is the configuration file inginious.conf:
<...
10
votes
2
answers
4k
views
High CPU load on Django/Apache/mod_wsgi site
Load testing a django 1.21/Apache/mod_wsgi configuration on an AWS small instance (Ubuntu 10.04) with Apache bench is showing extremely high CPU load (using uptime and vmstat) at low concurrent ...
0
votes
1
answer
2k
views
AH00035: access to / denied 403 Forbidden Django mod-wsgi
I am trying to configure apache with Django using mod-wsgi. But I am getting the following error
AH00035: access to / denied (filesystem path '/home/ec2-user/ezvoice') because search permissions are ...
1
vote
1
answer
7k
views
Apache 2.4 with mod_wsgi: 403 Forbidden, don't have permission to access /calbase on this server
So I am trying to deploy my django project on a windows server, using apache 2.4 with mod_wsgi and pythong 3.4. Before I configure httpd.conf and just try start apache with mod-wsgi installed, it ...
0
votes
1
answer
670
views
Apache, mod-wsgi: Any URL is served by project, ServerName is ignored
I am setting up a Django project and Apache on Ubuntu 20. The below setup correctly displays the Django project, however ANY URL that points to the server's IP address is served this project. I ...
0
votes
1
answer
184
views
How to get to modwsgi 4+ on Centos7
On Centos7, yum pulls in mod_wsgi 3.4 using a yum install. I'm having some problems and multiple resources I have looked at regard this version as ancient and ask the users to upgrade to 4+. I'm not ...
2
votes
1
answer
1k
views
Apache2.4 + Python 3.7 + mod_wsgi not executing script
I have installed Apache 2.4 (vc15 apacheLounge) and Python 3.7. I installed the mod_wsgi using PIP and everything appears to be setup correct in the Apache server.
error.log from apache:
[mpm_winnt:...
0
votes
3
answers
7k
views
Apache/httpd error: Invalid command 'WSGIPythonHome'
ISSUE:
My Apache/httpd server will not launch. journalctl -xe reveals:
Feb 27 01:50:12 localhost.localdomain httpd[4398]: AH00526: Syntax error on line 355 of /etc/httpd/conf/httpd.conf:
Feb 27 01:...
1
vote
0
answers
1k
views
Apache Server Error: ImportError: No module named site
I am trying to serve my django project over Apache using mod_wsgi. Apache will start but my project in inaccessible. When Apache launches I see ImportError: No module named site in the log. There is ...
6
votes
1
answer
11k
views
Django with Apache and mod_wsgi: no system log unless setting Debug = True
I'm using apache web server and mod_wsgi to transfer request to django.
$ apache2ctl -v
Server version: Apache/2.4.10 (Raspbian)
Server built: Sep 17 2016 16:40:43
I'm using this apache site to ...
0
votes
0
answers
290
views
How to correctly tune Apache and mod_wsgi
I'm using Django with mod_wsgi and need to tune the httpd.conf to handle 500 requests per second at peak.
Right now I have the following configuration:
StartServers 3
ServerLimit 15
MinSpareThreads ...
1
vote
1
answer
9k
views
Django 2.1 deployment on centos 7 with apache, mod_wsgi, python3 venv
I've stumbled with this seemingly most relevant deployment option because guides seem to either reference mod_wsgi with python2, or deployment on deb based systems where expected paths are different.
...
0
votes
1
answer
3k
views
Are mod_wsgi, python3-mod_wsgi and libapache2-mod-wsgi-py3 the same thing? Do i need just one for Django on RHEL 7.6?
I see a couple of tutorials mentioning the Gate Interface specific to python3.6 for Ubuntu -- libapache2-mod-wsgi-py3 as opposed to just mod_wsgi in RHEL's case.
Should i be worrying about looking for ...
0
votes
1
answer
2k
views
Python module import from a WSGI script fails on RedHat server
Here is a minimal WSGI script, importing a custom python module.
It runs fine on a development environment (Mint 18.1, Apache 2.4.18, libapache2-mod-wsgi-py3), but fails when deployed to a test ...
0
votes
1
answer
384
views
Need .py files to execute in the same directory with .html and .php files using mod_wsgi
I'm running CentOS 8.1 with Python 3.6.8, and Apache/2.4.37.
I'm new to mod_wsgi. I found this "hello world" example and got it to work:
https://www.ionos.com/community/hosting/python/use-mod-wsgi-...
18
votes
5
answers
27k
views
WSGI : Truncated or oversized response headers received from daemon process
System Configuration : Apache2, Django 1.10, Python 3, Ubuntu 16.04 LTS
Django debug=True.
/var/log/apache2/error.log
[52:53.057967] [wsgi:error] [pid 4303] [client 1.1.1.22:24409] Timeout when ...