|
When you have more than a few forwarders to maintain, it becomes tedious (and error-prone) to install them one-by-one. Using the Deployment Server is great for keeping the configurations up-to-date and consistent. But I want to script the installation. This isn't really a Splunk problem, it's more of a scripting problem. Any great scripts out there? All answers welcome, especially Linux and Windows. |
|
With some updates that were created (and tested!) by rroberts. Thanks Mr R; you are the best! If you cut-and-paste this script - watch out for the line wraps! You will need to correct these before your script will run.
1
This was the shortest script that I could come up with that wasn't completely lame. It is based on a much more sophisticated script that is now part of the documentation.
(22 Nov '11, 11:10)
lguinn ♦
1
If you cut-and-paste this script, watch out for the line wrap on the lines that start with /opt/splunkforwarder
(22 Nov '11, 11:12)
lguinn ♦
Thanks, the above script is a proof of the splunk inability to create easy to install and deploy products. I just hope that they will fix the current silly URL download tricks and provide a solution like this, maybe even RPM and DEB repositories.
(21 Mar '12, 11:32)
ssbarnea
2
ssbarnea, that's a bit harsh. We're talking about on the fly configuration, which is not trivial, and this kind of script is very helpful (at least to oldschoolers like myself). Thanks lguinn, this one answers 3-4 questions I had while writing something similar.
(30 Mar '12, 07:42)
bilhays
1
A couple of comments: [1] Nothing keeps you from running a purely-internal yum repository to distribute Splunk install images to your servers. Then, "yum update" even works... [2] Rather than setting the admin password directly, there's always user-seed.conf, which works well for that purpose. [3] It's not terribly difficult to spin out your own RPM that includes splunk as a dependency - let that RPM (and its included scriplets) deal with post-install configuration
(13 Jun '12, 19:59)
dwaddle ♦
Thanks for the script. We have found Splunk incredibly easy to install and upgrade. Much easier that most products. We have UF's installed on 3000+ servers.
(10 Jan, 03:48)
rmorlen
showing 5 of 6
show 1 more comments ▼
|
BTW, if you want to learn more about the Deployment Server and how to distribute configuration files (like
inputs.conf), take a look at the Distributed Deployment Manual, especially here:http://docs.splunk.com/Documentation/Splunk/5.0.2/Deploy/Aboutdeploymentserver