Deployment Architecture

Mask data at indexserver for only some of the indexes

jnhth
Explorer

I want to mask only data in my test indexes (I have both prod and test indexes on 1 indexer server)

Can I do so? As I can see the masking is applied to all my indexes with data from a specified spurcetype.

Ex:
props.conf:
[source::...\access.log*]
sourcetype = access_common

transform.conf:
[access_common]
SE-msi1 = q/(\/eb\/res\/rec\/Number\/\d{2})\d{4}/\1xxxx/

Tags (3)
0 Karma
1 Solution

woodcock
Esteemed Legend

Given your clarification:

Some host are test and some are prod - the filename is the same but the paths are different

Then you can do this:

props.conf:

[source::.../UniqueSegmentOfTestPath/...]
sourcetype = access_common_filter_first

[source::.../UniqueSegmentOfProductionPath/...]
sourcetype = access_common

transform.conf:

[access_common_filter_first]
SE-msi1 = q/(/eb/res/rec/Number/d{2})d{4}/1xxxx/
rename = access_common

View solution in original post

0 Karma

woodcock
Esteemed Legend

Given your clarification:

Some host are test and some are prod - the filename is the same but the paths are different

Then you can do this:

props.conf:

[source::.../UniqueSegmentOfTestPath/...]
sourcetype = access_common_filter_first

[source::.../UniqueSegmentOfProductionPath/...]
sourcetype = access_common

transform.conf:

[access_common_filter_first]
SE-msi1 = q/(/eb/res/rec/Number/d{2})d{4}/1xxxx/
rename = access_common
0 Karma

woodcock
Esteemed Legend

What discriminates test vs. prod? Is there a difference in the path/file? Are some hosts prod and some test?

0 Karma

jnhth
Explorer

Some host are test and some are prod - the filename is the same but the paths are different

0 Karma

somesoni2
Revered Legend

Since both prod and test are on same server and surely, they will have same sourcetype and can have same source, try to setup the masking based on host (in props.conf).

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...