I do not know the service\'s name, but would like to stop the service by checking its status.
For example, if I want to check if the PostgreSQL service is running or no
run
ps -ef | grep name-related-to-process
above command will give all the details like pid, start time about the process.
like if you want all java realted process give java or if you have name of process place the name