0 Members and 1 Guest are viewing this topic.
Hi,Latest upload using "if $(chkconfig --list|grep $item|grep -i ':on' >/dev/null 2>&1) && [ -f /etc/init.d/$item ] ; then" and previous using "if [ -f /etc/init.d/$item ] ; then".That it.
#!/bin/shlist=(named djbdns maradns httpd nginx lighttpd hiawatha php-fpm qmail xinetd mysqld mysql kloxo)for item in ${list[*]}do if [ -f /etc/init.d/$item ] ; then if [ $item == 'qmail' ] ; then /etc/init.d/$item stop /etc/init.d/$item start else /etc/init.d/$item restart fi fidone
Page created in 0.067 seconds with 19 queries.