LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Mail to accounts on local server disappears.. (https://www.linuxquestions.org/questions/linux-server-73/mail-to-accounts-on-local-server-disappears-519895/)

marcussmit 01-16-2007 03:18 PM

Mail to accounts on local server disappears..
 
Hello,

On my server i can send mail to external accounts as well as accounts to virtual domains on this server, but email to accounts locally on the server disappears.

When i mail to 'root', the mail seems to be sent, but no mail arrives.

Who can tell me where to look and find a solution to this problem?

Thanks in advance for any help.

Kind regards,
Marcus Smit

Russell Griffiths 01-16-2007 11:02 PM

Do you send to 'root' etc, or root@mydomain.com.au
the second should work as is,
but the first may need a rule change to work

or you may have an error in your LOCAL_RELAY macro in your config file.
The manual says ..
'Unless you specify otherwise in the LOCAL_RELAY macro, any address that is a username without any @host part is delivered using the 'local' delivery agent.'

it adds that even if LOCAL_RELAY points at another machine to handle local addresses, 'root' will ALWAYS be delivered on the local machine, so the fact that root's mail is NOT arriving, leads me to think you haven't specified a local delivery agent.

at your root prompt, type 'sendmail -bt' to enter rule checking mode, and get the '>' prompt
at this prompt, type =M to list the mailers loaded.
you should see entries for mailers .. 0 (program), 1 (file), 2 (Include0, 3 (Local), 4 (smtp), 5 (esmtp), 6 (esmt8), 7 (dsmtp), and 8 (relay).
Some may be excluded if thats what you specify in the config file, but Mailer 3 HAS to be there f local mail is to be delivered.

If it's not, re-edit the sendmail.mc file to include a line MAILER('local'), and recompile.

marcussmit 01-17-2007 02:19 AM

Thank you for your response!

Quote:

Originally Posted by Russell Griffiths
Do you send to 'root' etc, or root@mydomain.com.au
the second should work as is,
but the first may need a rule change to work

Yes, i've tried sending to 'root', 'root@$HOSTNAME', 'root@FQDN' and even 'root@ipaddress'.

Quote:

Originally Posted by Russel Griffiths
or you may have an error in your LOCAL_RELAY macro in your config file.
The manual says ..
'Unless you specify otherwise in the LOCAL_RELAY macro, any address that is a username without any @host part is delivered using the 'local' delivery agent.'

It is exactly that what isn't working. How can i check if the local mail delivery agent receives mail and how can i see if it tries to save mail in /var/mail/root ?

Quote:

Originally Posted by Russel Griffiths
it adds that even if LOCAL_RELAY points at another machine to handle local addresses, 'root' will ALWAYS be delivered on the local machine, so the fact that root's mail is NOT arriving, leads me to think you haven't specified a local delivery agent.

Postfix uses a file named 'local_domains'. The secondlevel domainname is mentioned in the file, but local hostname is not. It shouldn't, does it?

Quote:

Originally Posted by Russel Griffiths
at your root prompt, type 'sendmail -bt' to enter rule checking mode, and get the '>' prompt
at this prompt, type =M to list the mailers loaded.
you should see entries for mailers .. 0 (program), 1 (file), 2 (Include0, 3 (Local), 4 (smtp), 5 (esmtp), 6 (esmt8), 7 (dsmtp), and 8 (relay).
Some may be excluded if thats what you specify in the config file, but Mailer 3 HAS to be there f local mail is to be delivered.

Sorry, i should have mentioned i'm using Postfix. I also should have mentioned that the problem first appeared when the server was moved from one datacenter to another. I díd however add Mailer('local') to sendmail.m4 and compile the file.

Quote:

Originally Posted by Russel Griffiths
If it's not, re-edit the sendmail.mc file to include a line MAILER('local'), and recompile.

I'll try that tonight.. Thanks again!!


All times are GMT -5. The time now is 08:01 AM.