[Zope] Re: Zope pcgi broken ???

David Elkins elkinsd@hurrah.com
Tue, 18 Jul 2000 10:22:06 -0700 (PDT)


On Tue, 18 Jul 2000, Michael Arndt wrote:
> No such file or directory
> 
> PCGI Error:
> 
> (102) failure during connect to ZServer
> 
> Explanation:
> 
> The PCGI-wrapper program, spawned by Apache to handle the HTTP request
> via the standard CGI protocol, is unable to
> connect to the ZServer background process via Unix socket
> /soft/swtest.rw.root/zope/rel2.2stable/Zope-2.2.0-src/var/pcgi.soc.
> and
> Mon Jul 17 17:16:32 2000
>   pcgi-wrapper(/usr/freeware/apache/share/cgi-bin/Zope.cgi): No such
> file or directory  (102) failure during connect to ZServer
> 
> where should i begin searching ?

Seems that the versions of pcgi from 2.1.6 to 2.2.0a1 and on are
"broken" on purpose ..

In pcgi/pcgi-wrapper.c, lines 246 to 282:

    /*
    // Attempt to connect 
    */
    if ((r->conn = pcgiConnect(r)) < 0)
    {       
        if (!r->errmsg[0])
        {   
            strcpy(r->errmsg, ERR102_FAILURE_DURING_CONNECT); 
            sprintf(r->explain, WHY102_FAILURE_DURING_CONNECT,
                r->sockpath); 
        }
        onError(E_503, strerror(errno), r);

/*
        if(pcgiVerifyProc(r) < 0)
        {   
            if(pcgiStartProc(r) < 0) 
            {   
                if (!r->errmsg[0])
                    strcpy(r->errmsg, ERR101_FAILURE_DURING_START); 
                onError(E_500, "Failed to start resource", r);
            }
            if ((r->conn=pcgiConnect(r)) < 0)
            {   
                if (!r->errmsg[0])
                    strcpy(r->errmsg, ERR102_FAILURE_DURING_CONNECT); 
                onError(E_503, strerror(errno), r);
            }
        }  
        else    
        {
            if (!r->errmsg[0])
                strcpy(r->errmsg, ERR103_UNABLE_VERIFY_RUNNING);
            onError(E_503, "pcgiVerifyProc failed", r);
        }
*/
    }

But you're fix works around this problem nicely.


David