Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8229887
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T16:57:05+00:00 2026-06-07T16:57:05+00:00

I was able to compile mod_wsgi for Python 2.5.4. It is now loaded into

  • 0

I was able to compile mod_wsgi for Python 2.5.4. It is now loaded into apache modules. I confirmed it by command

httpd.exe -M
.
.
wsgi_module(shared)
php5_module(shared)

But I am unable to run a test file(hello.wsgi), it is located in folder c:/apache/htdocs/wsgi : so the path of file becomes c:/apache/htdocs/wsgi/hello.wsgi

My hello.wsgi file contains:

def application(environ, start_response):
    status = '200 OK'
    output = 'Hello World!'

    response_headers = [('Content-type', 'text/plain'),
                        ('Content-Length', str(len(output)))]
    start_response(status, response_headers)

    return [output]

I added the following lines to httpd.conf:

LoadModule wsgi_module modules/mod_wsgi.so

<IfModule wsgi_module>
    WSGIScriptAlias /wsgi/ "c:/apache/htdocs/wsgi/hello.wsgi"

    <Directory "c:/apache/htdocs/wsgi">
            Order deny,allow
            allow from All
    </Directory>
</IfModule>

And my Apache Error Log is :

[Sat Nov 19 15:29:32 2011] [warn] pid file C:/apache/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Sat Nov 19 15:29:32 2011] [warn] mod_wsgi: Compiled for Python/2.5.
[Sat Nov 19 15:29:32 2011] [warn] mod_wsgi: Runtime using Python/2.5.4.
[Sat Nov 19 15:29:33 2011] [notice] Apache/2.2.21 (Win32) mod_wsgi/3.3 Python/2.5.4 PHP/5.3.8 configured -- resuming normal operations
[Sat Nov 19 15:29:33 2011] [notice] Server built: Sep  9 2011 10:26:10
[Sat Nov 19 15:29:33 2011] [notice] Parent: Created child process 2296
[Sat Nov 19 15:29:33 2011] [warn] mod_wsgi: Compiled for Python/2.5.
[Sat Nov 19 15:29:33 2011] [warn] mod_wsgi: Runtime using Python/2.5.4.
[Sat Nov 19 15:29:33 2011] [notice] Child 2296: Child process is running
[Sat Nov 19 15:29:33 2011] [notice] Child 2296: Acquired the start mutex.
[Sat Nov 19 15:29:33 2011] [notice] Child 2296: Starting 64 worker threads.
[Sat Nov 19 15:29:33 2011] [notice] Child 2296: Starting thread to listen on port 80.
[Sat Nov 19 15:30:21 2011] [error] [client 127.0.0.1] File does not exist: C:/apache/htdocs/wsgi

Update

I removed the trailing slash from alias, i have moved my wsgi folder from htdocs to apache & created a vhost file:

<VirtualHost 127.0.0.1:80>
    <Directory "C:/apache/wsgi">
        Options FollowSymLinks Indexes
        AllowOverride All
        Order deny,allow
        allow from All
    </Directory>
    ServerName 127.0.0.1
    ServerAlias 127.0.0.1
    WSGIScriptAlias /wsgi "C:/apache/wsgi/hello.wsgi"
    DocumentRoot "C:/apache/wsgi"
    ErrorLog "C:/apache/logs/127.0.0.1.err"
    CustomLog "C:/apache/logs/127.0.0.1.log" combined
</VirtualHost>

But now my Apache is giving some windows error like:

Faulting application name: httpd.exe, version: 2.2.21.0, time stamp: 0x4e6a3015
Faulting module name: ntdll.dll, version: 6.1.7601.17514, time stamp: 0x4ce7ba58
Exception code: 0xc0000005
Fault offset: 0x00038da9
Faulting process id: 0xc4c
Faulting application start time: 0x01cca6c0f9ccd446
Faulting application path: C:\apache\bin\httpd.exe
Faulting module path: C:\Windows\SysWOW64\ntdll.dll
Report Id: 3ba0b9e0-12b4-11e1-b285-005056c00008

Need Some Help.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T16:57:06+00:00Added an answer on June 7, 2026 at 4:57 pm

    This sounds like the error that I had when the Visual C++ 2008 Redistributable (msvcr90.dll) was not installed on the system. But first, please check (with Dependency Walker) that httpd.exe and mod_wsgi.so are using exactly the same msvcr90.dll:

    • same name
    • same directory
    • same version
    • same timestamp

    If they are using different DLL names (e.g. msvcr90.dll and msvcr100.dll) then you must recompile both with the same compiler (e.g. Visual Studio 2008).

    If they are using the same DLL name, but different versions or in different directories, then you might be having the same problem that I had, with BitNami DjangoStack.

    Because msvcr90.dll was not installed system-wide in C:\Windows\WinSxS, httpd was only able to run at all because there was an “xcopy deployment” of the side-by-side assembly in the same directory as httpd.exe:

    • Microsoft.VC90.CRT.manifest
    • msvcr90.dll

    If these files had not been present, it would have failed due to a missing dependency on msvcr90.dll, or else with this error:

    This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem.

    (i.e. the DLL was found but without a manifest to make it valid).

    Although httpd.exe runs this way, it is not able to reliably load a DLL that also uses msvcr90.dll:

    • If the DLL has an “xcopy deployment” in its OWN directory, then it will load another copy of the DLL into the process (because it’s a different copy of the DLL?). This results in a second heap in the process memory space, which can crash the process if memory is passed between the DLL and httpd (allocated by one and freed by the other). I think this is what you’re seeing.
    • If the DLL does not have an “xcopy deployment” in its own directory, then it will fail to load with a SideBySide or Windows Error Reporting error in the System event log.

    You can see more about this kind of problem on Python bug 4120, although this is not a clear, complete and definitive explanation of the problem, and I have not been able to find one yet.

    The only reliable way I found to run this stack was to install the Visual C++ 2008 redistributable system-wide, which places a copy of msvcr90.dll in a subdirectory of C:\Windows\WinSxS along with a manifest to make it work.

    This should (I think) cause Windows to completely ignore the Microsoft.VC90.CRT.manifest and msvcr90.dll files in the application and DLL directories. Both should use the same DLL in C:\Windows\WinSxS, and it should only be loaded into the process once.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I was wondering if someone was able to compile Django based projects (into shared
I was finally able to compile libssh2, but now I keep seeing the EXC_BAD_ACCESS
I am not able to compile the following program because of cyclic dependency between
I have a long-standing application that I'm normally able to compile equally well from
Not able to store all binary data values into sqlite3 table using QT. For
I'd like to be able to compile a C/C++ library so that it runs
I'd like to be able to compile a C/C++ library so that it runs
I'd like to be able to compile an Android app on my desktop, upload
One user running Snow Leopard wasn't able to compile my code. After an hour
I'd like to be able to compile a ruby program to a java JAR

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.