Splunk Enterprise

How to resolve "splunk.service could not be found"?

henryf
Explorer

Trying to install splunk on ubuntu instance within e3, I've partitioned and formatted the drive and every step works fine but whenever I get to the last step I keep running into this issue. How can I solve it?

Labels (1)
0 Karma
1 Solution

isoutamo
SplunkTrust
SplunkTrust

Hi

I add some clarifications on @danspav 's answer.

1st you must start splunk with Splunk User (I expecting that you are using this user for splunk) like

/opt/splunk/bin/splunk start --accept-license --answer-yes

Add splunk's internal admin user + password to it.

Then stop splunk and after that you must switch back to root user to enable boot start.

You could check which name is used for that service by

[root@splunk-demo-rh8] ~>
(0) # systemctl |egrep -i splunk|egrep service
Splunkd.service                                                                     loaded active running   Systemd service file for Splunk, generated by 'splunk enable boot-start'
[root@splunk-demo-rh8] ~>
(0) #

 I expecting that your name is something like splunk. If it't totally different then just ls on @danspav example and find which service file contains command splunk start.

r. Ismo

View solution in original post

henryf
Explorer

Thanks!

0 Karma

danspav
SplunkTrust
SplunkTrust

HI @henryf ,

 

I assume you've run the boot-start command to generate the service file:

./splunk enable boot-start -user splunk -systemd-managed 1

 

You can check what the service name is by looking here:

ls -l /etc/systemd/system

 

On my host it's called splunkd.service so I start splunk by running:

systemctl start splunkd

 

Make sure you match the case and name with the service file.

 

Give that a go and see if it starts. There's more info in docs:
https://docs.splunk.com/Documentation/Splunk/latest/Admin/RunSplunkassystemdservice

 

Cheers,
Daniel

isoutamo
SplunkTrust
SplunkTrust

Hi

I add some clarifications on @danspav 's answer.

1st you must start splunk with Splunk User (I expecting that you are using this user for splunk) like

/opt/splunk/bin/splunk start --accept-license --answer-yes

Add splunk's internal admin user + password to it.

Then stop splunk and after that you must switch back to root user to enable boot start.

You could check which name is used for that service by

[root@splunk-demo-rh8] ~>
(0) # systemctl |egrep -i splunk|egrep service
Splunkd.service                                                                     loaded active running   Systemd service file for Splunk, generated by 'splunk enable boot-start'
[root@splunk-demo-rh8] ~>
(0) #

 I expecting that your name is something like splunk. If it't totally different then just ls on @danspav example and find which service file contains command splunk start.

r. Ismo

Get Updates on the Splunk Community!

A Season of Skills: New Splunk Courses to Light Up Your Learning Journey

There’s something special about this time of year—maybe it’s the glow of the holidays, maybe it’s the ...

Announcing the Migration of the Splunk Add-on for Microsoft Azure Inputs to ...

Announcing the Migration of the Splunk Add-on for Microsoft Azure Inputs to Officially Supported Splunk ...

Splunk Observability for AI

Don’t miss out on an exciting Tech Talk on Splunk Observability for AI! Discover how Splunk’s agentic AI ...