|
I have a lot of remote Windows servers that I would like to install Splunk on. It will take forever to manually do this, so I was wondering if I could use Group Policy Objects in Active Directory to automate the exe push. Also, I have some Linux servers too I may want to include, so I'm wondering what other "push" solution(s) do people use to distribute binaries to servers in their IT environments. |
|
I'm keeping this: http://www.splunk.com/wiki/Deploying_Splunk_Light_Forwarders up to date as the recommended way to deploy. Please refer to that link, since as Splunk versions change and we develop new practices, I'll maintain the other link. Note the the below applies to 4.0. For 4.1, the script is valid, but the configuration file set required is smaller, as 4.1 does not set as much upon install, and therefore does not need as much to disable functionality. In particular, you will not need:
but you will still want to have:
You can use any software distribution mechanism you have available. To install Light Forwarders on Windows, I recommending creating a Windows batch file
Edit the Splunk MSI path information as appropriate, and place the MSI files in the same directory as this script. Finally, create a directory in the same folder called To create a bare initial installation that does nothing, with all defaults inputs and scripts disabled, place the following files into the
The files should contain: etc\apps\sample_app\local\app.conf:
etc\apps\search\local\inputs.conf:
etc\apps\search\local\savedsearches.conf:
etc\apps\SplunkLightForwarder\local\app.conf:
etc\apps\SplunkLightForwarder\local\inputs.conf:
etc\apps\windows\local\inputs.conf:
etc\apps\windows\local\savedsearches.conf:
and finally, etc\apps\deploymentclient\local\deploymentclient.conf is only necessary if you will be using the Splunk Deployment Server to manage the forwarder configurations. Unless you have another configuration management system, we recommend you use the Deployment Server to be able to make modifications to forwarder configurations from. However, any system which lets you push configurations files and restart a service can be used instead, e.g., on Linux systems, puppet has been a good and effective solution that can both install Splunk and manage the configuration.
I have gotten this to work for my Server 2003 boxes but not my Server 2008 R2 64 bit box. Has anyone else had the same issue???
(20 Dec '10, 21:39)
balbano
It is possible that Windows User Account Control is blocking this. The Splunk MSI in the current release I believe will simply fail silently if UAC fails. You may try checking into this.
(20 Dec '10, 22:29)
gkanapathy ♦
I don't think that is the issue... if I manually setup splunk (non-forwarder mode) and hardwire inputs.conf and outputs.conf in SplunkHome/etc/system/local it works fine and sends the logs to my indexers... that is not the case in light forwarder or even forwarder mode... Don't see how it can be UAC related if the same local system user is being used by default. Should I open a support case for this? Let me know. Thanks. Brian
(20 Dec '10, 23:37)
balbano
|
|
For various reasons we don't have a viable software distribution system. To get around that we leveraged a few open source tools and wrote a few cmd scripts. [Tools] blat.exe psexec.exe [Overall Iterative Install/Uninstall Wrapper]
[Installer CMD Script]
[Uninstaller CMD Script]
It took me about 5-10 minutes to install the forwarders across 40 servers. As part of the installation package, we pre-created all of the splunkd configurations (deployment client, logging) which are copied as part of the installation. Our particular installation we made sure to disable SplunkWeb, and have splunkd check into our deployment server for all monitoring details. This includes the instructions as to which index server/s to connect to. |
|
I was looking at impementing Splunk a couple of months ago and I thought about how I was going to get the Security log from over 200 servers. I to thought about installing forwarders on each of the servers but this would have been impossible to do in the time that I had. I ended up using WMI to gather selected events from Security logs, I had to build three Splunk servers - 1 central server that would do all the indexing, 1 that would gather from non-domain servers and one that gathers from AD servers each of these forward to the central instance for indexing, We are also indexing all the syslog data on UDP:514. |
|
From the server command prompt I run: msiexec.exe /i "where the install files are located" INSTALLDIR="where you want splunk installed" FORWARD_SERVER="IP or DNS:Port_used" SPLUNK_APP="SplunkLightForwarder" /passive This is how I have been setting up my SplunkForwarder for windows. Then after I copy my custom .conf and disable Splunk Web from services.msc and a splunkd restart I am up and running. Travis. |
|
We have created a batch installer also. To solve our needs we needed to be able to set up different indexes, file integrity monitoring, and which parts of Splunk to turn on. This is done by asking the installer a series of questions. We named the script file SplunkInstaller.cmd because we are so original and creative. The .cmd extension was used so in Windows Server 2008 you can choose to run as an administrator. We bundle this script, the msi files for 32bit and 64bit, and PortQry.exe in to a self extracting executable that will extract to the Windows Temp directory (%WINDIR%\Temp\ or commonly found at C:\Windows\Temp). PortQry can be downloaded from Microsoft (http://support.microsoft.com/kb/310099). This allows you to test to make sure the ports are open to the Splunk indexer.
|
|
So in the following configuration. Can I just copy it to notepad and save as a .bat file? and also how does the syntax work for the path following the I hope all these questions make sense. I plan to use SCCM to deploy this bat file. ****START CONFIG BELOW**** setlocal :b64 if not defined ProgramFilesW6432 ( msiexec.exe /i "%SPLUNK_MSI%" INSTALLDIR="%LOC%" LAUNCHSPLUNK=0 SPLUNK_APP="" /QUIET popd |
