sendmail[2525]: My unqualified host name (servername) unknown

If you see these messages in your syslog, your sendmail is not configured correctly with the domain name. If you are sending from a fully qualified domain, add it to the local-host-names file. In Ubuntu, it would be /etc/mail/local-host-names. Make sure it reads something like this.

[server name]

Now in the /etc/hosts, make sure it reads the following. [] [server name] localhost


sudo /etc/init.d/sendmail restart

and the error should not continue filling the syslog.