4

We are using the GAE flexible environment for java (with openjdk8), with a memory limit of 2GB, running a spring boot app which connects to google cloudsql and a separate mongodb vm instance.

Now every once in a while, the instance running the service restarts (which means a downtime of our service for several minutes). The logs show that the oom_kill_process routine is called, which leads to the restart. After some research we started to monitor not just the memory usage of our service, but also of the other services running on the instance (https://github.com/GoogleCloudPlatform/appengine-sidecars-docker).

We found that the fluentd-logger running in a ruby environment uses a larger junk of the memory, more than the 400MB additionally reserved for the system according to the gae docs. One snapshot showed a usage of >650MB and it was still rising, minutes later the instance crashed and then restarted.

Is there a way to limit the memory usage of the fluentd-logger?

This might also be related to this: Google Cloud Platform App Engine Node Flexible Instance Ruby sitting at 50% RAM usage

As an intermediary solution we increased the total memory to 4GB, which made the gap between the restarts larger, but that shouldn't be the long term solution

ghiermann
  • 61
  • 5
  • 1
    Does anyone have a solution to this? We have an equivalent problem with Golang application; fluentd consumes memory until the application shuts down. I suspect the OOM killer is shutting down processes to make room for fluentd, as OP suggests, but we have no way to ensure fluentd consumes less memory – abgordon Dec 19 '17 at 21:58

0 Answers0