moinmoin and litespeed fastcgi

#1
Hi,

I'm trying to get moinmoin set up with litespeed fastcgi.

In the litespeed admin console, I added a fastcgi external
app pointed at moinmoin's moin.fcg, and an associated
context, basically following the instructions from
http://www.litespeedtech.com/support/wiki/doku.php?id=litespeed_wiki:python_fcgi

After restarting litespeed, I get "500 Internal Server
Error" when I attempt to access moinmoin. Looking at the
litespeed logs, I see messages like

[127.0.0.1:45439-0#www.example.com] Handler with type id [8202896] is not implemented.

I don't see anything in error_lsws.log, or anything
interesting in access_lsws.log.

Looking at the process list, it appears that moin.fcg isn't
getting started (or dies immediately).

I appreciate any suggestions.

Thanks much,
David
 
#3
Still digging ...

Got the idea from another thread of wrapping the fcgi script in a shell script
like this

Code:
#!/bin/bash
strace -o strace.log ./demoapp.py
When I hit the web page, no strace.log gets created.

In fact, as far as I can see, the UDS socket file isn't being created. Unless it gets created and disappears before I can catch it.
 
#6
Hi mistwang,

Here's the FastCGI App Definition:
Name lspyfcgidemo
Address UDS://home/montgomery/webapps/moinmoin158/demo.sock
Max Connections 10
Environment Not Set
Initial Request Timeout (secs) 60
Retry Timeout (secs) 0
Persistent Connection Yes
Connection Keepalive Timeout 30
Response Buffering No
Auto Start Yes
Command /home/montgomery/webapps/moinmoin158/strace_demoapp.sh
Back Log 50
Instances 10
Run On Start Up Not Set
Max Idle Time Not Set
Priority Not Set
Memory Soft Limit (bytes) Not Set
Memory Hard Limit (bytes) Not Set
Process Soft Limit Not Set
Process Hard Limit Not Set

(Address was originally "uds://tmp/lshttpd/mypythonfcgi.sock",
and Command was originally "/home/montgomery/webapps/moinmoin158/demoapp.py")

Here's the FCGI Context Definition:
URI /demo/
Fast CGI App [VHost Level]: lspyfcgidemo
Notes Not Set
Extra Headers Not Set
Allow Override Not Set
Realm Not Set
Authentication Name Not Set
Required Not Set
Access Allowed Not Set
Access Denied Not Set
Authorizer Not Set
Add Default Charset Off
Customized Default Charset Not Set
Enable IP GeoLocation Not Set

> What is your OS? Which version LSWS is used?

I know that it's redhat -- I don't know which version.
The LSWS version is 3.2. This is a new site I'm setting up
at WebFaction.

David
 
#7
Update: iaihmb sent me a video showing how to set up moinmoin with litespeed at WebFaction. I haven't gone through the steps myself, yet (I need an account upgrade first), but it looks pretty straightforward.

The main difference is that solution he shows has moinmoin listening on a specified port (like the moinmoin fastcgi directions for Windows or lighttpd), rather than connecting over a uds socket.

David
 

mistwang

LiteSpeed Staff
#8
Please make sure your python script can be started successfully from command.

The jon.fcgi package might be outdated, I failed to run it with Python2.5, maybe you should try the fcgi module in flup package.

It should not matter that TCP socket or Unix socket was used.
 
Top