Forum: Ruby on Rails [Tip] Keeping fastcgi in memory

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Ef0db53920b243d6758c2f6b1306df0d?d=identicon&s=25 Steve Ross (cwd)
on 2006-02-22 19:26
There has been discussion about using wget and curl to ping a server
every 5 minutes or so to keep the fastcgi processes alive. I didn't find
a command line for this so I thought I'd post one.

Put this in your crontab using crontab -e or your favorite other method:

0-59/5 * * * *  curl -r 0-99 http://somedomain.com>/dev/null 2>/dev/null

This hits the default page of somedomain.com every 5 minutes and dumps
the output into a black hole. If you're lucky and have an HTTP 1.1
compliant version of curl, you will only yank 100 bytes of the page.

n.b., the page you hit should not be cached or it will bypass Rails and
serve up the static page.

Cheers
This topic is locked and can not be replied to.