I am deploying Flask application in Apache2 server during this i need to run a command for enabling mod_wsgi by using:
sudo a2enmod wsgi
but its showing:
sudo: a2enmod: command not found
please help thanks
I am deploying Flask application in Apache2 server during this i need to run a command for enabling mod_wsgi by using:
sudo a2enmod wsgi
but its showing:
sudo: a2enmod: command not found
please help thanks
I had the same problem with using Ubuntu 16.04 in AWS. However, installing apache2 along with libapache2-mod-wsgi and python-dev solved the issue.
Try:
sudo apt-get update
sudo apt-get install apache2 libapache2-mod-wsgi python-dev
Then,
sudo a2enmod wsgi
sudo systemctl reload apache2
will be needed –
Toilsome I share this tips because it append to me :
If you enter into the root account with su
, the /usr/sbin
folder is not in the path and the a2enmod
command is not found...
So you have to use su -
instead ;)
This can happen if you switch to root user as su root
instead of su -
on Debian Buster
For asking about installation debugging, you have to post (and think) about
You could try to reinstall your package. If under Ubuntu, you could try:
sudo apt update &&
sudo apt reinstall apache2 libapache2-mod-wsgi
Then rerun:
sudo a2enmod wsgi
© 2022 - 2024 — McMap. All rights reserved.
mod_wsgi
package installed? – Cornfield