Documentation
DocumentationDiscussions
Documentation
These docs are for v2023.2. Click to read the latest docs for v2024.3.

Memory

Details on using the Seq Docker container

For Seq to accurately measure available memory, depending on the hosting infrastructure, it's often necessary to specify memory limits for the container. If the Seq container exits unexpectedly, or fails with out-of-memory errors, specify the --memory and --memory-swap arguments to docker run:

docker run --memory=16g --memory-swap=16g <other args> datalust/seq

The argument to these flags is the total memory that the system should provide for the container (more is better). Normally, both flags should have the same value, effectively disabling swap for the container.

Managing memory

Memory in Seq is managed in a few layers:

  • The host memory limit. If Seq uses too much memory on the host it will risk being 'OOM-killed' by the OS.
    • The container memory limit. This value is specified through the --memory args to docker run. If this value isn't set then it will default to the host memory limit. If Seq uses more than this value it will probably be recycled by Docker.
      • The .NET GC heap limit. This value is specified through the COMPlus_GCHeapHardLimitPercent environment variable. If this value isn't set then it will default to 97% of the container memory limit. If Seq uses more than this value it will start throwing OutOfMemory exceptions.

The default values should provide a stable environment with headroom for ingestion and query spikes, but they can be tuned for very large or very small instances.