Defect #13904
closedRedmine does not send e-mails if ssmtp is installed
0%
Description
Hi there.
Looks like redmine 2.3.0 is not able to send e-mails if ssmtp is installed rather than, for instance, postfix.
My settings:
/srv/www/redmine/config/configuration.yml
production:
email_delivery:
delivery_method: :sendmail
a) With postfix installed -> it works
b) With ssmtp installed -> it doesn't work
It doesn't prints nothing on /var/log/mail.log.
My guess is that /usr/sbin/sendmail binary installed with ssmtp has different parameters than the one installed by postfix
Updated by Perico Os Palotes over 11 years ago
Software versions:
ssmtp - 2.54-7
postfix - 2.9.6-1~12.10.1
I'm running Ubuntu 12.10
Updated by Andreas Boesen over 11 years ago
I can confirm/reproduce that that in 2.3.1.
Environment: Operating System Debian Linux 7.1 (wheezy/stable) Redmine version 2.3.1.stable Ruby version 1.9.3 (x86_64-linux) Rails version 3.2.13 Environment production Database adapter PostgreSQL Redmine plugins: redmine_ldap_sync 2.0.1.devel.g7566486332
config/configuration.yml:
production: email_delivery: delivery_method: :sendmail
I can send emails from the commandline ("echo "Subject: test" | sendmail -v user@domain.tld"). Postfix is not installed but ssmtp is.
root@caspar:/var/lib/redmine# echo "Subject: test" | sendmail -v user@domain.tld [<-] 220 mail.domain.tld ESMTP Postfix [->] HELO caspar.server.domain.tld [<-] 250 mail.domain.tld [->] MAIL FROM:<caspar@server.domain.tld> [<-] 250 2.1.0 Ok [->] RCPT TO:<user@domain.tld> [<-] 250 2.1.5 Ok [->] DATA [<-] 354 End data with <CR><LF>.<CR><LF> [->] Received: by caspar.server.domain.tld (sSMTP sendmail emulation); Tue, 02 Jul 2013 18:47:19 +0200 [->] From: "root" <caspar@server.domain.tld> [->] Date: Tue, 02 Jul 2013 18:47:19 +0200 [->] X-selfnet-root: caspar [->] Subject: test [->] [->] . [<-] 250 2.0.0 from MTA(smtp:[127.0.0.1]:10025): 250 2.0.0 Ok: queued as 46104180301 [->] QUIT [<-] 221 2.0.0 Bye
Because I got the test email from the commandline I think my /etc/ssmtp/ssmtp.conf should be correct.
Updated by Simon Deziel over 11 years ago
Perico Os Palotes wrote:
Software versions:
ssmtp - 2.54-7
Looks like a typo since Ubuntu 12.10 ships with 2.64-7.
postfix - 2.9.6-1~12.10.1
I'm running Ubuntu 12.10
I'm also on Ubuntu 12.10 and I have not seen any problem between Redmine and sSMTP. I'm running Redmine version 2.3.2 though.
Environment: Redmine version 2.3.2.stable Ruby version 1.9.3-p194 (2012-04-20) [x86_64-linux] Rails version 3.2.13 Environment production Database adapter Mysql2 Redmine plugins: no plugin installed
So, works for me.
Updated by Perico Os Palotes about 11 years ago
Note: since I'm getting "422. This request was denied because it was considered spam or your IP adress is temporarily blocked." while trying to update the issue, I'll replace, as per http://www.redmine.org/issues/12495 all links and domains by redime.org.
Updated information:
1. Software versions:
Environment:
Operating System Ubuntu Server 12.10
Redmine version 2.3.2 2013-07-14
Ruby version ruby 1.8.7 2012-02-08 patchlevel 358 [x86_64-linux]
Rails version 3.2.13
Environment production
Database adapter Mysql
ssmtp version 2.64-7
2. E-mail settings ssmtp using 3rd party relay, replaced by redmine.org in this snippet
ssmtp 2.64-7
/etc/ssmtp/ssmtp.conf
root=admin@redmine.orgmailhub=smtp.redmine.org:587
UseTLS=YES
UseSTARTTLS=YES
AuthMethod=LOGIN
- 3rd party relay credentials
AuthUser=*********@redmine.org
AuthPass=*********
hostname=server.redmine.org
3. I can send e-mails through ssmtp:
echo "Subject: test" | sendmail -v destination@redmine.org
[<-] 220 mx.redmine.org ESMTP dr11sm4732360wid.3 - gsmtp
[->] EHLO server.redmine.org
[<-] 250 ENHANCEDSTATUSCODES
[->] STARTTLS
[<-] 220 2.0.0 Ready to start TLS
[->] EHLO server.redmine.org
[<-] 250 ENHANCEDSTATUSCODES
[->] AUTH LOGIN
[<-] 334 VXNlcm5hbWU6
[->] amFtZ28ub3JnQGdtYWlsLmNvbQ==
[<-] 334 UGFzc3dvcmQ6
[<-] 235 2.7.0 Accepted
[->] MAIL FROM:<local_unix_user@server.redmine.org>
[<-] 250 2.1.0 OK dr11sm4732360wid.3 - gsmtp
[->] RCPT TO:<destination@redmine.org>
[<-] 250 2.1.5 OK dr11sm4732360wid.3 - gsmtp
[->] DATA
[<-] 354 Go ahead dr11sm4732360wid.3 - gsmtp
[->] Received: by server.redmine.org sSMTP sendmail emulation; Fri, 30 Aug 2013 16:38:08 +0200
[->] From: "local_unix_user" <local_unix_user@server.redmine.org>
[->] Date: Fri, 30 Aug 2013 16:38:08 +0200
[->] Subject: test
[->]
[->] .
[<-] 250 2.0.0 OK 1377873491 dr11sm4732360wid.3 - gsmtp
[->] QUIT
[<-] 221 2.0.0 closing connection dr11sm4732360wid.3 - gsmtp
4. I tried to create a user and check "Send account information to the user", and also creating a ticket and adding this new user as a watcher. In both cases looks like redmine never reached ssmtp, since /var/log/mail.log shows no activity.
Simon Z can you please provide same details of your working environment?
Can somebody else please try to reproduce?
Thanks
Updated by Clemens Rabe about 11 years ago
I had the same problem running redmine 2.3.3 on Ubuntu Server 12.04. The problem seems to be the '-t' option given to sendmail. By changing the configuration.yml file to
production: email_delivery: delivery_method: :sendmail sendmail_settings: arguments: '-i'
redmine is now able to send messages via ssmtp.