We recently replaced a failing hard drive on an iMac. After the drive was replaced, we had problems connecting to it through Remote Desktop. We always got an error message about authorization failure. I am pretty sure the username and password were entered correctly. The problem persisted even though I restarted the Remote Management several times.
I found an article on how to fix this problem. The article was published in 2008. Some preferences have changed, but, based off the instructions, I was able to fix the problem on a 10.6 machine. The idea is to stop Remote Management/Desktop on the machine and delete the preferences. All the steps are performed on Terminal or a SSH session.
- Disable Remote Management/Desktop.
sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -deactivate -configure -access -off
- Delete the preferences.
sudo rm -rf /var/db/RemoteManagement/ sudo rm /Library/Preferences/com.apple.RemoteManagement.plist sudo rm -r /Library/Application\ Support/Apple/Remote\ Desktop/
- Restart Remote Management/Desktop
sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -activate -configure -access -on -users username -privs -all -restart -agent -menu