0

for some reason my sendmail is not able to send mails from my virtual server at Hetzner via sendmail.

In my /etc/mail/aliases config look like:

mailer-daemon: postmaster
postmaster: root
nobody: root
hostmaster: root
usenet: root
news: root
webmaster: root
www: root
ftp: root
abuse: root
noc: root
security: root
fail2ban: root
root: hetzner

It seems be ok because it tries to send the mail then, but log shows:

Aug  9 10:11:47 mydomain sm-mta[16537]: u798BllJ016535: to=<fail2ban@mydomain>, delay=00:00:00, mailer=local, pri=123469, dsn=5.1.1, stat=User unknown
Aug  9 10:11:47 mydomain sm-mta[16537]: u798BllJ016535: to=hetzner, ctladdr=root (8/0), delay=00:00:00, mailer=local, pri=123469, dsn=5.1.1, stat=User unknown
Aug  9 10:11:47 mydomain sm-mta[16537]: u798BllJ016535: u798BllJ016537: postmaster notify: User unknown
Aug  9 10:11:48 mydomain sm-mta[16537]: u798BllJ016537: to=hetzner, ctladdr=root (8/0), delay=00:00:01, mailer=local, pri=0, dsn=5.1.1, stat=User unknown
Aug  9 10:11:48 mydomain sm-mta[16537]: u798BllJ016537: to=hetzner, ctladdr=root (8/0), delay=00:00:01, mailer=local, pri=0, dsn=5.1.1, stat=User unknown
Aug  9 10:11:48 mydomain sm-mta[16537]: u798BllJ016537: u798BllK016537: return to sender: User unknown
Aug  9 10:11:48 mydomain sm-mta[16537]: u798BllK016537: to=hetzner, ctladdr=root (8/0), delay=00:00:00, mailer=local, pri=0, dsn=5.1.1, stat=User unknown
Aug  9 10:11:48 mydomain sm-mta[16537]: u798BllJ016537: Saved message in /var/lib/sendmail/dead.letter

(I hide my domain name in the logfile. but it's configured in /etc/mail/local-host-names and /etc/hosts)

closed as off-topic by Stephen Harris, Kusalananda, Shadur, Stephen Kitt, Jeff Schaller Aug 9 '16 at 15:05

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – Stephen Harris, Kusalananda, Shadur, Stephen Kitt, Jeff Schaller
If this question can be reworded to fit the rules in the help center, please edit the question.

  • Have you run newaliases after adding fail2ban to your /etc/aliases file? – Anthon Aug 9 '16 at 9:09
  • actually not directly, but i tried to configure sendmail with sendmailconfig. as far as i know this gets invoked then. – tl-photography.at Aug 9 '16 at 9:15
  • i trashed sendmail and switched to postfix. work there now – tl-photography.at Aug 9 '16 at 10:28
0

Your sendmail sends message to local user/mailbox named hetzner. Your sendmail reports the OS account does not exist.

You may define alias to non local email address e.g.

# forward message to local account/mailbox named "archive" and to non local email
hetzner: archive,john.doe@example.net
# sendmail specific hack to deliver to local account and send a copy
user: \user,jane.doe@example.org

see "man aliases"

  • If you need extra information from the OP, please use the comments below the original post. – Anthon Aug 9 '16 at 9:58
  • i thought that my VM provider (hetzner) configured that so that it will work. The local account hetzner doe not exists and i want that my server send mail that goes to root goes to my private address. can i configure it like root: myprivate@adress? – tl-photography.at Aug 9 '16 at 10:08

Not the answer you're looking for? Browse other questions tagged or ask your own question.