Surviving macOS server
August 3, 2016 — August 3, 2016
Macos Server is discontinued; this is of historical interest only.
This was split off from general macOS hacks.
How to maintain a high-performance internet-facing server on macOS.
I’m kidding, no-one does that. You are running macOS Server to sync contacts to your phone or intranet because you don’t trust iCloud.
1 Why is my computer behaving generally horribly since I installed Server?
I once enabled Xcode server, and thus my machine is intrusively and eternally hijacked as a build server for The Next Viral iPhone App That I Should Be Building To Shovel Into The Dread Furnaces Of The iTunes Store Atop Mountainview Doom. Symptoms include difficulty shutting down, multiple copies of GUI apps being run by invisible users, and chronic RAM shortage. If you use GUI apps to manage hardware, this will ream you extra hard. (I lost control of my sound card output gain performing on stage on New Year’s Eve. Class.)
Friends don’t let friends run Xcode Server. Instead, p3n an enemy and botnet it. There.
Now, you stop this foolishness on your formerly usable laptop:
2 Stop the damn wiki that why would you use you wouldn’t use it there are better wikis
If you ever install Server.app your debug log becomes filled with hundreds of megabytes of messages that look like this:
com.apple.launchd[1]: (com.apple.collabd.notifications[48293]) Exited with code: 1
com.apple.launchd[1]: (com.apple.collabd.notifications) Throttling respawn: Will start in 10 seconds
If this is annoying you, stop collabd:
serverctl disable service=com.apple.collabd.notifications
serverctl disable service=com.apple.collabd.stats
serverctl disable service=com.apple.collabd.expire
or:
or perhaps:
launchctl unload -w /Applications/Server.app/Contents/ServerRoot/System/Library/LaunchDaemons/com.apple.collabd.plist
This seems to work until reboot, then the entire rigmarole restarts. If you can tell me how to make it stick I’d love to know. Other than setting the computer on fire which I couldn’t guarantee maybe server metrics will keep on like some kind of undead 5-9s uptime zombie.
3 Turn off other server stupidness
servermetricsd using 100% CPU? Temporarily disable it:
sudo serverctl disable service=com.apple.servermetricsd.daemon
sudo serverctl disable service=com.apple.servermetricsd.sample
You can possibly turn it on again later? Then you might get enterprisey bar charts of your iPhone’s connectivity rate, and make tiny PowerPoint presentations of them to show to the flatmates and assorted household pets at sharehouse AGMs. (Thanks infoworld)