Skip to content

SCP2 Commands ignoring restriction to local #155

@justinatpnnl

Description

@justinatpnnl

I created a generating search that pulls in events from a rest api. Everything works perfectly with SCP2 when testing on my dev box, but when deploying in a distributed environment I get an error from each of my indexers that it can't make a connection to the rest api (internet access blocked as intended).

Configurations tried:

  • Added local=true to commands.conf
  • Added local=true to @configuration() within the command itself (old method)
  • Added type='streaming',distributed=False to @configuration() (scpv2 method according to docs)

All of these still gave me errors on my indexers. If I use splunk_server=local with my command from the web ui, it does make it stay local as expected. All of this seems to run contrary to the docs which state that "By default generating commands are configured to run locally in the streams pipeline".

A side note, there appears to be some incomplete commands.conf instructions for setting up distributed options in commands.conf:
http://docs.splunk.com/DocumentationStatic/PythonSDK/1.6.0/searchcommands.html#splunklib.searchcommands.GeneratingCommand

SCP 2

  1. Add this configuration setting to your code
  2. You are good to go; no need to restart Splunk

For now I have reverted to SCP1 and local=True is working as expected.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions