-
admin posted an update 6 years, 6 months ago
How to restart multiple init scripts with a similar name
Lets say you want to quickly restart all /etc/init.d/*courier* scripts, how to do that?
# find /etc/init.d/ | grep courier | while read line; do $line restart; done
Stopping Courier POP3-SSL server: pop3d-ssl.
Starting Courier POP3-SSL server: pop3d-ssl.
Stopping Courier POP3 server: pop3d.
Starting Courier POP3 server: pop3d.
Stopping Courier authentication services: authdaemond.
Starting Courier authentication services: authdaemond.
Stopping Courier IMAP-SSL server: imapd-ssl.
Starting Courier IMAP-SSL server: imapd-ssl.
Stopping Courier IMAP server: imapd.
Starting Courier IMAP server: imapd.