You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Calendar Server error 504 and 'Server with secure communication unavailable'

After upgrade to Yosemite 10.10.4 and server 4.1.3 (from Mavericks and 3.2.2) Calendars became unavailable. I don't seem to get any farther than this error message:


7/26/15 3:15:56.794 PM Calendar[46384]: [com.apple.calendar.iaplugin.log.CalInternetAccountsPlugin] [Autodiscovery error: [Error Domain=CoreDAVHTTPStatusErrorDomain Code=405 "The operation couldn’t be completed. (CoreDAVHTTPStatusErrorDomain error 405.)" UserInfo=0x600000263f80 {CoreDAVHTTPHeaders=<CFBasicHash 0x600000471a80 [0x7fff79c97ed0]>{type = immutable dict, count = 7,

entries =>

0 : Server = Apache

1 : Content-Type = <CFString 0x60800064c240 [0x7fff79c97ed0]>{contents = "text/html; charset=iso-8859-1"}

2 : Allow = <CFString 0x608000450d40 [0x7fff79c97ed0]>{contents = "POST,OPTIONS,GET,HEAD"}

6 : Date = <CFString 0x6080006409f0 [0x7fff79c97ed0]>{contents = "Sun, 26 Jul 2015 19:15:56 GMT"}

10 : Keep-Alive = <CFString 0x608000645490 [0x7fff79c97ed0]>{contents = "timeout=15, max=100"}

11 : Content-Length = 308

12 : Connection = <CFString 0x608000436be0 [0x7fff79c97ed0]>{contents = "Keep-Alive"}

}

}].]



caldavd is not shown as a process in Activity Monitor, but I get these messages on the server.


7/26/15 3:25:44.843 PM com.apple.xpc.launchd[1]: (org.calendarserver.calendarserver) Service only ran for 34 seconds. Pushing respawn out by 26 seconds.

I get no indication that anything to do with Calendar on the Server has been contacted. Open Directory, Kerberos, and User Home Folders working fine. Can ssh in fine.


This produces the same symptoms even if I work only on the Server itself and use the Server Admin user to create a calendar for a local network User (possibly bypassing network configuration issues).


I am perfectly willing to trash all pre-existing Calendars (not using Contacts) and start over. any insights appreciated.

Mac Pro (Early 2009), OS X Yosemite (10.10.3), & MacBook Pro, AppleTalk Printers

Posted on Jul 26, 2015 12:33 PM

Reply
9 replies

Jul 26, 2015 5:35 PM in response to Linc Davis

That certainly helps me commiserate, But I see no resolution on that thread (another user with a different error camped on, then solved their own different problem.)


Is there a known way to initialize the Calendar Server and actually get it to start up and work?


This is what I get from serveradmin:


Last login: Sun Jul 26 15:09:37 on ttys010

b-aassoc:~ OSXSrvAdmin$ sudo serveradmin status calendar

Password:

calendar:setStateVersion = 1

calendar:calendarState = "STARTING"

calendar:state = "STARTING"

calendar:contactsState = "STOPPED"

calendar:readWriteSettingsVersion = 1

b-aassoc:~ OSXSrvAdmin$


Jul 26, 2015 9:21 PM in response to Linc Davis

Doing literally what you said made the server throw a major error at startup. It was not happy about the 'Calendar and Contacts' folder missing.

'Preparing services - CalendarServer' Error Domain:SVCConfigurationErrorDomain Code:2

The Server had an Alert saying the the Volume 'Calendar and Contacts' had not been mounted.


Next, I tried throwing away Server.app, creating a new Calendar and Contacts folder, and retrieving Server.app -- No success. I tried throwing away Server.app, changing the new Folder ownership to 'root', and retrieving Server.app -- still errors. Whenever I attempted to start the service, it just sat for a minute, then the slider moved to OFF.


Then threw away Server.app, went to a Backup and pulled in that folder and the files inside it (owned by _calendar User and _calendar Group) from before the Server upgrade. It had no cluster.pg directory at all. Then retrieved Server.app. This time it worked, and from that old stuff, it created cluster.pg directory and the dozen or so .pg files inside it, and the signal-files that the upgrade was done. Turned on the service inside Server.app and it started up and even indicated it could be seen as an available service from outside the local Network.

sudo serveradmin status calendar

calendar:setStateVersion = 1

calendar:calendarState = "RUNNING"

calendar:state = "RUNNING"

calendar:contactsState = "STOPPED"

calendar:readWriteSettingsVersion = 1

Firing up a User's Calendar, I can now see the cached calendar items, but I cannot refresh them.


I have certainly made progress from 'server unavailable', but am not quite there yet. The hour grows late, I will have to see if I can make more progress later. Thanks for your suggestions.

Jul 27, 2015 1:43 PM in response to Linc Davis

I have been referring to that thread, especially the first post in it. The Terminal serveradmin command has been quite helpful, but as of Server 4, the postgres subcommands are no longer supported inside the serveradmin command. Users should note that in Server 4 and later, commands such as:


sudo serveradmin status postgres

does not work, and does not provide a proper errors message, just four lines of hexadecimal trash.

Jul 27, 2015 5:06 PM in response to Linc Davis

I did try it much earlier. It appears I did not have a failed conversion, but no conversion whatsoever. I was never able to get it to do anything for me, as I did not have any of the cluster.pg subdirectory pieces to feed it. I had only two folders in:


Server/Calendar and Contacts/Data/Database.xpg

backup

working


And working was empty.


But your suggestions of emptying that directory led me to restore it from Backup, and then when Server.app launched, it converted it happily.


My inability to modify items turned out that it had dropped its certificate, and was proffering "none".


Now I am trying the debug the ability to get to delegates. and one computer that needs support for iCal in 10.6.8.

Jul 27, 2015 10:42 PM in response to Grant Bennet-Alder

It appears that delegation information needs to be entered anew. Once it is, things seem to perk up a bit.


For the 10.6.8 Computer, unchecking [√] Use Kerberos seemed to have helped enormously. As I recall 10.6 is still using MIT Kerberos, and 10.7 and later switched to Heimdal Kerberos. Perhaps they are not willing to get along.

Calendar Server error 504 and 'Server with secure communication unavailable'

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.