When installing dovecot you might get this error:
Setting up dovecot-common (1:1.2.9-1ubuntu6.5) ... Creating generic self-signed certificate: /etc/ssl/certs/dovecot.pem (replace with hand-crafted or authorized one if needed). hostname: Name or service not known
What this mean's is that the installer is trying to issue "hostname -f" and it can't resolve your fqdn.
-f, Display the FQDN (Fully Qualified Domain Name). A FQDN consists of a short host name and the DNS domain name. Unless you are using bind or NIS for host lookups you can change the FQDN and the DNS domain name (which is part of the FQDN) in the /etc/hosts file. See the warnings in section THE FQDN above, and avoid using this option; use hostname --all-fqdns instead.
The Fix: vi /etc/hosts 126.96.36.199 example.com example where 188.8.131.52 is your publicly routeable ip address