Free forever, no credit card.Get Started for Free →
← All posts
December 5, 2026 · 6 min read

Does Metricbeat Remember Between Runs? A Sampler With No Bookmark and a Queue That Forgets on Restart

Does Metricbeat Remember Between Runs? A Sampler With No Bookmark and a Queue That Forgets on Restart Metricbeat collects metrics from a host and the services on it: CPU, memory, filesystem, network, processes, and, through modules, systems such as Docker, Kubernetes, MySQL or nginx. It runs on fleets that reboot, get redeployed as containers, and restart for every config change. So the memory question sounds familiar: when Metricbeat starts again, does it pick up where it stopped? The short a

Does Metricbeat Remember Between Runs? A Sampler With No Bookmark and a Queue That Forgets on Restart

Metricbeat collects metrics from a host and the services on it: CPU, memory, filesystem, network, processes, and, through modules, systems such as Docker, Kubernetes, MySQL or nginx. It runs on fleets that reboot, get redeployed as containers, and restart for every config change. So the memory question sounds familiar: when Metricbeat starts again, does it pick up where it stopped?

The short answer is that there is almost nowhere to pick up from. Metricbeat is a sampler, not a tailer. It has no registry bookmark like Filebeat or Winlogbeat, no record number and no file offset to resume. What it holds between moments inside one process life — a previous sample for delta calculations and a buffered queue of unpublished events — is real, but a restart clears both. Understanding that split explains the gaps, the missing first percentages, and the unpublished metrics that never arrive.

No bookmark: sampling is not reading

Filebeat and Winlogbeat read a stream that exists whether they are running or not. A log file keeps growing and an event channel keeps recording, so those Beats store a position and return to it. Elastic's own path documentation makes the distinction plain: Filebeat and Winlogbeat look for their registry files in the data path. Metricbeat is not named there, because it has no equivalent file to look for.

Metricbeat instead polls. Each module runs its metricsets on a period, and the system module's default period is 10 seconds. At each tick it reads the operating system's current counters and publishes a fresh event. If Metricbeat was down for an hour, there is no backlog of samples waiting for it. The counters moved on without it, and the restarted process simply takes a new sample. The gap in the graph is not a failure to resume. It is what a sampler produces when nobody sampled.

The data path still matters, just for different things. On deb and rpm installs it defaults to /var/lib/metricbeat, and it holds persistent data files such as the secrets keystore. Persist that directory in a container and the keystore survives. What does not survive, because it was never written there by default, is a queue of metrics or a position in a stream.

The one memory inside a run: the previous sample

Some metrics cannot be produced from a single reading. A percentage is a change over time, so Metricbeat has to remember the last reading while it waits for the next one.

The system module documentation gives the clearest example: system.process.cpu.total.norm.pct reports the percentage of CPU time a process used since the last event. For that percentage to exist, the process needs to appear at least twice, so a delta can be calculated. If a process has not been available long enough to be included in two collection periods, that field can simply be missing from the event.

That is genuine memory, but it lives only in the running process. Restart Metricbeat and the baseline is gone. The first sample after a restart can report cumulative counters, but the derived percentages need a second sample before they mean anything again. Nothing restores the previous baseline from disk, because nothing wrote it to disk.

The queue: buffered events, held only until acknowledgement

Between collection and delivery, Metricbeat buffers events in an internal queue. The default queue is the memory queue, configured under queue.mem. It holds up to 4096 events by default, waits for the output to acknowledge or drop events before freeing space, and by default flushes when 2048 events are available or after a 1-second flush timeout.

While the process stays alive, that queue is a short-term memory of work not yet delivered. If the output slows down, events accumulate there instead of vanishing immediately. Once the queue is full, however, Metricbeat behaves differently from Filebeat. A Filebeat input can pause at its offset and resume when space returns. A Metricbeat metricset has no offset to pause at: once the queue reaches capacity, additional metric events are dropped. The sample was taken, the moment passed, and there is nowhere to re-read it from.

