Here at my work, we have a very large and managed Macintosh environment -- 6,000 MacBooks, 30+ Xserves, and 1,000+ Mac desktops, all in an Open Directory environment. As such, Apple Remote Desktop (ARD) Admin is a very widely-used application for myself and my coworkers. When it works, it is awesome, but over the last year and a half at this deployment, a lot of us have randomly seen ARD Admin fail, for a lack of a better term. Symptoms are constant crashes, hangs when launching, not scanning through certain subnets or VLANs, and it won't connect to certain computers on your network. The way I have seen it happen is at first it becomes sluggish, and the application performs slow, then it goes into crashing and not working down the road. You try to reinstall the application and it gets you nowhere.
In the past, my coworkers have just wiped and reloaded OS X to fix this issue, which is kind of an unacceptable solution in my mind. Just this morning I got hit with the same issues trying to remote into some servers -- the application just hung, and it would lock and I would have to force quit it. I did not want to reload OS X to fix this issue, so I went looking for another solution.
You can't simply trash the ARD Admin application and then reinstall it; that does not work, as ARD Admin puts files and resources in many places. I have compiled a script, which I use in OS X 10.5 with ARD Admin 3.2. The script removes all resources that ARD admin installs on your system, and allows you to reinstall the application like it was a clean install. Here's the code:
#!/bin/sh IFS=$'\t\n' PATH=/bin:/usr/bin export PATH home=~ list=" # Remote Desktop Application /Applications/Remote Desktop.app # ARD Agent Software /System/Library/CoreServices/RemoteManagement /System/Library/CoreServices/Menu Extras/RemoteDesktop.menu # Application Support Files /Library/Application Support/Apple/Remote Desktop # Preferences /Library/Preferences/com.apple.ARDAgent.plist /Library/Preferences/com.apple.RemoteDesktop.plist /Library/Preferences/com.apple.RemoteManagement.launchd /Library/Preferences/com.apple.RemoteManagement.plist # Receipts /Library/Receipts/RemoteDesktopAdmin320.pkg /Library/Receipts/RemoteDesktopAdmin322.pkg /Library/Receipts/RemoteDesktopClient.pkg /Library/Receipts/RemoteDesktopRMDB.pkg # User Items $home/Library/Application Support/Remote Desktop $home/Library/Preferences/com.apple.RemoteDesktop.plist # Reporting Database /var/db/RemoteManagement " for file in $list do if [[ -e $file ]] then rm -rf $file fi done exit
Mac OS X Hints
http://hints.macworld.com/article.php?story=20081017095005445