Can you please share me the script i can use it a Linux
Can you please share me the script i can use it a Linux
Monitor for what? That it exists / is running?
Which version of Linux?
The following will check if 'apache2' is running on debian(s).
{
#! /bin/bash
if [ $(ps aux | grep apache2 | wc -l) -gt 1 ]; then
echo "Statistic:0"
else
echo "Statistic:1"
fi
exit 0;
}
Change 'apache2' to your service and see if it works for you.
SolarWinds solutions are rooted in our deep connection to our user base in the THWACK® online community. More than 195,000 members are here to solve problems, share technology and best practices, and directly contribute to our product development process.