This is similar to what gutschik said but with a tad more info...I was having this problem at work yesterday and thought it had something to do with port 993 as well. I talked to the IT guy and he said that port 993 is unblocked. I also have a gmail and yahoo account that both use the same port and I had no issues with those accounts. It appear now that the new iCloud setup sets the default incoming mail server as p03-imap.mai.me.com whereas the Lion version was simply imap.mail.me.com for whatever reason our fortiguard router does not like the p03- part at all. At home I have no issues on a airport setup nor did I have any problems on 4g on my iphone. Both Mail and Notes use the incoing mail server to connect and sync it appears.
The biggest pain in the butt is that you can't simply just go into the prefs and change that setting for some reason(it's greyed out). You have to actually create a fake account that the apple setup can not verify thus taking you to a setting page where you can enter the information manually and remove the p03- part. Once I did that boom, mail started working and so did notes sync, but now I essentially have two different iCloud accounts listed...one for mail and notes and the other being the default apple set up one with everything else. Hope this helps until there is a more permenant solution. If anyone figures out why some routers reject the p03- part please let me know so I can pass this along to the IT guy.
I don't think it has anything to do with the 993-port either. Tried open ports on my Airport Extreme with nothing happening. To me it seems like a hangup at the iCloud servers. I have a old @me account also, and that one works well on everything with all devices in sync. Problem is that I have all my goddies on the other account. I'm aware of the possiblity of running two accounts, but its still a messy setup.
I've tried to mess around with changing primary iCloud-ID with hopes of resetting some iclud settings, but no luck.
Also, when i try setting up the old @me account in Mail.app. It instantly figures out the icloud settings and everything works, in comparison to the other Apple-ID which I set up more or less manually. Mail.app works, but I can't tick off mail/notes in pref.pan.
I'm not an IT guy or know the ins and outs of networking so I'm not sure what you mean by host files. All I know is after trying a dozen different setting yesterday, removing the p03- on my end is the only thing that will work with the configuration we have at work. The IT guy seems equally as baffled...I guess it's possible that it's a setting on the router somehwere but I have no information as far as that goes. This fix as far as I can tell is only for people who use the mail app with icloud in which their service worked perfectly on lion and now only works perfectly on an airport with unblocked ports versus not working upon upgrade to mountain lion whilst being behind a more heavy duty industrial router/firewall like the fortiguard system we have here at work. Like I said, I don't know the complexities of all this but hopefully this will help some people.
I was able to add the accounts to Mail using the tip from fcpguy. By adding the accounts manually I'm able to send and receive messages from all 3 of my accounts.
The problem still persists, though, if I try to set them up as iCloud accounts in System Preferences.
Or as iCloud accounts in Mail itself. It seems as though the setup completes,
but trying to change any information (checking off "Only use this server", editing the Full Name, etc.) will result in the following error:
As you can see from the previous screenshot, the Incoming Mail Server field is populated with "p03-imap.mail.me.com", but it's also greyed out, so there's no way to change it even if I wanted to.
Hope this info helps with anyone else that may be having this issue. Bottom line, the only thing that worked for me was setting up the accounts in Mail, and entering the wrong email address. That will present the manual account add screen, in which you can fill in the correct server addresses. I still can't check off the Mail boxes for these accounts in System Preferences, but at least I'm getting my mail again.
Got the error on Mail, fixed this by opening the Mail app, it then upgrades the database and all was well (I added my iCloud account there too, just to be sure).
I was also getting the Notes error at work, our ISP block IMAP/POP/SMTP ports (of particular relevance seems to be 993), so that personal email doesn't work in clients such as Outlook and Mac Mail. Anyway, I connected my iphone on USB, used the personal hotspot and bingo it worked.
Bottom line is, there definitely seems to be a link to blocked ports, weird thing is this worked in Lion.
MBP 15" Late-2011
At least in my case, I'm pretty sure whats happend is that iOS6 beta 3 forced me to create an @icloud alias on my account to make the mail/notes work. ML on the other hand is not ready for @icloud-adresses yet. This makes sense since if you try to make a new Apple-ID from the ML pref pane, it suggest you an @me-adress.
So the Mountain Lion iCloud pref. pan. wizzard will not recognize the @iCloud- adresses yet. The GM-release did, but not the final release. My guess is that this will be fixed in an update pretty soon.
A workaround to this problem is to set up everything (on all devices) with you're main Apple-ID.
Then add a second iCloud account and log in with a @me-adress and activate only notes.
(In system prefs-> Mail, Contact & Calendars)
If you want mail on the mac, just open Mail.app and set it up manually
On the iOS device, do exactly the same. Set up your main apple account. Uncheck notes/mail. Add a new iCloud account in "Mail, Contacts, Calendar" log in with @me and check only notes/Mail.
Hope this helps.
After two days of total frustration, problem solved. The post about adding the iCloud mail/notes through the mail app rather then the system preferences is dead on. Once I opened mail, clicked on preferences, and clicked the plus sign to add the iCloud account everything worked fine. Now shows up properly in both the iCloud system preferences and the mail system preferences as well as in the mail app itself. Why couldn't the Apple people have just told me this when I called two days ago?
I was able to a get the Mail and Notesapps in ML on my mid-2012 MacBookAir set up to use my iCloud account with no porblems. However, I ran into difficulty setting them up on my late 2009 MacPro.
Similar to you, I was able to associate the Mail account by going through the Preferences->Accounts procedure in the Mail app. However, when I tried a similar trick in the Notes app, I was sent back to the same iCloud preference panel in System Preferences and was unsuccessful with this error message.
I had the same issue - turns out PeerGuarian was blocking the server.
If you have it, remove it from your login items (Users prefs), reboot, and all good.
If you don't, remove everything from login items that may be the cause. I imagine Little Snitch could do the same, so you may want to check your rules.