# Capistrano Deployment Delay

**URL:** <https://www.ruby-forum.com/t/capistrano-deployment-delay/75049>\
**Category:** Rails\
**Created:** [November 7, 2006, 11:08am UTC](https://www.ruby-forum.com/t/capistrano-deployment-delay/75049 "2006-11-07T11:08:09Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [November 7, 2006, 11:08am UTC](https://www.ruby-forum.com/t/capistrano-deployment-delay/75049/1 "2006-11-07T11:08:09Z")

</div>

I have an RoR app happily deployed on Dreamhost with Capistrano.  
Sometimes when I do an update and cap deploy the changes are available  
as soon as I log in, others take a few minutes, some take overnight. I  
can see the dispatch.fcgi being restarted at the end of the deployment.  
Does anyone have any insight? Thanks in advance.

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [November 7, 2006, 11:06pm UTC](https://www.ruby-forum.com/t/capistrano-deployment-delay/75049/2 "2006-11-07T23:06:32Z")

</div>

On 11/6/06, Hugh [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I have an RoR app happily deployed on Dreamhost with Capistrano.  
> Sometimes when I do an update and cap deploy the changes are available  
> as soon as I log in, others take a few minutes, some take overnight. I  
> can see the dispatch.fcgi being restarted at the end of the deployment.  
> Does anyone have any insight? Thanks in advance.

Are you using any caching? If so, are the caches cleaned when you  
deploy?

-ryan

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [November 8, 2006, 5:33am UTC](https://www.ruby-forum.com/t/capistrano-deployment-delay/75049/3 "2006-11-08T05:33:42Z")

</div>

I have the same issue as the OP. No caching or any other voodoo being  
intentionally done on my part.

I’ve always just assumed that DH has a cron job they run once an hour  
or so that flushes something out (not sure what), and that the  
variability in how long it takes is a fumction of how closely your  
deployment lines up with the timing of said cron job.

Capistrano takes the “this site down for maintenance” page down when  
it’s done, so I just start the deployment before I go to sleep.

- f

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [November 8, 2006, 8:20pm UTC](https://www.ruby-forum.com/t/capistrano-deployment-delay/75049/4 "2006-11-08T20:20:18Z")

</div>

No caching or anything fancy running. Is there a specific task I could  
add to deploy.rb to clean out caches just in case?

Thanks,  
Hugh

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [November 8, 2006, 10:35pm UTC](https://www.ruby-forum.com/t/capistrano-deployment-delay/75049/5 "2006-11-08T22:35:06Z")

</div>

Hugh wrote:

> No caching or anything fancy running. Is there a specific task I could  
> add to deploy.rb to clean out caches just in case?

It sounds to me as though your FCGI processes aren’t actually being  
restarted.

You might want to log in via ssh and kill them manually after the  
deploy. That will force a reload of your application when they’re  
started up again.

–Al Evans

---

<div class="post-metadata">

**Author:** ![casper\_the\_ghost](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/58956e/32.png) [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Post date:** [November 9, 2006, 5:07pm UTC](https://www.ruby-forum.com/t/capistrano-deployment-delay/75049/6 "2006-11-09T17:07:19Z")

</div>

Great, thanks.

I’ll give it a try.

Hugh
