Bash script to check Linux Service Status

Veeresh Kumar
Sep 10, 2021

I needed to develop a script to check status of any application running on linux and thought of sharing the same which could be useful to anyone looking for the same kind of task.

Here we go !!!!

The below script takes the service name as input and provides the status of it.

Usage:

sudo sh Check_Service_Status.sh <service_name>

  1. Copy the below script to Check_Service_Status.sh

2. Make the script executable by running below command.

chmod +x Check_Service_Status.sh

3. Now execute the script as below

sudo sh Check_Service_Status.sh <Service_Name>

Hope it helps !!!

--

--

Veeresh Kumar

He is a Sr. DevOps Engineer loves to automate cloud infrastructure and App deployments. #Terraform #Azure #Jenkins #Ansible #Chef #Bash #PowerShell #AWS #GCP