liveBook · Manning

Memory input plugin

As explained in Logs and Telemetry

The memory input plugin is a Fluent Bit input extension that periodically collects memory and swap measurements.

The memory input plugin periodically collects host memory measurements and emits them as Fluent Bit log events. This log-oriented path supports flexible data manipulation; the records can later be transformed into metrics when required. section 3.2.1

Configure the plugin through an input block:

  • Set name to mem to select the memory input plugin. section 3.2.1
  • Set interval_sec or interval_nsec to control polling frequency. section 3.2.1
  • Assign an explicit tag, such as book_vm_memory, so filters can match the records predictably. section 3.2.1
  • Route records to stdout with match * for an initial local monitoring check. section 3.2.1
Listing 3.1 Performing basic OS monitoring
[INPUT]
  name disk           #1
  interval_sec 5
  tag book_vm_disk

[INPUT]
  name cpu          #2
  interval_sec 5
  tag book_vm_cpu

[INPUT]
  name mem         #3
  interval_sec 5
  tag book_vm_memory

[INPUT]
  name netif          #4
  interval_sec 5
  #interface eth0     #5
  tag book_vm_network

[OUTPUT]
  name stdout
  match *        #6

Use the complete configuration to run memory collection alongside disk, CPU, and network-interface inputs, polling each source every five seconds. section 3.2.1

How Logs and Telemetry covers it

How deep it goes
Defines the plugin name, polling interval, tag, and stdout route, but does not detail record fields or platform-specific support.
Examples
Uses a five-second mem input tagged book_vm_memory in a combined disk, CPU, memory, and network monitoring configuration.
What you can do after
Operate/configure Fluent Bit to poll memory and send the resulting events to a console output.
How it connects
Connects input plugins with tags, filters, log events, metrics, and stdout output.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Logs and Telemetry. The section links point to the parts of the book it draws on.