Where does an ubuntu machine get the default domain to append to users when sending mail? Ours is currently sending as [email protected], while /etc/mailname has mail.example.com set. Should this not be sending as [email protected]? I'm using exim4, and I've dpkg-reconfigure'd it so that the system mail name, and the visible domain name are both set to mail.example.com.
--edited to include mailserver--
Most mail servers will chop off the first part of the mail server name (i.e. pop, pop3, smtp, imap, mail) to get what it should put after the @ sign in the email address.
Without knowing the email server you are using, it is hard to give a recommendation on how to change this. I assume a form of Linux, but you should really give more detail.
In the default configuration on an Ubuntu / Debian box, the contents of /etc/mailname is used. It can, of course, be overridden in the actual config file for exim, postfix, etc.
Just to be on the safe side - you haven't accidentally set a mail address for the user in /etc/email-addresses?