The OS X version doesn't even need perl!
# ping -c1 hostname || say 'moo!' [download]
In reply to Re: when no ping say 'moo!' by jasonk in thread when no ping say 'moo!' by Discipulus