Scenario Based Splunk Admin Interview Questions
Scenario Based Splunk Admin Interview Questions
Scenario Based Splunk Admin Interview Questions
Table of Contents
Prerequisites 6
Q1: What happens, If Cluster Master down 6
Q2: What happens, If one of the Indexers down in 3-member cluster 6
Q3: What happens, If two of the Indexers down in 3-member cluster 6
Q4: What happens, If all of the Indexers down in 3-member cluster 7
Q5: What happens, If one of the Search Heads down in 3-member cluster 7
Q6: What happens, If two of the Search Heads down in 3-member cluster 7
Q7: What happens, If all of the Search Heads down in 3-member cluster 7
Q8: What happens, If Deployer is down 7
Q9: What happens, If Monitoring Console down 8
Q10: What happens, If Deployment Server is down 8
Q11: What happens, If Universal Forwarder is down 8
Q12: What happens, If License Master/Server is down 8
Q13: How to Decide number of Search Heads & Indexers 8
Q14: How to Choose a Forwarder? (UF or HF) 8
Q15: Why do we need an Intermediate Forwarder? (IF) 9
Q16: Do we need License for Forwarders? 9
Q17: Why can’t we use a single Splunk instance with huge size, instead of Search
Head, Indexer, Universal Forwarder separately? 9
Q18: How Splunk Stores Indexes? 9
Q19: Is it possible to open the flat files in notepad++? 9
Q20: Is it possible to rename the Index? If yes, how? If not, why? 10
Q21: How to clean the Index in a Standalone Splunk instance & Indexer Cluster? 10
Q22: How to migrate index from one Splunk server to another Splunk server? 10
@splunkmania #splunkmania
2
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
Q43: What happens when you remove the stanza from indexes.conf & restart the
Splunk? 18
Q44: What happens when the Disk is full? Index is full? 18
Q45: What is SmartStore in Splunk? 19
Q46: Does Splunk Support SSO/SAML? How to configure them? 19
Q47: How to enable SSL in Splunk? Is it possible to use custom SSL Certificates? 20
Q48: How to restrict users to specific index/data? 20
Q49: How to collect logs from AWS? or how to integrate Splunk with AWS? 20
Q50: How to connect/integrate Databases with Splunk? 20
Q51: How to integrate ServiceNow with Splunk? 21
Q52: How to get logs from Windows (or) Linux? 21
Q53: How to Anonymize/ Normalize/ Mask data in Splunk? 22
Q54: How to index the same data into 2 different indexers? 23
Q55: Other than Forwarders, what are all the ways the data can be onboarded to
Splunk? 24
Q56: How to upgrade Splunk Apps? 24
Q57: How to install Apps from Splunk base? 24
Q58: How to index log files into Splunk? 25
Q59: How to index custom CSV files into Splunk? 25
Q60: How index Json files into Splunk? 26
Q61: How to connect UF with Indexer? 26
Q62: How to connect Search Head with Indexer? 27
Q63: What happens in a distributed environment, under the hood/behind the screen,
when a user runs a query in Search Head? 28
Q64: Can Search Head store/index the data? 28
Q65: Can Forwarders store/index the data? 28
@splunkmania #splunkmania
4
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
@splunkmania #splunkmania
5
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
Prerequisites
● Basic understanding of Splunk Components & their functions
Notice: This Document provides a few examples of scenario-based questions one can expect in
an interview, but not limited to.
To deal with the possibility of a downed master, you can configure a stand-by master that can take
over if needed.
● Searches can continue across the cluster after a node goes down; however, searches will
provide only partial results until the cluster regains its valid state
@splunkmania #splunkmania
6
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
@splunkmania #splunkmania
7
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
@splunkmania #splunkmania
8
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
Q17: Why can’t we use a single Splunk instance with huge size,
instead of Search Head, Indexer, Universal Forwarder
separately?
● For POC or Small deployment, Single Splunk Instance will be a good choice
● But for large scale of data and the greatest number of users,
o It will be a single point of failure
o When it comes to scaling, the 3 functions of Splunk (Input, Index, Search) can’t be
scaled separately as needed.
● In the real scenario, the Splunk dashboards can’t be created & managed, in the data source
itself.
@splunkmania #splunkmania
9
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
Note: This procedure works only on the standalone instance of Splunk, not in the Indexer Cluster
● In Indexer cluster,
o Add lower retention policy (say 10 seconds) to the respective index stanza
o Deploy the bundle to Indexer Cluster
o Wait for a few mins for the changes to take effect, after a few mins the data will be
cleaned. (You can verify the same from the Splunk Web/UI)
Note: This way of cleaning data is preferred only in dev environments. Please try to avoid this in
production environment
/opt/splunk/var/lib/splunk/test_index/
Note: Make sure the Splunk service is stopped & all the hot buckets are rolled to warm, to avoid any
data loss.
@splunkmania #splunkmania
10
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
/opt/splunk/etc/
/opt/splunk/var/lib/
● Take the backup of below directories (In Splunk Universal Forwarder installation)
/opt/splunkforwarder/etc/
/opt/splunkforwarder/var/lib/
● The reason behind taking the backup is to have a plan for failure scenarios. This backup will
help in restoring the configurations & data stored in Splunk
Note: Taking backup will differ based on the Splunk component, depending upon the purpose it’s
being used. (Detailed discussion will be needed during the architecture planning to come up with the
requirement for backup)
Note: Make sure you read the prompts in between & understand the impact, before you proceed with
the upgrade.
Note: The above-mentioned procedure is when you choose to upgrade all tier at once, this is not the
only way to upgrade Splunk Clustered environment. There are other ways, which you can try by
referring the Splunk Docs
Note: Make sure you read the prompts in between & understand the impact, before you proceed with
the upgrade.
/opt/splunk/etc/shcluster/apps/
Note: shcluster-bundle command has various parameters, based on your use case you can select the
parameters, such as preserving lookups, merging local to default, etc,.
@splunkmania #splunkmania
12
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
/opt/splunk/etc/master-apps/
● Validate the bundle and check whether a restart is necessary using below command in Cluster
Master
● Push the configuration bundle to Indexers using below command in cluster master
[tcpout:my_indexers]
server=mysplunk_indexer1:9997, mysplunk_indexer2:9996
[tcpout-server://mysplunk_indexer1:9997]
(or)
● If it’s a Heavy Forwarder you can also try Splunk web/UI, go to settings >> Forwarding &
Receiving >> Configure receiving >> Add New >> Enter the details of Indexer and save it.
Good for monitoring files or directories and Good for receiving data directly from an
transforming data application.
@splunkmania #splunkmania
13
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
A Full Splunk instance that handles inputs HEC is a one way (among many) in
and sends data to a Splunk Indexer which you can bring data to Splunk
In other words, HF is a machine / tool and HEC is a function of this machine / tool
Colocate with
Management component
LM
MC? DS? CM? Deployer? Indexer? Search head?
?
@splunkmania #splunkmania
14
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
Q34: How to reduce license usage in Splunk? How & where the
license usage is being calculated?
● To reduce license usage, filter the unwanted data in the Input phase itself & index only
required data.
● The measured data volume is based on the raw data that is placed into the indexing pipeline.
It is not based on the amount of compressed data that is written to disk. Because the data is
measured at the indexing pipeline, data that is filtered and dropped prior to indexing does
not count against the license volume quota.
@splunkmania #splunkmania
15
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
Q36: Can the Replication Factor be lower than the Search factor?
why?
● No. Replication Factor can’t be lower than Search Factor
● Search Factor talks about how many searchable copies out of the replicated copies (which is
decided by Replication factor). So, it can’t be like 4 searchable copies out of 3 replicated
copies. (This is not realistic)
/opt/splunk/etc/master-apps/
/opt/splunk/etc/master-apps/
● Step-3: Validate the bundle and check whether a restart is necessary using below command in
Cluster Master
● Step-4: Push the configuration bundle to Indexers using below command in cluster master
● Step-5: Login to any one of Indexer & check the indexes list. Settings>>Indexes
@splunkmania #splunkmania
16
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
[default]
maxWarmDBCount = 200
frozenTimePeriodInSecs = 432000
rotatePeriodInSecs = 30
@splunkmania #splunkmania
17
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
● As a deployment's data volume increases, demand for storage typically outpaces demand for
compute resources. SmartStore allows you to manage your indexer storage and compute
resources in a cost-effective manner by scaling those resources separately.
@splunkmania #splunkmania
19
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
@splunkmania #splunkmania
20
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
● When you use Splunk DB Connect, you are creating additional data inputs for Splunk
Enterprise. That is, you're giving Splunk Enterprise more sources of data to consume. Splunk
DB Connect is what connects your relational database data to Splunk Enterprise and makes
that data consumable by Splunk Enterprise.
● In addition, Splunk DB Connect can do the reverse—write Splunk Enterprise data back to
your relational database
● App Link: https://splunkbase.splunk.com/app/2686/
● Procedure Document Link:
https://docs.splunk.com/Documentation/DBX/3.8.0/DeployDBX/AboutSplunkDBConnect
@splunkmania #splunkmania
21
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
● The Splunk Add-on for Windows allows a Splunk software administrator to collect:
o CPU, disk, I/O, memory, log, configuration, and user data with data inputs.
o Active Directory and Domain Name Server debug logs from Windows hosts that act as
domain controllers for a supported version of a Windows Server. You must configure
Active Directory audit policy since Active Directory does not log certain events by
default.
o Domain Name Server debug logs from Windows hosts that run a Windows DNS Server.
Windows DNS Server does not log certain events by default, and you must enable
debug logging.
● App Link: https://splunkbase.splunk.com/app/742
● Procedure Document Link:
https://docs.splunk.com/Documentation/WindowsAddOn/8.1.2/User/AbouttheSplunkAdd-on
forWindows
● Use a regular expression (regex) transform. This method takes longer to configure, but less
complex to modify after the initial configuration. You can also assign this method to multiple
data inputs more flexibly.
Both of these options are also available in Splunk Enterprise, where you can complete the
configuration on either a heavy forwarder or an indexer.
@splunkmania #splunkmania
22
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
[default]
TRANSFORMS-routing=errorRouting
[syslog]
TRANSFORMS-routing=syslogRouting
[errorRouting]
REGEX=error
DEST_KEY=_TCP_ROUTING
FORMAT=errorGroup
[syslogRouting]
REGEX=.
DEST_KEY=_TCP_ROUTING
FORMAT=syslogGroup
In this example, if a syslog event contains the word "error", it routes to syslogGroup, not errorGroup.
This is due to the settings you previously specified in props.conf. Those settings dictated that all syslog
events should be filtered through the syslogRouting transform, while all non-syslog (default) events
should be filtered through the errorRouting transform. Therefore, only non-syslog events get
inspected for errors. Edit $SPLUNK_HOME/etc/system/local/outputs.conf to define the target
groups.
[tcpout]
defaultGroup=everythingElseGroup
[tcpout:syslogGroup]
server=10.1.1.197:9996, 10.1.1.198:9997
@splunkmania #splunkmania
23
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
[tcpout:errorGroup]
server=10.1.1.200:9999
[tcpout:everythingElseGroup]
server=10.1.1.250:6666
syslogGroup and errorGroup receive events according to the rules specified in transforms.conf. All
other events get routed to the default group, everythingElseGroup.
Q55: Other than Forwarders, what are all the ways the data can
be onboarded to Splunk?
● HTTP Event Collector
● Manual Upload through “Add Data” option from UI
● Custom streaming commands
● Summary indexing
● Splunk DB Connect, etc.
● Method-2
o Step-1: Download the required app from Splunkbase to your laptop
o Step-2: In Splunk UI/Web, Go to Manage Apps, click on “Install app from file” & upload
the app (if the app already present, select the checkbox which says “upgrade this app,
if already exists”)
o Step-3: click on “Install” button
o Step-4: Once the app is installed, restart the Splunk (If applicable).
@splunkmania #splunkmania
24
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
[monitor:///var/log/messages]
disabled = 0
index = test_index
● Method-3: Execute CLI command as shown below (e.g., to index /var/log/messages log file)
[structuredCSVDataProps]
FIELD_DELIMITER=,
HEADER_FIELD_DELIMITER=\s
FIELD_QUOTE="
[monitor:///opt/test/data/StructuredData/sample_data.csv]
sourcetype=structuredCSVDataProps
● Method-3: Execute CLI command as shown below (e.g., to index sample_data.csv file)
(Assuming the sourcetype “structuredCSVDataProps” is already created)
@splunkmania #splunkmania
25
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
[monitor:///tmp/sample_data.json]
disabled = 0
index = test_index
sourcetype = _json
● Method-3: Execute CLI command as shown below (e.g., to index /tmp/sample_data.json log
file)
[tcpout]
defaultGroup=myIndexerGroup
[tcpout:myIndexerGroup]
server=10.128.72.25:9997, 10.128.72.26:9997
[tcpout-server://10.128.72.25:9997]
[tcpout-server://10.128.72.26:9997]
● Method-3: Execute CLI command as shown below (e.g., to connect to the indexers with IP –
10.128.72.25 & 10.128.72.26)
@splunkmania #splunkmania
26
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
● Then, under “Distributed search”>> “Search peers” >> Click “+ Add new”
● On the next screen, enter the details such as Peer URI (this refers to Indexer URI), and the
authentication details (Service account created in Step-2), then click on “Save” button as
shown below
● Once the details are added, it will be listed under “Search Peers” page
@splunkmania #splunkmania
27
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
● After completing all above steps, go to Search head, open “Search & Reporting” app, then run
below query to see the results from all 3 Splunk nodes (Heavy Forwarder, indexer & Search
Head) 🡪 with Time Range of “Last 15 minutes”
Index=_internal
● The results of the above query will have data from 3 hosts. This shows the connection
between all 3 Splunk nodes (Heavy Forwarder, indexer & Search Head) are live.
[tcpout]
defaultGroup=myIndexerGroup
indexAndForward = true
● “indexAndForward = true” means, the data will be stored in Forwarder also, while the same
being sent to indexer
/opt/splunk/var/lib/splunk/
(or)
$SPLUNK_HOME/var/lib/splunk/
/opt/splunkforwarder/var/lib/splunk/fishbucket/
o This method will re-index whole data which forwarder indexed earlier, this method is
not preferred in production
● Method-2: Reset the fishbucket for the specific file in the Forwarder
@splunkmania #splunkmania
29
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
[monitor:///var/log/messages]
disabled = 0
index = test_index
crcSalt = sometext
@splunkmania #splunkmania
30
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
Link:
http://docs.splunk.com/Documentation/Splunk/6.5.3/Indexer/Updatepeerconfiguratio
ns
@splunkmania #splunkmania
31
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
/opt/splunk/bin/splunk restart
@splunkmania #splunkmania
32
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
o Log into the instance on which you want to configure the monitoring console. The instance
by default is in standalone mode, unconfigured.
o In Splunk Web, select Monitoring Console > Settings > General Setup.
o Click Distributed mode.
o Confirm the following:
✔ The columns labeled instance and machine are populated correctly and show unique
values within each column.
✔ The server roles are correct. For example, a search head that is also a license master
must have both server roles listed. If not, click Edit > Edit Server Roles and select the
correct server roles for the instance.
✔ If you are using indexer clustering, make sure the cluster master instance is set to the
cluster master server role. If not, click Edit > Edit Server Roles and select the correct
server role.
● Click Apply Changes.
The set of updates that the deployment server The set of updates that the deployer
distributes is called the configuration files and distributes is called the configuration bundle,
apps, to deployment clients. to search head cluster members
Mainly used for Forwarder Mainly used for Search Head Cluster Members
You cannot use the deployment server to update indexer cluster peer nodes or search head cluster
members.
Happy Splunking…!!
Any help/support required on the Splunk, please contact the Splunk Mania Team using any one of the
methods mentioned at the end of this document.
@splunkmania #splunkmania
33
Scenario based Splunk Admin Interview Questions (Part-1 & 2) Splunk Mania
References
https://docs.splunk.com/Documentation/Splunk
Contact:
WhatsApp : +919345372209
Email : splunkmania@gmail.com
LinkedIn : https://www.linkedin.com/company/splunk-mania
Facebook : https://www.facebook.com/SplunkMania
Instagram : Splunk Mania (@splunkmania) • Instagram photos and videos
Slack : https://splunkmania.slack.com/
YouTube : Splunk Mania - YouTube
Website : Splunk Mania
@splunkmania #splunkmania
34