Hi James, Thanks for reply.
I read below commands to install for mod_wsgi from here - (https://modwsgi.readthedocs.io/en/develop/user-guides/quick-installation-guide.html) tar xvfz mod_wsgi-X.Y.tar.gz cd mod_wsgi-4.5.14 ./configure --with-apxs=/usr/sbin/apxs --with-python=/usr/local/bin/python3 make make install Since I already had apache installed on Linux , I could locate apxs file bash-4.1# locate apxs /usr/local/apache2/bin/apxs Can I install mod_wsgi at system level with this command for existing apache installation as an laternative to pip install mod_wsgi. ./configure --with-apxs=/usr/local/apache2/bin/apxs --with-python=/usr/local/bin/python3 On Friday, September 15, 2017 at 3:24:46 PM UTC+5:30, James Schneider wrote: > > > > On Sep 15, 2017 2:04 AM, "BIJAL MANIAR" <bij...@gmail.com <javascript:>> > wrote: > > > Hi, > I had a production application running with Python2.7 and Django1.11 > through Apache and mod_wsgi. > Now I have upgraded to Python3.5 and created virtual env. pip install > mod_wsgi is giving below error. > > (p3_venv) bash-4.1# pip install mod_wsgi > Collecting mod_wsgi > Downloading mod_wsgi-4.5.18.tar.gz (2.5MB) > Complete output from command python setup.py egg_info: > Traceback (most recent call last): > File "<string>", line 1, in <module> > File "/tmp/pip-build-_hbwnbp5/mod-wsgi/setup.py", line 164, in > <module> > 'missing Apache httpd server packages.' % APXS) > RuntimeError: The 'apxs' command appears not to be installed or is not > executable. Please check the list of prerequisites in the documentation for > this package and install any missing Apache httpd server packages. > > > You're likely missing the development libraries needed to build Apache > itself. Mod_wsgi needs to link with those during it's installation process. > > > > Since mod_wsgi was already installed for Python2.7 how do I reinstall > mod_wsgi. Do I need to re install within virtual environment or at system > level. Any links/list of steps will be helpful. > Any help would be appreciated. > > > That is very dependent on your environment and how much control you want > over the patch and update process. You'll need to remove the 2.7 version of > mod_wsgi, or at the very least, prevent Apache from loading it. It cannot > be loaded at the same time as another mod_wsgi instance using a different > Python version. > > You'll need to either use your system package manager to install the py3 > version of mod_wsgi and hope that it matches your python version, or build > it yourself (as you are trying to do) from a virtualenv that will run your > project. Once that completes, you'll need to point Apache at the new module > you've built. It's not necessarily trivial. Start with the official guide, > or look for one specific to your OS: > > https://modwsgi.readthedocs.io/en/develop/installation.html > > -James > -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at https://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/829ac778-b997-445b-81ee-bf0104a76d44%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.