- I cannot sync my contacts with macOS Server anymore.
- pythonwrapper cpu usage is high.
- "Unable to verify account or password."
- There are hundreds of addressbook groups called "addressbook".
Attention: This will only backup the calendar and addressbook data. If you use other macOS server services, make sure to backup their data as well!
brew uninstall postgresql
.- Backup calendar and addressbook data.
- Move Server.app to Trash.
- Remove server data.
- Re-Install Server.app from the Mac App Store.
- Restore calendar and addressbook data.
- Make sure that there's no "&" in the full name of the users (CoreDAVErrorDomain error 3).
- Run a script to remove the "addressbook" groups.
sudo mv "/Library/Server/Calendar and Contacts/Data" /my/backup/location
sudo mv "/Library/Server/Calendar and Contacts/Data" "/Library/Server/Calendar and Contacts/Data.blank"
sudo cp /my/backup/location "/Library/Server/Calendar and Contacts/Data"
sudo chown -R _calendar "/Library/Server/Calendar and Contacts/Data"
sudo rm -r /.ServerBackups
sudo rm -r /var/db/.ServerSetupDone
sudo rm -r /Library/Preferences/com.apple.serverd.plist
sudo rm -r /Library/Preferences/com.apple.servermgr_accounts.plist
sudo rm -r /Library/Preferences/com.apple.servermgr_certs.plist
sudo rm -r /Library/Preferences/com.apple.servermgr_info.plist
sudo rm -r /Library/Preferences/com.apple.servermgrd.plist
sudo rm -r /Library/PrivilegedHelperTools/com.apple.serverd
sudo rm -r /Library/Server
Credit: http://apple.stackexchange.com/a/179726/62173
To remove the hundreds of addressbook groups, which have all the same name "addressbook", open the Apple Script Editor and run the following script:
set counter to 0
display dialog "Name of group to delete?" default answer ""
set theGroupName to text returned of result
tell application "Contacts"
repeat
try
set theGroup to group theGroupName
delete theGroup
set counter to counter + 1
on error
exit repeat
end try
end repeat
save
display dialog "Removed " & counter & " instances of the group" with icon caution buttons {"OK"} default button "OK"
end tell
When asked, enter the group name "addressbook".
Credit: http://apple.stackexchange.com/a/65846/62173
"Removed 2498 instances of the group" — yeehaaa!