Deployment Architecture

Unable to stop splunk

rdelhorbe
New Member

I run Splunk as a non-root user named splunk

When I try the command /opt/splunk/bin/splunk stop I get :

Stopping splunkd...
Shutting down. Please wait, as this may take a few minutes.
Failed to stop Splunkd.service: The name org.freedesktop.PolicyKit1 was not provided by any .service files
See system logs and 'systemctl status Splunkd.service' for details.
Systemd manages the Splunk service. Use 'systemctl stop Splunkd' to stop the service. Root permission is required. Login as root user or use sudo.

I tried run the command as root or as splunk non-root user, nothing change.

0 Karma

badrinath_itrs
Communicator

@rdelhorbe @dm1 , If you are running Splunk as systemd service, then it would be better if you use below command to stop SPLUNK.

 

systemctl stop Splunkd ( # Stop Splunk ) 
systemctl status Splunkd ( # Status Splunk )
systemctl start Splunkd ( # Start Splunk )

If you have not setup SPLUNK properly to run as systemd service you would need to login with root user to stop it. 

Refer this page for more details as how to properly configure Splunk to run as systemd service. 

https://docs.splunk.com/Documentation/Splunk/8.2.3/Admin/RunSplunkassystemdservice

dm1
Contributor

facing the same issue. were you able to fix this ?

0 Karma

muralikoppula
Communicator

find and kill any lingering processes that contain "splunk" in their name

kill -9 `ps -ef | grep splunk | grep -v grep | awk '{print $2;}'`

and then perform splunk service restart/start as splunk

Hope this helps....

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Agent Mode Engaged! Enchaining Agentic Operations with Splunk AI Assistant 2.0

    Are you ready to transform how your team handles complex data requests? We invite you to our upcoming ...

Announcing Modern Navigation: A New Era of Splunk User Experience

We are excited to introduce the Modern Navigation feature in the Splunk Platform, available to both cloud and ...

Modernize your Splunk Apps – Introducing Python 3.13 in Splunk

We are excited to announce that the upcoming releases of Splunk Enterprise 10.2.x and Splunk Cloud Platform ...