Sometimes you may receive the following error message while trying to get your emails with Mac Mail:
The attempt to read data from the server 'mail.yourdomain.com' failed
To resolve the issue, you should do the following (here we will assume that your mail account is called John Smith):
Start Mail and go to the Mailbox tab > Synchonize "John Smith".
This will resolve the issue and you will be able to get your mails without any problem.