#!/bin/bash count=`ps aux | grep "kafka" | grep -v grep -c` if [ $count -eq 0 ]; then echo 'Not running...' else echo 'running...' fi