The environment is FreeBSD 10.2 with default services including sendmail.
Sending a message from one user to another on the system works fine:
mail -s "A message" userb Hi b, this is a. CTRL-D
Which results in:
su - userb you have mail
but, how do you send a message to another server in the network (not hosted on the internet)? e.g.
mail -s "A message" userb@anotherhost mail -s "A message" email@example.com
The remote hosts are configured and working individually as described for the local host above, but the commands don't seem to work for sending to another host. It doesn't error out, but no mail shows up on the other server.
running mail -v -s "A message" firstname.lastname@example.org
250 2.0.0 t9VKPqha007199 Message accepted for delivery userb@remote... Sent (t9VKPqha007199 Message accepted for delivery) Closing connection to [127.0.0.1] >>> QUIT 221 2.0.0 myhost closing connection
t9VKOKhl007191 (Permission denied)