fastcgi

PHP5.3 with FastCGI caching problem accross different requests

I have designed a stylesheet/javascript files bundler and minifier that uses a simple cache mechanism. It simply writes into a file the timestamp of each bundled files and compares those timestamps to prevent rewriting the "master file" again. That way, after an application update (here my website), where CSS or JS files were modified, a...

connect time from NGINX to PHP via FastCGI

Hi, here's a six core with 32GB ram. I've nginx 0.7.X and php5-fpm with php5.3 (from dotdeb.org). Important config files: nginx.conf user www-data; worker_processes 2; events { worker_connections 4096; } location ~ \.php$ { fastcgi_pass unix:/tmp/fcgi.sock; fastcgi_index index.php; ...

WebSocket and CGI/FastCGI/SCGI protocols

Hello, I'm looking for resources about interaction between client side web socket, web server and real application backend that works behind CGI, FastCGI or SCGI protocols. It seems that this is impossible at this point as: Request length is specifically defined in CONTENT_LENGTH variable so I can't expect that the data would continue...

PHP Can't Connect to MS SQL Express 2008

Hi all, I'm struggling to connect to my MS SQL Express 2008 edition from my PHP files, but it seems virtually impossible. I've found several guides/notes on teh intarweb solving the issues, but none of these have helped me any further. I've taken a script from another site and entered my database information, but I still get errors: ...

Seeing what gets written to stderr in Python web site using FastCGI

I am working on a website, hosted on DreamHost, using Python. For a while, I was using their default setup, which runs Python scripts using CGI. It worked fine, but I was worried that if I get a lot of traffic, it would run slow and use a lot of memory, so I switched it over to FastCGI using this module. Overall, it still works fine, bu...

PHP _SERVER["USER"] and _SERVER["HOME"]

I run PHP via FastCGI with nginx web server on Gentoo. PHP is started by spawn-fcgi script from lighttpd, which is started run as a daemon using start-stop-daemon. Among other things, startup scripts cleans-up environment, so that only PATH, PHP_FCGI_CHILDREN and PHP_FCGI_MAX_REQUESTS are left when PHP is started. However on my machine, ...

Can't create wildcard mapping for Ruby on IIS7.5

I'm following the steps to run Ruby on Rails on IIS here: http://mvolo.com/blogs/serverside/archive/2007/02/18/10-steps-to-get-Ruby-on-Rails-running-on-Windows-with-IIS-FastCGI.aspx I'm running on Windows 7 64-bit (which I think is IIS7.5) and verified that CGI was already installed. But when I got to step 9, creating the wildcard mappi...

Deploying django under a sub-URL with Nginx/Fastcgi

I can't for the life of me figure out how to deploy a django site under a non-root location with Nginx/fastcgi, e.g. http://localhost:8080/myproject/ instead of http://localhost:8080/; all the examples I have seen either assume Apache or mounting at the root of the site. Here's the relevant part of my nginx.conf: server { listen 808...

"child exited with status 13" when trying to run fastcgi examples with lighttpd

Hi all, I have compiled fastcgi c-api examples: http://www.fastcgi.com/devkit/examples/ They work fine when I execute them manually in the command line (by typing ./echo for example) but I have some troubles when I try to make it work with lighttpd. "/echo.fcgi" => ( "localhost" => ( "socket" ...

FastCGI, Apache, Django and 500 Error

I am getting 500 Internal error with Apache and FastCGI. Spent the whole day to find the reason :-/ /etc/apache2/vhost.d/mysite.conf FastCGIExternalServer /home/me/web/mysite.fcgi -socket /home/me/web/mysite.sock Listen 80 <VirtualHost *:80> ServerName os.me #That's my localhost machine DocumentRoot /home/me/web ...

Socket permissions when running Django with FastCGI

I am running Django fcgi with standard line: exec setuidgid $USERID $VENVBIN/python $WEBAPP/manage.py runfcgi daemonize=false socket=$FCGISOCKET Problem is that only group is shared between fastcgi process and webserver, not user - however group do not have write permissions by default (hotfix is running chmod g+w manually). How to f...

URL issue when using lighttpd, django and fastcgi

I just set up fastcgi with lighty for django, but I'm getting the fcgi file path when it processes the url, e.g. 404 error at http://myserver.myhost.com/myproject.fcgi. It needs to route to / instead of /myproject.fcgi. Lighty conf: $HTTP["host"] =~ "myproject\.myhost\.com" { fastcgi.server = ( ".fcgi" => ( ...

How to reload the configuration in catalyst

How to reload the configuration when ever the configuration changed in catalyst web framework and need to reload the configuration with out restarting the catalyst server. ...

How to configure FastCGI on IIS 6 to load Perl modules correctly

I've achieved several partial successes, but can't cross the last hurdle. Symptom: When in test mode FastCGI performs perfectly. When running plain perl scripts in eval or do mode it performs perfectly. As soon as I attempt to access the FCGI::Request() object or the CGI::Fast->new object, it hangs indefinitely. Here's my config: [Typ...

Login as www-data on Debian

I have a Debian Lenny server running Apache 2.2. I run PHP using Apache's fcgi mod. PHP runs as user www-data (the default) because it's what Apache runs as and there is only one site on the server so I don't see any reason (feel free to correct me) to have the FastCGI instance run as a different user. I chown the ownership of all my PH...

When executing Perl with FastCGI wrapper in nginx, do I actually get a speed benefit?

Hi, I'm using nginx with this script as FastCGI wrapper, that I start with: spawn-fcgi -F 3 -u www-data -s /var/run/perl-fcgi.sock -P /var/run/perl-fcgi.pid -- ./perl-fcgi.pl Now, suppose I have a simple script: #!/usr/bin/perl print "Content-type: text/plain\r\n\r\n"; print "hello\n"; The script runs fine, and I see the "hello" w...

Web gateway interfaces in Python 3.

I've finally concluded that I can no longer afford to just hope the ongoing Py3k/WSGI disasterissues will be resolved anytime soon, so I need to get ready to move on. Unfortunately, my available options don't seem a whole lot better: While I find a few different Python modules for FastCGI scattered around the web, none of them seem to...

rails 3 - fcgi_handler and dispatcher missing

Im trying to update a 1&1 server to run rails 3 with apache and fastcgi. Has anyone done this yet? I the dispatch.fcgi file I have: require 'fcgi_handler' but apparently rails 3 does not have this file any more. ...

Long delays and messed up AJAX responses when running Pylons app via Apache

I have a Pylons app that I'm trying to set up using Apache and FCGI. The Pylons INI file has this in it: [server:main] use = egg:Flup#fcgi_thread host = 0.0.0.0 port = 40100 This used to work on an old CentOS server with Pylons 0.9.7, but now I'm trying to set it up on a new one, running Ubuntu 10.04 and Pylons 1.0. I can connect to t...

Why does lighttpd mod_fastcgi start a listening socket?

I read in lighttpd 1.4.19 source codes, now I got stuck at the function fcgi_spawn_connection, if (-1 == connect(fcgi_fd, fcgi_addr, servlen)) { ... bind(fcgi_fd, fcgi_addr, servlen) ... listen(fcgi_fd, 1024) } The question is, why does mod_fastcgi create a listening socket, what's it use for? Isn't that mod_fastcgi works as clie...