All Apps and Add-ons

How to use $HOSTNAME Linux environment variables in forwarder's inputs.conf to identify servers by hostname?

ivangutev
Engager

Hello,

I am trying to use the $HOSTNAME Linux environment variable in inputs.conf of splunkforwarder, because I would like to identify servers by hostname. I wonder is that possible and how, because I have tried already to set a HOST variable and to pass the content into host = $(HOST)-webserver but somehow that is not working.

Can you help me please?

Thanks,
Ivan

0 Karma
1 Solution

ivangutev
Engager

I found a solution. If I do not set the host in inputs.conf, it will use the hostname of the server and therefore I can identify it this way.

View solution in original post

0 Karma

ivangutev
Engager

I found a solution. If I do not set the host in inputs.conf, it will use the hostname of the server and therefore I can identify it this way.

0 Karma
Get Updates on the Splunk Community!

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...

Tech Talk | Elevating Digital Service Excellence: The Synergy of Splunk RUM & APM

Elevating Digital Service Excellence: The Synergy of Real User Monitoring and Application Performance ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...