|
|
Avoid Western Digital external drives' built-in spin down
I effectively did something very similar to this to make that damn drive not spin down (it's where I store all the files I serve to my PS3...so it was really annoying).
My solution was not to write a script, but rather to just call touch on the hidden file directly through the launch agent. Here's the plist: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>Label</key> <string>com.xaren.touchApollo</string> <key>ProgramArguments</key> <array> <string>touch</string> <string>/Volumes/Apollo/.touch</string> </array> <key>RunAtLoad</key> <true/> <key>StartInterval</key> <integer>60</integer> </dict> </plist> My MyBook drive is called Apollo. Since I'm not overly concerned about logging, if the drive isn't there then I'm not terribly worried about any log messages this may produce. Save the file in ~/Library/LaunchAgents and either load it using launchctl load /path/to/agent.plist and you should be good to go. I figured out my solution when I needed it. The above solution is better than mine, but I thought I'd share anyway :) Adam. ---
Avoid Western Digital external drives' built-in spin down
Instead of touching
/Volumes/Apollo directly, you could avoid any logged errors by saying [[ -w /Volumes/Apollo ]] && touch /Volumes/Apollo. I wonder if you need to wrap each "word" in a separate "<string> .. </string>" clause.
|
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.05 seconds |
|