Monitoring Splunk

monitor inode useage

Vinesh93
Explorer

Is there any possible solution to monitor the inode usage of linux system in Splunk?

Tags (1)
0 Karma
1 Solution

PavelP
Motivator

you need to install an Add-on for Linux and modify/copy its df.sh script, change

CMD='df -TPh'

to

CMD='df -TPhi'

you can remove -h parameter too.

Output will be:

Filesystem   Type              Size        Used       Avail      UsePct    MountedOn
/dev/sda1   ext4               57G         19G         35G         36%    /

and without -h:

Filesystem    Type              Size        Used       Avail      UsePct    MountedOn
/dev/sda1    ext4           7627488      104349     7523139          2%    /

you can modify the FORMAT and HEADER variables in df.sh further to show Inodes/IUsed/IFree/IUse% instead of Size/Used/Avail/UsePct

View solution in original post

PavelP
Motivator

you need to install an Add-on for Linux and modify/copy its df.sh script, change

CMD='df -TPh'

to

CMD='df -TPhi'

you can remove -h parameter too.

Output will be:

Filesystem   Type              Size        Used       Avail      UsePct    MountedOn
/dev/sda1   ext4               57G         19G         35G         36%    /

and without -h:

Filesystem    Type              Size        Used       Avail      UsePct    MountedOn
/dev/sda1    ext4           7627488      104349     7523139          2%    /

you can modify the FORMAT and HEADER variables in df.sh further to show Inodes/IUsed/IFree/IUse% instead of Size/Used/Avail/UsePct

Vinesh93
Explorer

@PavelP Thanks a lot, that works like a charm!!!

0 Karma

PavelP
Motivator

thank you @Vinesh93 , please accept the answer as solution so everybody can benefit from it

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

What Is Splunk? Here’s What You Can Do with Splunk

Hey Splunk Community, we know you know Splunk. You likely leverage its unparalleled ability to ingest, index, ...

Level Up Your .conf25: Splunk Arcade Comes to Boston

With .conf25 right around the corner in Boston, there’s a lot to look forward to — inspiring keynotes, ...

Manual Instrumentation with Splunk Observability Cloud: How to Instrument Frontend ...

Although it might seem daunting, as we’ve seen in this series, manual instrumentation can be straightforward ...