unicorn Ruby/Rack server user+dev discussion/patches/pulls/bugs/help
 help / color / mirror / code / Atom feed
From: Eric Wong <e@80x24.org>
To: sumit nagariya <sumit.nagariya@gmail.com>
Cc: unicorn-public@bogomips.org, Hleb Valoshka <375gnu@gmail.com>
Subject: Re: Why Unicorn master process memory increasing
Date: Thu, 19 Apr 2018 02:45:48 +0000	[thread overview]
Message-ID: <20180419024548.GA20200@dcvr> (raw)
In-Reply-To: <CAAB-Kc=VyceZd1QHN5DTh5J523=RTFGz=KO3C1R6EL1vd5oTAw@mail.gmail.com>

Hleb: remember to reply-all, we will never require subscription
to post to this list, so it's likely sumit never saw it.

Hleb Valoshka <375gnu@gmail.com> wrote:
> I believe it's hard to say something without your unicorn configuration file.

sumit: what Hleb asked...

I suspect "preload_app true" in your config is loading something
in your app which is using up your memory.  Sometimes there's
monitoring threads which might fill a queue up or something.

Anything in error logs?  Failing that, strace (on Linux) might
tell you what's going on at the error level.

But yeah, the master process shouldn't be doing anything besides
listening to signals and respawning failed workers.

If you want to check if there's monitoring threads on Linux
systems with /proc mounted, you can see how many threads the
master has:

	ls /proc/$PID_OF_MASTER/task/

There should be two entries for Ruby 1.9-2.5(*), one being the
master PID and one for the timer-thread.  If you have more,
then that's probably some thread doing stuff in the
background...

(*) _maybe_ we can get rid of timer-thread for 2.6...

  reply	other threads:[~2018-04-19  2:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-11 15:07 Why Unicorn master process memory increasing sumit nagariya
2018-04-12 10:22 ` Hleb Valoshka
2018-04-19  2:45   ` Eric Wong [this message]
2018-05-05 19:00     ` sumit nagariya

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://yhbt.net/unicorn/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180419024548.GA20200@dcvr \
    --to=e@80x24.org \
    --cc=375gnu@gmail.com \
    --cc=sumit.nagariya@gmail.com \
    --cc=unicorn-public@bogomips.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhbt.net/unicorn.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).