Bareos unable to send mail

843 views
Skip to first unread message

Umesh Kumar Dubey

unread,
Dec 18, 2017, 6:51:51 PM12/18/17
to bareos-users
Hi,

I have configured bareos on windows server 2016 R2 and its working properly but while backup completed unable to send mail to me on mentioned email id bereos configuration file and also if backup got failed same unable to send mail.

I have already installed send mail on this server and tested from Power shell and CMD,Its working properly but bereos unable to send mail to me.

See below configuration file.

C:\ProgramData\Bareos\bareos-dir.d\messages

1. Daemon.conf

Messages {
Name = Daemon
Description = "Message delivery for daemon messages (no job)."
mailcommand = "C:/Program Files/Bareos/bsmtp -h xxx.xxx.com -f \"\(Bareos\) \<%r\>\" -s \"Bareos daemon message\" %r"
mail = dubeyu...@gmail.com = all, !skipped, !audit # (#02)
console = all, !skipped, !saved, !audit
append = "C:/ProgramData/Bareos/logs/bareos.log" = all, !skipped, !audit
append = "C:/ProgramData/Bareos/logs/bareos-audit.log" = audit
}

Here --> xxx.xxx.com (my mail server name)

2.Standard.conf


Messages {
Name = Standard
Description = "Reasonable message delivery -- send most everything to email address and to the console."
operatorcommand = "C:/Program Files/Bareos/bsmtp -h xxx.xxx.com -f \"\(Bareos\) \<%r\>\" -s \"Bareos: Intervention needed for %j\" %r"
mailcommand = "C:/Program Files/Bareos/bsmtp -h xxx.xxx.com -f \"\(Bareos\) \<%r\>\" -s \"Bareos: %t %e of %c %l\" %r"
operator = dubeyu...@gmail.com = mount # (#03)
mail = dubeyu...@gmail.com = all, !skipped, !saved, !audit # (#02)
console = all, !skipped, !saved, !audit
append = "C:/ProgramData/Bareos/logs/bareos.log" = all, !skipped, !saved, !audit
catalog = all, !skipped, !saved, !audit
}


Here xxx.xxx.com ----> My mail server

Can you please help for this issue ?

Regards,
Umesh Dubey

Bruno Friedmann

unread,
Dec 20, 2017, 11:01:38 AM12/20/17
to bareos...@googlegroups.com
bsmtp is really a simple client, unable to process login and so on...
So check firstly if your mail server accept unauthenticated mail from your bareos instance.

Normally you should be able to find success or failure on your mail server logs.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
Message has been deleted

Bruno Friedmann

unread,
Dec 23, 2017, 8:03:46 AM12/23/17
to bareos...@googlegroups.com
It's certainly more a problem of escaping correctly the command (always tricky how shell do)
you can firstly try to confirm that using bareos bsmtp command it work from command line too.
then try to figure out how the command is really run once passed to the shell.



On December 23, 2017 1:17:10 AM GMT+01:00, Umesh Kumar Dubey <dubeyu...@gmail.com> wrote:
Hi Bruno,

Thanks for reply.

I have tested from Power shell and cmd,mails are successfully delivering from
Windows server (Where has installed Bareos backup installed ) but Bareos unable to send mail.

Ran the mail sent by another command from both PowerShell and CMD as

PowerShell= Send-MailMessage -From "bar...@shipco.com" -To "udu...@shipco.com" -SmtpServer "smtp.shipco.com" -Subject "Test3" -Body "Backup"

CMD= C:/Windows/System32/WindowsPowerShell/v1.0>powershell.exe Send-MailMessage -From "bar...@shipco.com" -To "udu...@shipco.com" -SmtpServer "smtp.shipco.com" -Subject "Test3" -Body "Backup"




Umesh Kumar Dubey

unread,
Dec 27, 2017, 8:09:58 PM12/27/17
to bareos-users

HI,

I have checked Event logs and found below but not sure where is problems..

Bareos ERROR:
26-Dec 21:14 Message delivery ERROR: Mail program terminated in error.

Reply all
Reply to author
Forward
0 new messages