I am using Mac OS X Server on Mac OS X Mavericks to manage the Apple devices at our school. Specifically – I set up the dock icons exactly how I wanted them arranged. I then uploaded the com.apple.dock.plist to profile manager. It detected all of the settings and everything was find until I clicked “Save.” Immediately after that – I was no longer able to load the device groups page and I got the dreaded “A Server Error Has Occurred” and to “Contact my system administrator if the problem persists”.
No matter what I did – I could not get the page to load. I knew it had to be a corrupt profile as it happened immediately after I pressed save. Resetting profile manager to default was not an option as I had many other profiles loaded already and didn’t want to lost them.
There is a postgressql database that stores all the profiles. I went in and manually deleted the profile for the device group that I had created and that fixed the issue. I believe these commands will only work on OS X Server on Mavericks as the database is in a different location then past versions.
1.) Open up Terminal.app
2.) Command to list all of the tables:
sudo psql -h "/Library/Server/ProfileManager/Config/var/PostgreSQL" -U _devicemgr -d devicemgr_v2m0 -c "\dt"
3.) Command to list all profiles so you can find the corrupt one:
sudo psql -h "/Library/Server/ProfileManager/Config/var/PostgreSQL" -U _devicemgr -d devicemgr_v2m0 -c "select * from profiles"
This is going to spit out all the tables – you will need to widen out your Terminal window so you can see everything correctly.
4.) Find the id of the profile that you believe to be the culprit and delete it with the following command:
sudo psql -h "/Library/Server/ProfileManager/Config/var/PostgreSQL" -U _devicemgr -d devicemgr_v2m0 -c "delete from profiles where id=15"