If you’ve needed to fully reset Profile Manager and you’re running OS X El Capitan and the server app version 5.1.5, you’ll not find a whole lot of information. Luckily the process is almost exactly the same as outlined for Mavericks in this official Apple support page. We only have to change the last line, because the shell script it refers to has moved in El Capitan. Follow these steps to fully reset the Profile Manager:
sudo serveradmin stop devicemgr
sudo serverctl disable service=com.apple.DeviceManagement.devicemgrd
sudo serverctl disable service=com.apple.DeviceManagement.postgres
sudo mv /Library/Server/ProfileManager/Config/ServiceData/Data/PostgreSQL ~/.Trash
sudo mv /Library/Server/ProfileManager/Config/ServiceData/Data/backup ~/.Trash
I hope this helps you out. Let me know if there are any problems.
Great help, but I found with Server 5.1.7 the last command needed to be run from within ‘/Applications/Server.app/Contents/ServerRoot/usr/bin’ otherwise an error would be reported:
‘could not identify current directory: Permission denied
The program “postgres” is needed by initdb but was not found in the
same directory as “initdb”.
Check your installation.’