Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-14 Thread Tomas Doran


On 13 Feb 2011, at 22:46, Mark Hughes wrote:

[info] sumo powered by Catalyst 5.80031
FastCGI: manager (pid 7003): initialized
FastCGI: server (pid 7004): initialized
FastCGI: manager (pid 7003): server (pid 7004) started



Ok, cool.

No errors are thrown to the log when sumo_fastcgi.pl is started from  
the command line.  The errors I copied, with the premature header  
etc., are logged when there's a request.


Perhaps there's a permission problem but, in an effort to figure  
this out, I have set everything at the site's root, web, to 777  
and everything in the scripts directory to 777, too.


Start apache with one child using strace -f

Watch what's actually crapping out?

Cheers
t0m


___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-14 Thread Mark Hughes

On 02/14/2011 01:49 AM, Tomas Doran wrote:


Perhaps there's a permission problem but, in an effort to figure this
out, I have set everything at the site's root, web, to 777 and
everything in the scripts directory to 777, too.


Start apache with one child using strace -f

Watch what's actually crapping out?


Wow.  First time I've ever done that.  Interesting to see how @INC gets 
walked.


This looked suspicious to me:

3969  stat64(/tmp/sumo, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
3969  stat64(/tmp/sumo/session_data, {st_mode=S_IFREG|0640, 
st_size=5832704, ...}) = 0
3969  stat64(/tmp/sumo/session_data, {st_mode=S_IFREG|0640, 
st_size=5832704, ...}) = 0
3969  stat64(/tmp/sumo/session_data, {st_mode=S_IFREG|0640, 
st_size=5832704, ...}) = 0



3969  open(/tmp/sumo/session_data, O_RDWR|O_LARGEFILE) = -1 EACCES 
(Permission denied)



3969  write(2, Couldn't load class (Sumo) becau..., 1375) = 1375

From here, what happens looks connected with logging an access event.

Here are the /tmp/sumo/session_data permissions:

[root@mayfly sumo]# pwd
/tmp/sumo
[root@mayfly sumo]# ls -l
total 5708
-rw-r- 1 root root 5832704 Feb 12 18:10 session_data
[root@mayfly sumo]#

A permission problem with writing to the /tmp/sumo directory makes sense 
of the fact that the standalone server works but apache doesn't. 
Perhaps because I run the standalone server (and myapp_fastcgi.pl) from 
the command line as root and apache runs them as some other user?  I 
wonder which is trying to write and where the system expects to write 
temp files?


If you know a way to figure it out from here, I'd be grateful, but at 
least I have a promising new path -- I do, don't I?


Thanks!

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-14 Thread Nigel Metheringham
I'd suggest deleting that /tmp/sumo entirely and letting it recreate.

Its probably not really a good idea to have it in /tmp shareable by
different uids either, but to try and get stuff running I'd just zilch
it for now and then work on analysing how it should be done :-)

Nigel.
--
[ Nigel Metheringham nigel.methering...@intechnology.com ]
[ - Comments in this message are my own and not ITO opinion/policy - ]





___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-14 Thread Steve
You could try deleting the whole session file and directory and see if 
that works.  It will get re-created when you fire up the server.  Crude, 
but I've run into this one before and it works.  Assuming of course that 
you don't have users logged in!


Steve
On 2/14/2011 8:31 AM, Mark Hughes wrote:

On 02/14/2011 01:49 AM, Tomas Doran wrote:


Perhaps there's a permission problem but, in an effort to figure this
out, I have set everything at the site's root, web, to 777 and
everything in the scripts directory to 777, too.


Start apache with one child using strace -f

Watch what's actually crapping out?


Wow.  First time I've ever done that.  Interesting to see how @INC 
gets walked.


This looked suspicious to me:

3969  stat64(/tmp/sumo, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
3969  stat64(/tmp/sumo/session_data, {st_mode=S_IFREG|0640, 
st_size=5832704, ...}) = 0
3969  stat64(/tmp/sumo/session_data, {st_mode=S_IFREG|0640, 
st_size=5832704, ...}) = 0
3969  stat64(/tmp/sumo/session_data, {st_mode=S_IFREG|0640, 
st_size=5832704, ...}) = 0



3969  open(/tmp/sumo/session_data, O_RDWR|O_LARGEFILE) = -1 EACCES 
(Permission denied)



3969  write(2, Couldn't load class (Sumo) becau..., 1375) = 1375

From here, what happens looks connected with logging an access event.

Here are the /tmp/sumo/session_data permissions:

[root@mayfly sumo]# pwd
/tmp/sumo
[root@mayfly sumo]# ls -l
total 5708
-rw-r- 1 root root 5832704 Feb 12 18:10 session_data
[root@mayfly sumo]#

A permission problem with writing to the /tmp/sumo directory makes 
sense of the fact that the standalone server works but apache doesn't. 
Perhaps because I run the standalone server (and myapp_fastcgi.pl) 
from the command line as root and apache runs them as some other 
user?  I wonder which is trying to write and where the system expects 
to write temp files?


If you know a way to figure it out from here, I'd be grateful, but at 
least I have a promising new path -- I do, don't I?


Thanks!

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: 
http://www.mail-archive.com/catalyst@lists.scsys.co.uk/

Dev site: http://dev.catalyst.perl.org/




___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-14 Thread Mark Hughes

On 02/14/2011 06:42 AM, Nigel Metheringham wrote:

I'd suggest deleting that /tmp/sumo entirely and letting it recreate.

Its probably not really a good idea to have it in /tmp shareable by
different uids either, but to try and get stuff running I'd just zilch
it for now and then work on analysing how it should be done :-)


I deleted sumo/ and sumo/session_file.  And it worked!  I cannot believe 
it.  Well, I can but . . . I can't believe it was such a simple thing. 
(Isn't one's first bug often a permission problem?!)


Here are the new permissions when the file was recreated:

-rw-r- 1 apache apache 5832704 Feb 14 07:30 session_data

Same for /tmp/sumo.

I'm guessing that when I ran the standalone server, which seemed a 
sensible first step in deploying this thing, it created the /tmp/sumo 
directory and session file.  And then, apache couldn't change it.  I 
never thought to look there and never would have if t0m had not 
suggested looking at apache's strace.


BTW, I think the location of the session_file is chosen by the perl 
module, not by me, but point taken.


Thanks everyone!  I feel relieved and like a dope.  And a bit wiser.

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Mark Hughes

I should have added that this is a sample of my error.log:

[root@mayfly log]# cat error.log
[Sun Feb 13 11:29:45 2011] [warn] (104)Connection reset by peer: 
mod_fcgid: read data from fastcgi server error.
[Sun Feb 13 11:29:45 2011] [error] [client 192.168.123.102] Premature 
end of script headers: sumo_fastcgi.pl
[Sun Feb 13 11:29:50 2011] [warn] (104)Connection reset by peer: 
mod_fcgid: read data from fastcgi server error.
[Sun Feb 13 11:29:50 2011] [error] [client 192.168.123.102] Premature 
end of script headers: sumo_fastcgi.pl
[Sun Feb 13 11:33:11 2011] [warn] (104)Connection reset by peer: 
mod_fcgid: read data from fastcgi server error.
[Sun Feb 13 11:33:11 2011] [error] [client 192.168.123.102] Premature 
end of script headers: sumo_fastcgi.pl
[Sun Feb 13 11:33:15 2011] [warn] (104)Connection reset by peer: 
mod_fcgid: read data from fastcgi server error.
[Sun Feb 13 11:33:15 2011] [error] [client 192.168.123.102] Premature 
end of script headers: sumo_fastcgi.pl


This is when using the hjksolutions setup linked in my original message.

Thanks.


On 02/13/2011 11:24 AM, Mark Hughes wrote:

I am trying to work through deployng a Catalyst app on an apache2 server
with mod_fcgi installed. I don't know what I am doing, and I have spent
an embarrassingly long time accomplishing nothing.

The app runs okay when I run the standalone myapp_server.pl on the
server. Requests from sitename:3000 generate charming debug messages and
pages appear in the browser -- just as when I run the app locally.

The trouble is that I cannot get myapp_fastcgi.pl to serve pages. When I
try to use myapp_fastcgi.pl, the standard debug status messages appear,
followed by this:

[info] sumo powered by Catalyst 5.80031
FastCGI: manager (pid 14119): initialized
FastCGI: manager (pid 14119): server (pid 14120) started
FastCGI: server (pid 14120): initialized

Seems fine. But requests result only in 404 errors.

I am stumped and out of things to try.

I have looked at a large number of pages on deploying Catalyst apps,
including the wiki, advent calendar (several days),
Catalyst::Engine::FastCGI docs (all three modes), and tried most of
them. The only thing I have really discovered is that most of the
instructions seem to be for mod_fastcgi rather than mod_fcgi. And most
of what I have found and tried prevent apache from starting. (I think
because mod_fcgi breaks on ExternalServer directives.)

The most promising, because it deals specifically with mod_fcgid, might
be
http://blog.hjksolutions.com/articles/2007/07/19/catalyst-deployment-with-apache-2-and-mod_fcgid
but I don't understand even the basics of how it works. It doesn't seem
to tell anything to listen anywhere, and I don't know how to
successfully start myapp_fastcgi.pl without telling it to listen someplace.

Any suggestions would help. Thanks.

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/
.




___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Francisco Obispo
Is there a reason why you need it to be fast_cgi and not mod_perl ?




On Feb 13, 2011, at 10:38 AM, Mark Hughes wrote:

 I should have added that this is a sample of my error.log:
 
 [root@mayfly log]# cat error.log
 [Sun Feb 13 11:29:45 2011] [warn] (104)Connection reset by peer: mod_fcgid: 
 read data from fastcgi server error.
 [Sun Feb 13 11:29:45 2011] [error] [client 192.168.123.102] Premature end of 
 script headers: sumo_fastcgi.pl
 [Sun Feb 13 11:29:50 2011] [warn] (104)Connection reset by peer: mod_fcgid: 
 read data from fastcgi server error.
 [Sun Feb 13 11:29:50 2011] [error] [client 192.168.123.102] Premature end of 
 script headers: sumo_fastcgi.pl
 [Sun Feb 13 11:33:11 2011] [warn] (104)Connection reset by peer: mod_fcgid: 
 read data from fastcgi server error.
 [Sun Feb 13 11:33:11 2011] [error] [client 192.168.123.102] Premature end of 
 script headers: sumo_fastcgi.pl
 [Sun Feb 13 11:33:15 2011] [warn] (104)Connection reset by peer: mod_fcgid: 
 read data from fastcgi server error.
 [Sun Feb 13 11:33:15 2011] [error] [client 192.168.123.102] Premature end of 
 script headers: sumo_fastcgi.pl
 
 This is when using the hjksolutions setup linked in my original message.
 
 Thanks.
 
 
 On 02/13/2011 11:24 AM, Mark Hughes wrote:
 I am trying to work through deployng a Catalyst app on an apache2 server
 with mod_fcgi installed. I don't know what I am doing, and I have spent
 an embarrassingly long time accomplishing nothing.
 
 The app runs okay when I run the standalone myapp_server.pl on the
 server. Requests from sitename:3000 generate charming debug messages and
 pages appear in the browser -- just as when I run the app locally.
 
 The trouble is that I cannot get myapp_fastcgi.pl to serve pages. When I
 try to use myapp_fastcgi.pl, the standard debug status messages appear,
 followed by this:
 
 [info] sumo powered by Catalyst 5.80031
 FastCGI: manager (pid 14119): initialized
 FastCGI: manager (pid 14119): server (pid 14120) started
 FastCGI: server (pid 14120): initialized
 
 Seems fine. But requests result only in 404 errors.
 
 I am stumped and out of things to try.
 
 I have looked at a large number of pages on deploying Catalyst apps,
 including the wiki, advent calendar (several days),
 Catalyst::Engine::FastCGI docs (all three modes), and tried most of
 them. The only thing I have really discovered is that most of the
 instructions seem to be for mod_fastcgi rather than mod_fcgi. And most
 of what I have found and tried prevent apache from starting. (I think
 because mod_fcgi breaks on ExternalServer directives.)
 
 The most promising, because it deals specifically with mod_fcgid, might
 be
 http://blog.hjksolutions.com/articles/2007/07/19/catalyst-deployment-with-apache-2-and-mod_fcgid
 but I don't understand even the basics of how it works. It doesn't seem
 to tell anything to listen anywhere, and I don't know how to
 successfully start myapp_fastcgi.pl without telling it to listen someplace.
 
 Any suggestions would help. Thanks.
 
 ___
 List: Catalyst@lists.scsys.co.uk
 Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
 Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
 Dev site: http://dev.catalyst.perl.org/
 .
 
 
 
 ___
 List: Catalyst@lists.scsys.co.uk
 Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
 Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
 Dev site: http://dev.catalyst.perl.org/

Francisco Obispo 
Hosted@ Programme Manager
email: fobi...@isc.org
Phone: +1 650 423 1374 || INOC-DBA *3557* NOC
Key fingerprint = 532F 84EB 06B4 3806 D5FA  09C6 463E 614E B38D B1BE





___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Lyle

On 13/02/2011 18:24, Mark Hughes wrote:

(I think because mod_fcgi breaks on ExternalServer directives.)


mod_fcgid has different directives to mod_fastcgi. When looking at 
documentation this can often lead to confusion and a mismatch of the 
different directives. The directives you should be using are here:

http://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html

Have you managed to get a simple hello world script to run under FastCGI?


Lyle


___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Mark Hughes

On 02/13/2011 11:46 AM, Francisco Obispo wrote:

Is there a reason why you need it to be fast_cgi and not mod_perl ?



This app is ultimately supposed to go onto a shared server.  mod_perl is 
not part of the standard setup.  I also read that when using mod_perl 
code changes required a restart of apache.


___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Aaron Dancygier
Can you post your Apache config.

--Aaron

On Sun, 13 Feb 2011 11:38:08 -0700, Mark Hughes mhug...@law.du.edu
wrote:
 I should have added that this is a sample of my error.log:
 
 [root@mayfly log]# cat error.log
 [Sun Feb 13 11:29:45 2011] [warn] (104)Connection reset by peer: 
 mod_fcgid: read data from fastcgi server error.
 [Sun Feb 13 11:29:45 2011] [error] [client 192.168.123.102] Premature 
 end of script headers: sumo_fastcgi.pl
 [Sun Feb 13 11:29:50 2011] [warn] (104)Connection reset by peer: 
 mod_fcgid: read data from fastcgi server error.
 [Sun Feb 13 11:29:50 2011] [error] [client 192.168.123.102] Premature 
 end of script headers: sumo_fastcgi.pl
 [Sun Feb 13 11:33:11 2011] [warn] (104)Connection reset by peer: 
 mod_fcgid: read data from fastcgi server error.
 [Sun Feb 13 11:33:11 2011] [error] [client 192.168.123.102] Premature 
 end of script headers: sumo_fastcgi.pl
 [Sun Feb 13 11:33:15 2011] [warn] (104)Connection reset by peer: 
 mod_fcgid: read data from fastcgi server error.
 [Sun Feb 13 11:33:15 2011] [error] [client 192.168.123.102] Premature 
 end of script headers: sumo_fastcgi.pl
 
 This is when using the hjksolutions setup linked in my original message.
 
 Thanks.
 
 
 On 02/13/2011 11:24 AM, Mark Hughes wrote:
 I am trying to work through deployng a Catalyst app on an apache2
server
 with mod_fcgi installed. I don't know what I am doing, and I have spent
 an embarrassingly long time accomplishing nothing.

 The app runs okay when I run the standalone myapp_server.pl on the
 server. Requests from sitename:3000 generate charming debug messages
and
 pages appear in the browser -- just as when I run the app locally.

 The trouble is that I cannot get myapp_fastcgi.pl to serve pages. When
I
 try to use myapp_fastcgi.pl, the standard debug status messages appear,
 followed by this:

 [info] sumo powered by Catalyst 5.80031
 FastCGI: manager (pid 14119): initialized
 FastCGI: manager (pid 14119): server (pid 14120) started
 FastCGI: server (pid 14120): initialized

 Seems fine. But requests result only in 404 errors.

 I am stumped and out of things to try.

 I have looked at a large number of pages on deploying Catalyst apps,
 including the wiki, advent calendar (several days),
 Catalyst::Engine::FastCGI docs (all three modes), and tried most of
 them. The only thing I have really discovered is that most of the
 instructions seem to be for mod_fastcgi rather than mod_fcgi. And most
 of what I have found and tried prevent apache from starting. (I think
 because mod_fcgi breaks on ExternalServer directives.)

 The most promising, because it deals specifically with mod_fcgid, might
 be

http://blog.hjksolutions.com/articles/2007/07/19/catalyst-deployment-with-apache-2-and-mod_fcgid
 but I don't understand even the basics of how it works. It doesn't seem
 to tell anything to listen anywhere, and I don't know how to
 successfully start myapp_fastcgi.pl without telling it to listen
 someplace.

 Any suggestions would help. Thanks.

 ___
 List: Catalyst@lists.scsys.co.uk
 Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
 Searchable archive:
 http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
 Dev site: http://dev.catalyst.perl.org/
 .

 
 
 ___
 List: Catalyst@lists.scsys.co.uk
 Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
 Searchable archive:
http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
 Dev site: http://dev.catalyst.perl.org/

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Mark Hughes

On 02/13/2011 11:55 AM, Lyle wrote:

On 13/02/2011 18:24, Mark Hughes wrote:

(I think because mod_fcgi breaks on ExternalServer directives.)


mod_fcgid has different directives to mod_fastcgi. When looking at
documentation this can often lead to confusion and a mismatch of the
different directives. The directives you should be using are here:
http://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html


It took me, I am sorry to say, a few tries to learn this!


Have you managed to get a simple hello world script to run under FastCGI?


I ran the first perl example in the mod_fcgid docs (it's on the page you 
linked to) without a problem and without changing the standard virtual 
host directives.


___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Mark Hughes

On 02/13/2011 12:36 PM, Aaron Dancygier wrote:

Can you post your Apache config.

--Aaron


Here it is the most recent version of the relevant part.  Most is 
boilerplate generated by ISPConfig.  I've made the marked changes near 
the top and commented out the ScriptAlias directive part way down:


[root@mayfly ~]# cat  /etc/httpd/conf/sites-available/sumosrus.spirit.vhost

Directory /var/www/sumosrus.spirit
AllowOverride None
Order Deny,Allow
Deny from all
/Directory

VirtualHost *:80

# changes from here by mhughes per http://blog.hjksolutions.com
DocumentRoot /var/www/sumosrus.spirit/web/root
#DocumentRoot /var/www/sumosrus.spirit/web
Alias /static /var/www/sumosrus.spirit/web/root/static
Location /static
SetHandler default-handler
/Location

Alias / /var/www/sumosrus.spirit/web/script/sumo_fastcgi.pl/

Location /
 Options ExecCGI
 Order allow,deny
 Allow from all
 AddHandler fcgid-script .pl
/Location

# end changes

ServerName sumosrus.spirit
ServerAlias www.sumosrus.spirit
ServerAdmin webmaster@sumosrus.spirit

ErrorLog /var/log/ispconfig/httpd/sumosrus.spirit/error.log


ErrorDocument 400 /error/400.html
ErrorDocument 401 /error/401.html
ErrorDocument 403 /error/403.html
ErrorDocument 404 /error/404.html
ErrorDocument 405 /error/405.html
ErrorDocument 500 /error/500.html
ErrorDocument 503 /error/503.html

Directory /var/www/sumosrus.spirit/web
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all

# ssi enabled
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
Options +Includes
/Directory
Directory /var/www/clients/client3/web3/web
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all

# ssi enabled
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
Options +Includes
/Directory


# cgi enabled
Directory /var/www/clients/client3/web3/cgi-bin
  Order allow,deny
  Allow from all
/Directory
#ScriptAlias  /cgi-bin/ /var/www/clients/client3/web3/cgi-bin/
AddHandler cgi-script .cgi
AddHandler cgi-script .pl
# Clear PHP settings of this website
FilesMatch \.ph(p3?|tml)$
SetHandler None
/FilesMatch
# php as fast-cgi enabled
IfModule mod_fcgid.c

  # SocketPath /tmp/fcgid_sock/

  # IdleTimeout n (3600 seconds)
	  # An idle fastcgi application will be terminated after IdleTimeout 
seconds.

  IdleTimeout 3600

  # ProcessLifeTime n (7200 seconds)
  # A fastcgi application will be terminated if lifetime expired, 
even no error is detected.

  ProcessLifeTime 7200

  # MaxProcessCount n (1000)
  # The max count of total fastcgi process count.
  # MaxProcessCount 1000

  # DefaultMinClassProcessCount n (3)
  # The minimum number of fastcgi application instances for any one 
fastcgi application.

  # Idle fastcgi will not be killed if their count is less than n
  # Set this to 0, and tweak IdleTimeout
  DefaultMinClassProcessCount 0

  # DefaultMaxClassProcessCount n (100)
  # The maximum number of fastcgi application instances allowed to 
run for

  # particular one fastcgi application.
  DefaultMaxClassProcessCount 100

  # IPCConnectTimeout n (3 seconds)
  # The connect timeout to a fastcgi application.
  IPCConnectTimeout 8

  # IPCCommTimeout n (20 seconds)
  # The communication timeout to a fastcgi application. Please 
increase this

  # value if your CGI have a slow initialization or slow respond.
  IPCCommTimeout 360

  # BusyTimeout n (300 seconds)
  # A fastcgi application will be terminated if handing a single 
request

  # longer than busy timeout.
  BusyTimeout 300

/IfModule
Directory /var/www/sumosrus.spirit/web
AddHandler fcgid-script .php .php3 .php4 .php5
FCGIWrapper /var/www/php-fcgi-scripts/web3/.php-fcgi-starter .php
Options +ExecCGI
AllowOverride All
Order allow,deny
Allow from all
/Directory
Directory /var/www/clients/client3/web3/web
AddHandler fcgid-script .php .php3 .php4 .php5
FCGIWrapper /var/www/php-fcgi-scripts/web3/.php-fcgi-starter .php
Options +ExecCGI
AllowOverride All
Order allow,deny
Allow from all
/Directory

# add support for apache mpm_itk
IfModule mpm_itk_module
  AssignUserId web3 client3
/IfModule

IfModule mod_dav_fs.c
  # DO NOT REMOVE THE COMMENTS!
  # IF YOU REMOVE THEM, WEBDAV WILL NOT WORK ANYMORE!
  # WEBDAV BEGIN
  # WEBDAV END
/IfModule


/VirtualHost


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Tomas Doran


On 13 Feb 2011, at 18:46, Francisco Obispo wrote:


Is there a reason why you need it to be fast_cgi and not mod_perl ?




On Feb 13, 2011, at 10:38 AM, Mark Hughes wrote:


I should have added that this is a sample of my error.log:

[root@mayfly log]# cat error.log
[Sun Feb 13 11:29:45 2011] [warn] (104)Connection reset by peer:  
mod_fcgid: read data from fastcgi server error.
[Sun Feb 13 11:29:45 2011] [error] [client 192.168.123.102]  
Premature end of script headers: sumo_fastcgi.pl

[


Your web server isn't succeeding in running sumo_fastcgi.pl - either:
. You are missing some modules - did you actually install FCGI.pm etc?
. Your web server user can't see it due to file permissions
. If you installed Catalyst into a local:;lib, then your app won't get  
that environment when it's started...


So to start with, what happens when you run sumo_fastcgi.pl yourself,  
and are you deps in local::lib?


Cheers
t0m


___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Lyle

On 13/02/2011 19:51, Mark Hughes wrote:
AddHandler fcgid-script .pl 


You have this well before your fcgid config. Might have an effect, can't 
say for sure without testing.



Lyle

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Mark Hughes

On 02/13/2011 02:29 PM, Tomas Doran wrote:





On Feb 13, 2011, at 10:38 AM, Mark Hughes wrote:


I should have added that this is a sample of my error.log:

[root@mayfly log]# cat error.log
[Sun Feb 13 11:29:45 2011] [warn] (104)Connection reset by peer:
mod_fcgid: read data from fastcgi server error.
[Sun Feb 13 11:29:45 2011] [error] [client 192.168.123.102] Premature
end of script headers: sumo_fastcgi.pl
[


Your web server isn't succeeding in running sumo_fastcgi.pl - either:
. You are missing some modules - did you actually install FCGI.pm etc?
. Your web server user can't see it due to file permissions
. If you installed Catalyst into a local:;lib, then your app won't get
that environment when it's started...

So to start with, what happens when you run sumo_fastcgi.pl yourself,
and are you deps in local::lib?

Cheers
t0m


Easy part first.  There are no modules installed locally and no debug 
output from sumo_fastcgi.pl that indicates that anything is missing.
I don't know whether this is relevant to dependencies, but if I 
regenerate the scripts with catalyst.pl sumo --force, I can run 
Makefile.PL without a problem.  FCGI.pm is installed, and I believe it's 
working since I could run the mod_fcgi sample script without a problem 
(with the apache conf file in its original, boilerplate form.)


When I run:

/var/www/sumosrus.spirit/web/script/sumo_fastcgi.pl -e -l /tmp/sumo.socket

(The listen part, -l, is only there to make it run.  It's taken from an 
earlier try.  I don't know what the command should actually be and at 
this point, with fcgi, I don't know whether anything must be started.)


I get the standard debug info -- boxes with loaded actions, classes, 
etc. No errors.  Nothing unusual.  The last output lines are these:


[info] sumo powered by Catalyst 5.80031
FastCGI: manager (pid 7003): initialized
FastCGI: server (pid 7004): initialized
FastCGI: manager (pid 7003): server (pid 7004) started

No errors are thrown to the log when sumo_fastcgi.pl is started from the 
command line.  The errors I copied, with the premature header etc., are 
logged when there's a request.


Perhaps there's a permission problem but, in an effort to figure this 
out, I have set everything at the site's root, web, to 777 and 
everything in the scripts directory to 777, too.


Thanks.

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/


Re: [Catalyst] Help Deploying on mod-fcgi Rather than mod_fastcgi

2011-02-13 Thread Mark Hughes

On 02/13/2011 02:59 PM, Lyle wrote:

On 13/02/2011 19:51, Mark Hughes wrote:

AddHandler fcgid-script .pl


You have this well before your fcgid config. Might have an effect, can't
say for sure without testing.


I moved that whole location to after the fcgi config section, 
restarted everything, and tried again.  No luck.


Sounded reasonable, though.

___
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/