|
16 | 16 | * [Setup requirements](#setup-requirements)
|
17 | 17 | * [Beginning with splunk](#beginning-with-splunk)
|
18 | 18 | 1. [Usage - Configuration options and additional functionality](#usage)
|
| 19 | + * [Upgrade splunk/splunkforwarder packages](#upgrade-splunksplunkforwarder-packages) |
| 20 | + * [Upgrade Example](#upgrade-example) |
19 | 21 | 1. [Reference - An under-the-hood peek at what the module is doing and how](#reference)
|
20 | 22 | 1. [Limitations - OS compatibility, etc.](#limitations)
|
21 | 23 | 1. [Development - Guide for contributing to the module](#development)
|
@@ -161,6 +163,39 @@ This virtual resource will get collected by the `::splunk::forwarder` class if
|
161 | 163 | it is tagged with `splunk_forwarder` and will add the appropriate setting to
|
162 | 164 | the inputs.conf file and refresh the service.
|
163 | 165 |
|
| 166 | +### Upgrade splunk/splunkforwarder packages |
| 167 | + |
| 168 | +This module has the ability to install *and* upgrade the splunk and splunkforwarder packages. All you have to do is declare `package_ensure => 'latest'` when calling the `::splunk` or `::splunk::forwarder` classes. |
| 169 | + |
| 170 | +#### Upgrade Example |
| 171 | + |
| 172 | +The following code will install the 6.6.8 version of the splunk forwarder. Then |
| 173 | +comment out the 6.6.8 version and build values and uncomment the 7.1.2 version |
| 174 | +and build values. Running puppet again will perform the following: |
| 175 | + |
| 176 | +1. splunk forwarder package is upgraded |
| 177 | + 1. splunk service is stopped as part of the package upgrade process |
| 178 | +1. new license agreement is automatically accepted |
| 179 | + 1. license agreement must be accepted or the splunk service will fail to start |
| 180 | +1. splunk service is started |
| 181 | + |
| 182 | +```puppet |
| 183 | +# Tell the module to get packages directly from Splunk. |
| 184 | +class { '::splunk::params': |
| 185 | + version => '6.6.8', |
| 186 | + build => '6c27a8439c1e', |
| 187 | + #version => '7.1.2', |
| 188 | + #build => 'a0c72a66db66', |
| 189 | + src_root => 'https://download.splunk.com', |
| 190 | +} |
| 191 | +
|
| 192 | +# Specifying package_ensure => 'latest' will ensure that the splunk and |
| 193 | +# splunkforwarder packages will be upgraded when you specify newer values for |
| 194 | +# version and build. |
| 195 | +class { '::splunk::forwarder': |
| 196 | + package_ensure => 'latest', |
| 197 | +} |
| 198 | +``` |
164 | 199 | ## Reference
|
165 | 200 |
|
166 | 201 | ### Types
|
|
0 commit comments