Below Bash script will restart the apache2 service #!/bin/bashRESTART="sudo service apache2 restart"PGREP="/usr/bin/pgrep"APACHE2="apache2"$PGREP ${APACHE2}if [ $? -ne 0 ]then$RESTARTfi
No comments:
Post a Comment