Getting Data In

SplunkForwarder RPM Installer - Hostname determination

BP9906
Builder

We added SplunkForwarder RPM with a script to install the agent on all our Redhat kickstarts. The problem is that the hostname is set during kickstart but when the Splunk script runs the way it obtains the server hostname is labeling it the default "localhost". If I run the script manually after the kickstart, it installs fine with the properly registered hostname.

How does the RPM determine the hostname at installation?

Tags (2)
0 Karma
1 Solution

jmantor
Path Finder

rpm -scripts -qp ./splunkforwarder-6.2.2-255606-linux-2.6-x86_64.rpm | more

shows the scripts in the rpm.

It gets the host name with this line :

HOSTNAME='hostname'

View solution in original post

0 Karma

jmantor
Path Finder

rpm -scripts -qp ./splunkforwarder-6.2.2-255606-linux-2.6-x86_64.rpm | more

shows the scripts in the rpm.

It gets the host name with this line :

HOSTNAME='hostname'

0 Karma

BP9906
Builder

thanks. Our kickstart file for redhat confirms it, thanks.

0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...