Rails app slow after PostgreSQL inactivity

Luca Ferrari fluca1978 at infinito.it
Tue May 5 10:13:14 UTC 2015


Ciao,

On Sat, May 2, 2015 at 10:18 PM,  <opendaddy at hushmail.com> wrote:
> Could this be related to FreeBSD (DigitalOcean)? Are my PostgreSQL workers are going dormant? Do I need a cron script to act as a little ping pong ball bouncing back and forth making sure everybody's awake?
>

Checking on the PostgreSQL side I would try enabling
log_min_duration_statement to see if there is a problematic query that
is causing some issue, as well as a few other log_ options (see
http://www.postgresql.org/docs/current/static/runtime-config-logging.html).
Have you tried to reproduce the query yourself to see (maybe with
explain) what is going on?
Are there processes running on the background that can slow down the
system (e.g., autovacuum)?

Hope this helps.

Luca


More information about the freebsd-questions mailing list