A restart is harsher still. Every unpublished event in the memory queue is discarded when the process stops. The metrics collected since the last successful acknowledgement are lost, not replayed on the next start. The queue remembered them only for as long as the process lived.

The disk queue changes the delivery answer, not the sampling answer

There is a persistent alternative. The disk queue stores pending events on disk rather than in main memory, configured with a maximum size such as queue.disk: max_size: 10GB. With a disk queue on persistent storage, unpublished events can survive a restart and be forwarded once the output returns.

That is worth enabling where output outages are common, but be clear about what it fixes. It preserves events that were already collected and queued. It does not create samples for the downtime itself, it does not restore the delta baseline for percentage calculations, and it does not store any conclusion an operator or an automation reached from the metrics. It is delivery durability, nothing more.

What Metricbeat never remembers

List what none of these mechanisms holds. The queue does not remember that the last run already flagged a host as saturated. The delta state does not remember that an automation already opened a ticket, already scaled a service, or already decided a spike was a known batch job. There is no shared record of decisions, only samples flowing one way into an output.

That distinction lands hardest on scheduled automation. A workflow that reviews Metricbeat data every fifteen minutes starts each run by querying the output, then re-derives context that the previous run already worked out: which hosts were already handled, which spikes were already explained, which actions are already in flight. The metrics survived in Elasticsearch. The reasoning did not survive anywhere, because no part of the pipeline was built to keep it.

Give the reasoning a memory of its own

Vilix AI is built for that missing layer. It is cloud-hosted with zero infrastructure to run, so a scheduled automation connects to it over MCP instead of standing up a memory server next to the metrics stack. The same memory is available everywhere MCP runs, so the agent reviewing host metrics and the agent summarising incidents read one shared state.

Vilix AI keeps full conversation history, not just extracted facts, so a run can check what the previous run actually concluded and did before it acts again. That is the difference between a fresh sample and a resumed line of work: Metricbeat tells you what the host looks like now, and shared memory tells the automation what it already decided about it.

Start on the free plan, which stays free forever, or run the 7-day Pro trial with no card required. Export or delete your memory at any time. Let Metricbeat sample, let the disk queue protect delivery if you need it, and stop expecting a 10-second sampler to remember your reasoning between runs.

Get Started for Free

Persistent memory across ChatGPT, Claude, and the AI tools you already use in Vilix AI.

Get Started for Free

Free forever, no credit card.

Keep reading
Does Winlogbeat Remember Between Runs? One Bookmark Per Channel, Written Only After the Output Says Yes.

Does Winlogbeat Remember Between Runs? One Bookmark Per Channel, Written Only After the Output Says Yes. Winlogbeat ships Windows Event Logs — Security, System, Application, PowerShell, and any other channel you name — to Elasticsearch, Logstash, or another output. It runs as a service on machines that reboot for patching, get reimaged, or lose power. So the memory question is exact: when Winlogbeat starts again, does it resend everything, skip what happened while it was down, or pick up precis

Does Data Prepper Remember Between Runs? The Buffer Forgets on Restart. The Checkpoint Does Not.

Does Data Prepper Remember Between Runs? The Buffer Forgets on Restart. The Checkpoint Does Not. OpenSearch Data Prepper sits between a source and a sink, filtering, enriching, and aggregating logs, metrics, and traces before they reach OpenSearch or another destination. Pipelines restart for ordinary reasons: a rolling deployment, a config change in pipelines.yaml, a pod reschedule, a crash under load. The memory question is therefore concrete. When Data Prepper comes back, which parts resume

Does Splunk Universal Forwarder Remember Between Runs? The Fishbucket Resumes the File. Nothing Resumes the Reasoning.

Does Splunk Universal Forwarder Remember Between Runs? The Fishbucket Resumes the File. Nothing Resumes the Reasoning. A Splunk Universal Forwarder sits on a server, a laptop, or a container host and does one job: read local data and send it to an indexer. It also restarts constantly in real life: patching, upgrades, reboots, a service recycle after a config change. So the memory question is practical. When the forwarder comes back, what does it still know, and what was never stored anywhere?