GithubHelp home page GithubHelp logo

w3ttr3y / puppet-module-splunk Goto Github PK

View Code? Open in Web Editor NEW
0.0 0.0 0.0 47 KB

A puppet module for installing and configuring Splunk Enterprise

License: Apache License 2.0

Ruby 47.72% Puppet 52.28%

puppet-module-splunk's People

Contributors

w3ttr3y avatar

Watchers

 avatar

puppet-module-splunk's Issues

Change User

If we change the user (e.g. from Splunk to Splunk2), does it do the right thing?

Update init script, file permissions, splunk-launch.conf etc

What about purging old users/group?

Install via TGZ: purge tgz file

This is complicated as if there are multiple instance, I really don't want to copy the file multiple times. I can't think of a way to do that without leaving a stale tar file laying around.

The problem is if we have two instance of a version and then one gets purged. One wants to purge the staged file, the other wants it.

There may be a clever way with virtual resources; otherwise I think Ruby code would be involved. I had hope the puppetlabs staging module would solve this issue, but I similarly have a stale file laying around in my tests.

Systemd

Add support for native systemd

I think this could be cleaner then trying to work within the traditional init system.

Using a template we could do something like:

[Unit]
Description=Splunk ${instance}
Wants=network.target
After=network.target

[Service]
Type=forking
RemainAfterExit=yes
ExecStart=${splunk_home}/bin/splunk start --answer-yes --no-prompt --accept-license
ExecStop=${splunk_home}/bin/splunk stop
ExecReload=${splunk_home}/bin/splunk restart
StandardOutput=syslog

[Install]
WantedBy=multi-user.target

Systemd: pidfile

http://www.freedesktop.org/wiki/Software/systemd/Incompatibilities/

Mentions using pidfile option so that systemd will know what the main process is and will know if the service has stopped.

This should allow us to stop splunk with $SPLUNK_HOME/bin/splunk and now that it was stopped.

This will be interesting in cases like deployer and deployment server where they restart Splunk as systemd will know that SPlunk stopped. We'll need to configure it to NOT automatically restart Splunk. Maybe with a timeout we can restart it with systemd.

Re-install init script

According to duckfez:
"somewhere in the docs they suggest a "splunk disable boot-start && splunk enable boot-start -user splunk" on non-patchlevel upgrades"

For at least the changes with eliminating the use of sudo that makes a lot of sense and is something we should implement.

Config

Define what we want in our basic configuration.

splunkd port
SSL?
user

?????

Set Limits on Start

Adjust ulimit settings on start.

I read that you can do this with a systemd service unit file; look into doing it for init scripts also.

Install TGZ: better way to stage file

Basically what I'm doing on the file copy is I'm using validate_cmd so that if we aren't updating Splunk, then we won't copy over the TGZ if it doesn't exist locally. The problem is that when the file doesn't exist and not update is needed, it prints a warning.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.