User Tools

Site Tools


linux:bash:example:autorestart-httpd

Bash Script Auto Restart HTTPd Apache Directadmin

Berikut ini adalah contoh script auto restart apache pada control panel hosting directadmin

#!/bin/sh
status=$(wget -qO- http://localhost)
echo $status
if [[ $status = *"Apache is "* ]];
then
        echo "working";
else
        echo "httpd down - restart httpd"
        /etc/init.d/httpd restart
        echo "done"
fi

Layanan

Harga Domain .COM | Harga Domain .ID | Shared Hosting | Email Hosting | MySQL Hosting |
linux/bash/example/autorestart-httpd.txt · Last modified: 2018/05/30 02:24 by kbadmin

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki