By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
439,931 Members | 2,015 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 439,931 IT Pros & Developers. It's quick & easy.

turbogears app deployment

P: n/a
I am trying to host a TuboGears app using Apache and mod_python on a
machine running Windows XP SP2 Professional.

Version info: apache_2.2.3-win32-x86-no_ssl.msi, python-2.4.4.msi,
mod_python-3.2.10.win32-py2.4-apache2.2.exe, mpcp-1.5.tar.gz,

================================================== =======
1. Installed Apache.

2. Installed python, turbogears, mod_python.
Added LoadModule python_module modules/
to conf\httpd.conf. The mod_python example is working.

3. In order to host a simple TG application, I am using the bookmarker
application which is in the TurboGears book (v1 from Chap 4).
That works when I run it locally on my machine (also a WinXP SP2 box).
Copied the application to "C:\Program Files\Apache Software

4. Made the following changes to conf\httpd.conf
Changed AllowOverride for .htaccess to: AllowOverride All

5. Renamed start file to Created a file called
..htaccess in bookmarker directory which has the following

SetHandler mod_python
PythonHandler mpcp
PythonDebug On
PythonOption cherrysetup bookmarker_start::mp_setup

6. Copied to the bookmarker directory (tried with installing it
using easy_install -Z mpcp, didn't help).

7. Changed

#turbogears.start_server(Root()) <----------- commented this line and
added the lines below.

def mp_setup():

if __name__ == "__main__":
================================================== =======

I have restarted the Apache daemon multiple times. When I try to connect
to http://machine/bookmarker, I get:

Mod_python error: "PythonHandler mpcp"

Traceback (most recent call last):

File "C:\Python24\Lib\site-packages\mod_python\", line 299,
in HandlerDispatch
result = object(req)
File "C:/Program Files/Apache Software
Foundation/Apache2.2/htdocs/bookmarker/", line 38, in handler
setup(req, options)
File "C:/Program Files/Apache Software
Foundation/Apache2.2/htdocs/bookmarker/", line 22, in setup
cherrypy.server.start(init_only=True, server_class=None)
line 72, in start
line 91, in start
autoreload.main(self._start, freq=freq)
line 63, in main

SystemExit: 1

Any idea what the problem is? Thanks for your help.
Dec 24 '06 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.