Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: update getting-started-splunk-setup.md #2417

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

jenworthington
Copy link
Collaborator

I can't quite figure out how the customer is supposed to use this. It reads as steps but they don't seem like actual guided tasks. Is it more of a best practices topic or an overview? Or if it is numbered steps/process, then maybe we add links to each step? I'd love to get your thoughts and maybe we can discuss in our 1:1

I can't quite figure out how the customer is supposed to use this. It reads as steps but they don't seem like actual guided tasks. Is it more of a best practices topic or an overview? Or if it is numbered steps/process, then maybe we add links to each step? I'd love to get your thoughts and maybe we can discuss in our 1:1
@mstopa-splunk
Copy link
Contributor

hi @jenworthington sure, that's what this section is about:

Topic: how to setup your Splunk instance to work with SC4S

Steps:

  1. Create default indexes in Splunk
  2. Set up the Splunk HTTP Event Collector

These are the two things that must be done to ensure SC4S-Splunk connection.

Ad 1 Indexes
You can use your custom set of indexes. But make sure that all of them, as well as the default set, are created in Splunk, else you will miss events processed by SC4S

Ad 2 HTTP event collector

  • Refer to Splunk docs to see how to set it up
  • But here are best practices to avoid problems:
    a. put HEC endpoints of your indexers behind a load balancer. Use native syslog-ng load balancing or, preferably, an external load balancer
    b. don't use an intermediate tier of HWFs
    c. make sure that the HEC token has permissions to write in the indexes that you'll need
    d. make sure that you either don't put any "Selected Indexes" or you carefully keep this list up to date
    e. If you're not using TLS on SC4S, turn it off in Splunk's HEC token too.

@mstopa-splunk mstopa-splunk changed the title Update getting-started-splunk-setup.md docs: update getting-started-splunk-setup.md Apr 23, 2024
@mstopa-splunk
Copy link
Contributor

partially solves #2358

@mstopa-splunk
Copy link
Contributor

@jenworthington can you work on the new file docs/gettingstarted/getting-started-splunk-setup-new.md ? I will replace the old one with this one when we finish

Copy link
Collaborator

@rjha-splunk rjha-splunk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please check the comment.

@mstopa-splunk
Copy link
Contributor

@rjha-splunk I left the file that you saw for reference for Jen, but please check docs/gettingstarted/getting-started-splunk-setup-new.md instead. It will replace the old one completely

@jenworthington
Copy link
Collaborator Author

jenworthington commented Apr 24, 2024

Thanks for the new suggestions for structure, it was really helpful. I think I've captured all of the requested changes, take a look and let me know, happy to work on this one some more as needed.

