Welcome to the JaguarPC Community
JaguarPC
Sales: (888) 338-5261
Support: (888)-551-3050
Results 1 to 7 of 7

This is a discussion on Rails and FCGI in the Shared & Semi-Dedicated forum
I seem to be having several problems with FastCGI processes dying all the time (due to the dynamic FastCGI server). Seems to make the site ...

  1. #1
    JPC Member
    Join Date
    Jan 2006
    Posts
    6

    Rails and FCGI

    I seem to be having several problems with FastCGI processes dying all the time (due to the dynamic FastCGI server). Seems to make the site very slow or completely unresponsive while the processes start up.

    Is there anyway I can keep at least one process alive so that the site can at least handle a minimal number of requests as other FCGI processes start up?
    Last edited by mistryv; 03-07-2006 at 01:46 AM.

  2. #2
    Community Leader jason's Avatar
    Join Date
    Sep 2001
    Location
    Rochester, NY
    Posts
    6,003
    Are you on a shared server? If so, controlling FastCGI processes will be out of your control. This does sound like a pretty serious problem however (FastCGI is supposed to speed up your apps, after all), so you might want to bring it up in a support ticket. Then support can monitor the server to determine why the processes die prematurely. It is natural for dynamic applications to start new processes to handle load and to release them when they are no longer needed, but it seems as though at least one process should remain running to handle new requests.

    I'm not a FastCGI expert, so I am relying on logic and my experience with other, similar server processes.

    --Jason
    Jason Pitoniak
    Interbrite Communications
    www.interbrite.com www.kodiakskorner.com

  3. #3
    JPC Member
    Join Date
    Jan 2006
    Posts
    6
    Yes I am on a shared server. I know I cannot control my FCGI processes, but as you mentioned I expected that one process stay active even if no requests are coming in.

  4. #4
    the Windlord Gwaihir's Avatar
    Join Date
    Jun 2002
    Posts
    2,562
    That is at least the way Apache does it: keep a few not-yet used instances around at all times. Indeed, if FastCGI needs the same, it sounds like it is slightly misconfigured on your server => support ticket.
    Regards,

    Wim Heemskerk
    ---
    Visit MeCCG.net - Cardgaming in J.R.R. Tolkien's Middle-earth
    And Gwaihir.net - The Middle-earth CCG store

  5. #5
    JPC Member
    Join Date
    Jan 2006
    Posts
    6
    Hmm... I've reading up online on FastCGI and apparantly the dynamic FastCGI server does kill ALL processes after a certain period of idling. Well OK. Looks like I'll have to live with it.

    Maybe I'll set up a quick Cron job to pop requests at my application to keep one FCGI process alive.

    Thank you to both jason and Gwaihir for replying.

  6. #6
    || $name ne 'R.Stiltskin'
    Join Date
    Jun 2003
    Location
    Tejas
    Posts
    2,438
    Interesting, mistryv.

    I considered FCGI a couple of years ago, but the servers here didn't support it. Needless to say when I looked at server response headers after the recent server upgrades, I was pleased to see that mod_fcgi had been installed. Your recent post enticed me to try to port an application to fcgi since I'm always looking to speed up processes.

    I'm chiming in here to let you know that I did successfully port my app to an FCGI version and that a single instance continues to restart itself in times of inactivity. In fact, I can't turn the darn thing off, and I have a nice long log to document the process of starting and self-terminating. In other words, it's doing what it's supposed to do (as far as I can tell) despite low usage and my nonintervention. It's been running for about a day and a half now and the process updates itself (i.e. it reloads the script anew) without any usage every 600 seconds.

    I'm wondering if your server is configured properly. Since I'm not running the server, I couldn't even begin to tell you which parameter to tweak or which one to request. You might try visiting www.fastcgi.com and looking for the Apache links to get the internals.

  7. #7
    JPC Member
    Join Date
    Jan 2006
    Posts
    6
    Thanks Spathiphyllum. I'll look into it further using the docs and maybe some experimentation at home.

    For now, the Cron job seems to be doing the trick so its not an immediate problem at the moment.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •