• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
How to control a Launchdaemon
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to control a Launchdaemon


  • Subject: How to control a Launchdaemon
  • From: Jim Weisbin <email@hidden>
  • Date: Tue, 17 Jan 2017 11:51:38 -0500

I maintain a lot of servers, each of which have numerous external drives/arrays attached. Occasionally one of these arrays will go off line (I’ve been having a lot of problems with aging OWC “Qx2” units which simply go off line instead of going into alarm). So I wrote a script (actually an app) that I run every hour using Launchctl, which checks a list of drives that should be mounted, and emails me if any are not mounted. Works fine, but here’s my question: if a drive is off line, I will continue to get an email every hour until I unload the daemon. Or, I could create a file and write to it, then check it as a flag so that it won’t email me if the flag is set. But then I have to manually clear the flag, which seems like just as much trouble as unloading the daemon. I could also possibly unload the daemon from the script itself, not sure if that’s possible. Can anyone think of a better way to handle this?


Jim Weisbin | C.T.O. | Human | Post Human | 27 West 20th Street | Suite 801 | New York, NY | 10011 |  (212) 352-0211 |  (917) 375-2272 | Los Angeles Office | 2046 Broadway | Santa Monica, CA | 90404 |  (310) 264-0211 telephone | 

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: How to control a Launchdaemon
      • From: Tom Robinson <email@hidden>
  • Prev by Date: Re: Coercing ligatures to expanded characters
  • Next by Date: Re: How to control a Launchdaemon
  • Previous by thread: RE: AppleScript-Users Digest, Vol 14, Issue 49
  • Next by thread: Re: How to control a Launchdaemon
  • Index(es):
    • Date
    • Thread