> On 21 Dec 2018, at 8:55 am, Siavosh Kasravi <[email protected]> wrote:
>
>
> What exact command are you running and what error do you get.
>
> Exact command: mod_wsgi-express install-module
> Exact Error: "Usage: mod_wsgi-express command [params]
>
> Commands:
> module-config
> module-location
For Windows you are meant to run:
mod_wsgi-express module-config
and copy the output from that into your existing Apache configuration file.
> mod_wsgi-express: error: Invalid command was specified."
>
> You can't use 'mod_wsgi-express start-server' or 'python manage.py
> runmodwsgi' on Windows. They only work on Unix type systems.
>
> So how can I configure my django app?
Once you have added in the output of 'module-config', then configure Apache as
described in Django documentation. Just be aware that you can't use daemon mode
on Windows.
https://docs.djangoproject.com/en/2.1/howto/deployment/wsgi/modwsgi/
>
> What Python version are you using? What version of MS C/C++ compiler? What
> distribution of Apache?
> Python: x64 v3.6
> VC: x64 15.6.4
> Apache: httpd-2.4.37-win64-VC15 (ApacheLounge)
>
> I suspected setup.py when it installed mod_wsgi because it usec x86_amd64
> instead of x64 for compilation. But thought the target would be c64 anyway.
> Thank you
> On Thursday, December 20, 2018 at 9:37:03 AM UTC+3:30, Graham Dumpleton wrote:
>
>
>> On 20 Dec 2018, at 4:11 pm, Siavosh Kasravi <[email protected] <>> wrote:
>>
>> I have three related problems:
>>
>> In this page <https://pypi.org/project/mod_wsgi/> "mod_wsgi-express
>> module-config" gives a .so module to be used in Apache conf. But when I ran
>> it in Windows it gave me a .pyd. Is it normal?
>
> Yes it is normal. Windows will use a .pyd or .pyo extension and not .so.
>
>> ("mod_wsgi-express install-module" noted in the same page doesn't work at
>> all!)
>
> What exact command are you running and what error do you get.
>
>>
>> Another issue is running "python manage.py runmodwsgi" in Windows fails
>> because script tries to call os.getuid, which is not available in Windows.
>
> You can't use 'mod_wsgi-express start-server' or 'python manage.py
> runmodwsgi' on Windows. They only work on Unix type systems.
>
>> Currently server stops functioning correctly when loads .pyd module.
>
> A failure of Apache to start up usually means, one of the following.
>
> * You aren't using the same compiler as the Python version was compiled with.
> See:
>
> https://wiki.python.org/moin/WindowsCompilers
> <https://www.google.com/url?q=https%3A%2F%2Fwiki.python.org%2Fmoin%2FWindowsCompilers&sa=D&sntz=1&usg=AFQjCNHx91mD8iBLYRVivOaLgI5AASATcg>
>
> for the correct compiler you should be used.
>
> * You aren't using all 64 bit for Apache, Python and the compiler. You can't
> mix 32 bit and 64 bit. Don't recommend using 32 bit at all.
>
> * You are trying to use Python 2.7. Give up on that. It is impossible to find
> Apache which is compiled with the old compiler that Python 2.7 requires. If
> you mix Python/Apache C compiler runs times, eg VC9 and VC14, it usually
> doesn't work.
>
> * You aren't using ApacheLounge distribution of Apache. Some of the other
> distributions of Apache just don't work, although usually you can't even get
> things to compile.
>
> Having said all that. What Python version are you using? What version of MS
> C/C++ compiler? What distribution of Apache?
>
> Graham
>
> --
> You received this message because you are subscribed to the Google Groups
> "modwsgi" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected]
> <mailto:[email protected]>.
> To post to this group, send email to [email protected]
> <mailto:[email protected]>.
> Visit this group at https://groups.google.com/group/modwsgi
> <https://groups.google.com/group/modwsgi>.
> For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>.
--
You received this message because you are subscribed to the Google Groups
"modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/modwsgi.
For more options, visit https://groups.google.com/d/optout.