MacOS – /System/Library/LaunchDaemons/com.apple.servermgrd.plist Is Missing – Causing postgres to not start properly

mac-minimacospostgresqlserver.app

I recently updated my Mac Mini Server to Yosemite and the Server app 4.0. When I tried to verify that Postgres is available by executing sudo serveradmin fullstatus postgres I get the following error:

postgres:error = <62706c69 73743030 d4010203 04050618 19582476 65727369 6f6e5824 6f626a65 63747359 24617263 68697665 72542474 6f701200 0186a0a4 07081112 55246e75 6c6cd409 0a0b0c0d 0e0f1056 4e53436f 64655a4e 53557365 72496e66 6f584e53 446f6d61 696e5624 636c6173 73100180 00800280 035f1014 636f6d2e 6170706c 652e7365 72766572 6d677264 d2131415 165a2463 6c617373 6e616d65 5824636c 61737365 73574e53 4572726f 72a21517 584e534f 626a6563 745f100f 4e534b65 79656441 72636869 766572d1 1a1b5472 6f6f7480 0108111a 232d3237 3c424b52 5d666d6f 7173758c 919ca5ad b0b9cbce d3000000 00000001 01000000 00000000 1c000000 00000000 00000000 00000000 d5>
postgres:errorDescription = "The operation couldn’t be completed. (com.apple.servermgrd error 1.)"
postgres:errorCode = 1

When I attempted to execute sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.servermgrd.plist I got the following error:

/System/Library/LaunchDaemons/com.apple.servermgrd.plist: No such file or directory

I tried doing the same in /Library/Preferences/com.apple.servermgrd.plist and got the following error:

/Library/Preferences/com.apple.servermgrd.plist: Invalid or missing service identifier

My guess is that the first file is the one it's trying to access which is missing. I'm not sure what deleted the file. How can I create this file? I have websites using the Web Service that are down.

I guess if I cannot figure it out I will restore to the backup right before I upgraded to Yosemite on both my servers. Oh well.

Best Answer

"Invalid or missing service identifier" seems to mean that your plist file has not got or has misspelled a section like

<key>Label</key>
<string>com.foo.bar</string>

Note "Label" must start with upper case L.