* In case you are not using TLS on SC4S- turn off SSL on global settings for HEC in Splunk.
- Refer to [Splunk Cloud](http://docs.splunk.com/Documentation/Splunk/7.3.1/Data/UsetheHTTPEventCollector#Configure_HTTP_Event_Collector_on_managed_Splunk_Cloud)
or [Splunk Enterprise](http://dev.splunk.com/view/event-collector/SP-CAAAE6Q) for specific HEC configuration instructions based on your
To set up syslog processing with SC4S, perform the following tasks in your Splunk instance:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a tricky one: SC4S will process syslog regardless Splunk. But if Splunk is not correctly set up, output from SC4S won't be correctly indexed by Splunk. Can me make it more like: "to ensure proper integration/collaboration/setup of SC4S and Splunk" kind of thing?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jenworthington please check this comment

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about "To ensure proper integration for SC4S and Splunk, perform the following tasks in your Splunk instance:"

To set up syslog processing with SC4S, perform the following tasks in your Splunk instance:
1. Create indexes within Splunk.
2. Configure your HTTP event collector.
3. Create a load balancing mechanism.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Create a load balancing mechanism" is a subsection to "Configure your HTTP event collector"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jenworthington I think it's better to remove point 3 as a subsection of point 2

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


## Step 1: Create indexes within Splunk

SC4S maps each sourcetype to the following indexes by default:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Customers report problems to us because sometimes they don't create those indexes in Splunk, so better to say in the docs that the SC4S's default set of indexes must be created in Splunk

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that makes so much more sense!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

right, but the call for action for the reader is that they must create those indexes or they will have problems, please compare with the original document

* `print`
* `_metrics` (Optional opt-in for SC4S operational metrics; ensure this is created as a metrics index)

You can also you create your own indexes in Splunk. See [Create custom indexes]( https://docs.splunk.com/Documentation/Splunk/9.2.1/Indexer/Setupmultipleindexes) for more information.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we say that if you use your own indexes in SC4S you also have to create them in Splunk?

send data to an index that is not in this list results in a `400` error from the HEC endpoint. The `lastChanceIndex` will not be
consulted if the index specified in the event is not configured on Splunk and the entire batch is then not sent to Splunk.
* If you are not using TLS on SC4S, turn off SSL on global settings for HEC in Splunk.
* SC4S traffic must be sent to HEC endpoints that are configured directly on the indexers.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we restore the alternative and change it to should? SC4S traffic should be sent to HEC endpoints configured directly on the indexers rather than an intermediate tier of heavy forwarders.

* If you are not using TLS on SC4S, turn off SSL on global settings for HEC in Splunk.
* SC4S traffic must be sent to HEC endpoints that are configured directly on the indexers.

### Step 2: Create a load balancing mechanism
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create a load balancing mechanism is a subsection of Configure your HTTP event collector

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i removed it as a numbered step and made it a subtopic instead.

* SC4S traffic must be sent to HEC endpoints that are configured directly on the indexers.

### Step 2: Create a load balancing mechanism
Create a load balancing mechanism between SC4S and Splunk indexers. See [Set up load balancing](https://docs.splunk.com/Documentation/Splunk/9.2.1/Forwarding/Setuploadbalancingd) for more information. Note that this should not be confused with load balancing between [sources and SC4S](../lb.md).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

splunk docs on load balancing don't apply to this case. Can we make it more in the style of:

In some situations, it is necessary to ensure balancing of the output from SC4S to Splunk indexers. Note that this should not be confused with load balancing between [sources and SC4S](../lb.md). 

what we mean here is that:

  • if you have Splunk Cloud no worry, you're already covered and your SC4S output will be automatically load balanced to Splunk indexers
  • if you have Splunk Enterprise and a single indexer, you obviously don't need an lb
  • if you have Splunk Enterprise and mutliple indexers, you should load balance your SC4S output

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks! Is there another topic we should link to in case they are now to the product and need some guidance for creating this type of load balancing?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately there's nothing to link at this point, we don't provide any further recommendations for lbs at this point

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"In some configurations, you should ensure output balancing from SC4S to Splunk indexers. To do this, you create a load balancing mechanism between SC4S and Splunk indexers. See Set up load balancing for more information."

* An external load balancer simplifies long-term maintenance by eliminating the need to manually keep the list of HEC URLs specified in SC4S current. Set up a load balancer using virtual IP and configured for https round-robin without sticky session.
* If a load balancer is not available, you can configure a list of HEC endpoint URLs with native syslog-ng load balancing. For internal load balancing of syslog-ng you should:
* Load balance ten or fewer indexers.
* Bse HEC exclusively for syslog.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* Bse HEC exclusively for syslog.
* Use HEC exclusively for syslog.

@mstopa-splunk
Copy link
Contributor

@jenworthington ready for the next iteration

- Refer to [Splunk Cloud](http://docs.splunk.com/Documentation/Splunk/7.3.1/Data/UsetheHTTPEventCollector#Configure_HTTP_Event_Collector_on_managed_Splunk_Cloud)
or [Splunk Enterprise](http://dev.splunk.com/view/event-collector/SP-CAAAE6Q) for specific HEC configuration instructions based on your
To set up syslog processing with SC4S, perform the following tasks in your Splunk instance:
1. Create indexes within Splunk.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please check how mkdocs renders documentation: https://splunk.github.io/splunk-connect-for-syslog/2417/gettingstarted/getting-started-splunk-setup/

in this case we need a newline before the list else we get:
image

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added a new line before the steps. I don't see it rendering though, am i doing it wrong?

To set up syslog processing with SC4S, perform the following tasks in your Splunk instance:
1. Create indexes within Splunk.
2. Configure your HTTP event collector.
3. Create a load balancing mechanism.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Point 3 is not a separate point, it's rather a subsection of configuring HTTP event collectors. And Splunk Cloud users don't have to worry about it at all


* `email`
* `epav`
* `epintel`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you also add fireeye and gitops?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jenworthington can you please add these two indexes too?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

docs/gettingstarted/k8s-microk8s.md Outdated Show resolved Hide resolved
@mstopa-splunk
Copy link
Contributor

mstopa-splunk commented May 8, 2024

@jenworthington something went wrong and your changes to docs/gettingstarted/getting-started-splunk-setup.md from the last pass were not commited. I opened all previous comments again, please go through them and commit the final pass, I'm sorry for that situation

I made these changes a while back but maybe i did something weird with the branching? So I redid them and hopefully second time is the charm. ;)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants