Saya47 / fluent-bit-disk

Disk plugin for fluentbit. Reports available disk space and inodes.

Home Page:http://www.vorteil.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Codacy Badge Build Status

fluent-bit-disk

Using the plugin

This plugin for fluent-bit reports disk partition usage.

The name of the plugin is 'vdisk' and the name of the partition can be defined in the INPUT section of the plugin.

Example configuration

[SERVICE]
        Daemon off
        Flush 1

[INPUT]
        Name vdisk
        Partition /run

[OUTPUT]
        Name stdout

To make the plugin available to fluentbit the path of the share object needs to be specified on the command line:

./fluent-bit --config=myconfig.cfg --plugin=/path/to/flb-in_vdisk.so

This will produce output like the following:

[0] vdisk.0: [1598916699.022796699, {"bytes_total"=>3361153024, "bytes_free"=>3358642176, "bytes_pct"=>0.074702, "inodes_total"=>4101586, "inodes_free"=>4102966, "inodes_pct"=>0.033634}]

Building the plugin

This plugin uses the example plugin setup for fluentbit plugins.

cmake -DPLUGIN_NAME=in_vdisk -DFLB_SOURCE=~/path/to/fluentbit  ..

About

Disk plugin for fluentbit. Reports available disk space and inodes.

http://www.vorteil.io

License:Apache License 2.0


Languages

Language:C 85.2%Language:CMake 14.8%