Friday, March 5, 2010

Controlling MLB NexDef on Mac OS X

NexDef / Autobahn is an obnoxious bit of software that be default sets it self up to run continously sucking up cpu and memory (800 - 1000 MB on my 2G mac when not in active use by me). Here are directions on how to start and stop it on demand. NexDef (I assume non-mlb branded autobahn works the same) uses launchd to spawn and respawn. To stop this edit the plist file the installer created, ~/Library/LaunchAgents/com.swarmcast.mlbnexdefautobahn.plist. Change the KeepAlive and RunAtLoad values from 'true' to 'false'. Reboot (I'm not an launchd expert, so this is the easiest way I know to reload the config). Now you will use launchctl to start and stop nexdef. The commands are:

launchctl start com.swarmcast.mlbnexdefautobahn

launchctl stop com.swarmcast.mlbnexdefautobahn

You could also change the Label in the plist file if you want a shorter command to type (I create aliases).

Here is a copy of my com.swarmcast.mlbnexdefautobahn.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">
<string>/Users/jamesb/Library/Application Support/Swarmcast/</string>
<string>/Users/jamesb/Library/Application Support/Swarmcast</string>