|
InstallationOnWindows
Installation of mod_wsgi on Windows.
Installation On WindowsThe mod_wsgi source code package doesn't yet contain scripts for building on Windows as yet. Scripts will likely be packaged with mod_wsgi version 3.0. In the interim, some binaries are being supplied on this site for Python 2.6, with binaries for older versions of Python being supplied by third parties. Precompiled BinariesVariations of precompiled binaries currently available are as follows. You need to make sure you select the correct one for the version of Python and Apache that is being used: Thanks to Adal Chiriliuc for making versions for older versions of Python available. If you can't find the specific version you need listed above, try browsing Adal's site directly: http://adal.chiriliuc.com/mod_wsgi/ Module InstallationThe appropriate mod_wsgi.so file for the version of Python and Apache being used should be copied into the Apache modules directory. For Apache 2.2, this would typically be directory: /Program Files/Apache Software Foundation/Apache22/modules Ensure first that this is actually the location where Apache has been installed in case it is different for your platform. Also ensure that the file when installed has access permissions such that the user that the Apache service runs as will be able to read it. To configure Apache to make use of mod_wsgi, follow the instructions for loading mod_wsgi in the Quick Installation Guide. Also refer to the Quick Configuration Guide and Configuration Guidelines. Note that the binaries from this site aren't actually called 'mod_wsgi.so'. You should rename the file to 'mod_wsgi.so' when it is placed into the Apache modules directory, or modify as appropriate the LoadModule line you add to the Apache configuration file to refer to its actual name. Also, the binaries from this site will have been compiled against the latest version of Apache available at the time. If you are using an older patch revision of Apache, it is possible that you may have problems. Ensure therefore that you always update to latest version of Apache. Python RequirementsWhen Python was being installed, it is preferable that it was installed as an Administrator and it made avaiable to all users. By installing it as an Administrator, it will ensure that the required C library DLL is installed into the Windows system folder and will be able to be found by Apache when it is being run as a service. Running installation of Python as the Administrator and making it available to all users also ensures that Windows registry entries related to Python are configured for the entire machine and not just the user that installed Python. If you have multiple versions of Python installed on your system, you must ensure that the first one found when the application PATH is searched is the version you wish to use. If this isn't the case, Python may not find the correct directories from which to load the site initialisation file and any Python modules. Note that although the precompiled mod_wsgi modules may not have been compiled with the exact same patch level version of Python as you are running, and as a result you may see a warning in the Apache error log files about a version mismatch, this warning can be ignored. You should only be concerned where the major/minor versions of Python differ, in which case you should install the correct version of the precompiled mod_wsgi module binary. |