View previous topic :: View next topic |
Author |
Message |
Aries-Belgium l33t
Joined: 08 Jul 2005 Posts: 730 Location: Willebroek, Belgium
|
Posted: Fri Jul 27, 2007 9:24 pm Post subject: |
|
|
I really can't get this to work.
I emerged ssmtp and nail
Code: |
# emerge -pv ssmtp nail
These are the packages that would be merged, in order:
Calculating dependencies... done!
[ebuild R ] mail-mta/ssmtp-2.61-r2 USE="ipv6 mailwrapper ssl -md5sum" 0 kB [0]
[ebuild R ] mail-client/nail-11.25-r3 USE="ssl -net" 0 kB [0]
Total: 2 packages (2 reinstalls), Size of downloads: 0 kB
Portage tree and overlays:
[0] /usr/portage
|
And this is my ssmtp.conf:
Code: |
mailhub=smtp.gmail.com:587
AuthUser=aries.belgium[at]gmail.com
AuthPass=*********
FromLineOverride=YES
UseSTARTTLS=yes
|
And this happens when I run the mail command:
Code: |
# mail -v -s "testing" aries.belgium[at]gmail.com
Hello World
EOT
[<-] 220 mx.google.com ESMTP 19sm121633ugl
[->] EHLO aries
[<-] 250 ENHANCEDSTATUSCODES
[->] STARTTLS
[<-] 220 2.0.0 Ready to start TLS
[->] EHLO aries
[<-] 250 ENHANCEDSTATUSCODES
|
Can someone help me, please ?
Replace [at] with @. _________________ Ep2.nl | Developers Community |
|
Back to top |
|
|
tlhall n00b
Joined: 24 Jan 2008 Posts: 1
|
Posted: Fri Jan 25, 2008 3:06 am Post subject: Re: TIP: Gmail and sSMTP |
|
|
ellotheth wrote: |
If this tip has been useful to you, let me know, yo. If it's completely unintelligible and worthless, let me know that too. I haven't written documentation in a long time, and I may well be out of practice. |
This tip has been enormously helpful.
Thank you ! |
|
Back to top |
|
|
chris.c.hogan Apprentice
Joined: 02 Oct 2005 Posts: 189
|
Posted: Fri Jan 25, 2008 7:14 pm Post subject: Re: desperation |
|
|
lcidw wrote: |
Build ssmtp without md5sum and mailwrapper.. It's one of those, too lazy to check which one. Had the same segfaults and with only the ssl flag, it works like a baby in water. |
mailwrapper just allows you to have multiple MTAs installed. It's not needed if all you are using is ssmtp. On the other hand, it also shouldn't be causing this problem. mailwrapper just switches configuration files around. I'd blame md5sum. |
|
Back to top |
|
|
orvtech Tux's lil' helper
Joined: 28 Aug 2004 Posts: 115 Location: US. Florida
|
Posted: Fri Mar 21, 2008 8:35 pm Post subject: |
|
|
mikegpitt wrote: | Great tip... FYI this also works on gmail for domains. |
can you post a sample of your config file? im trying to configure my domain but im havinf problems sending mail, i know it works cause i use it under pine, but i want to be able to allow script to send emails.
i get this error
[<-] 535 5.7.1 Credentials Rejected ..
ssmtp: Authorization failed (535 5.7.1 Credentials Rejected
this is my ssmtp.com
Code: |
root=myuser@mydomain.com
mailhub=smtp.gmail.com:587
rewriteDomain=
hostname=myuser@mydomain.com
UseSTARTTLS=YES
AuthUser=myuser@mydomain.com
AuthPass=mypasswordhere
FromLineOverride=YES
|
_________________ http://orvtech.com
http://www.linuxevolution.org |
|
Back to top |
|
|
Cheba n00b
Joined: 10 Jun 2006 Posts: 20
|
Posted: Wed Apr 09, 2008 10:50 am Post subject: |
|
|
SSMTP has problems with passwords containing "=" (equals sign). |
|
Back to top |
|
|
krisse Guru
Joined: 15 Mar 2005 Posts: 325 Location: Sweden
|
Posted: Sat May 24, 2008 2:40 pm Post subject: |
|
|
krisse wrote: | Everything works well when mails are sent to a complete email address (name@domain), however when trying to send to a local user "name", the mails is sent to "namegmailuser@gmail.com". That is, local username "name" is just prefixed to my gmail address.
Yes, I have a entry in /etc/ssmtp/revaliases. | I just realized I still have this problem. I've just been sending mails where the whole address is defined (nn@domain), so I haven't noticed this. Now I did. And it still annoys me.
Although user is defined in revaliases, and revaliases is readable by user-sending-email, revaliases is not respected. It doesn't matter if I comment them out or not.
If "root:me@gmail.com:smtp.gmail.com:587" is set, and I try Code: | echo "mail body" | mail -s "subject" | Then mail is sent to "root", not me@gmail.com. If I uncomment it, mail is also sent to "root". And similarly if I change "root" to "krisse". On the other hand, if I send mail to "me@gmail.com", then it all works with no problems. |
|
Back to top |
|
|
Urkburk n00b
Joined: 31 Oct 2006 Posts: 24
|
Posted: Fri Jun 27, 2008 11:16 pm Post subject: |
|
|
I also got those nasty:
Quote: | 530 5.7.0 Must issue a STARTTLS command first. |
error messages, when trying to configure PHP to use ssmtp as the user nobody.
My problem was that I had made the ssmtp.conf file unreadable for "others". So instead I made it readable by the group nobody:
Quote: | [root@threepwood ssmtp]# ls -l /etc/ssmtp/
total 8
-rw-r--r-- 1 root root 335 2008-06-28 01:04 revaliases
-rw-r----- 1 root nobody 1373 2008-04-04 02:08 ssmtp.conf |
This fixed this problem... Too bad, because I really only want root to be able to read that file containing the password. |
|
Back to top |
|
|
muczy n00b
Joined: 29 Sep 2006 Posts: 45 Location: Szeged, Hungary, Europe
|
Posted: Thu Jul 10, 2008 10:55 am Post subject: |
|
|
Is there any patch, for ssmtp to set outgoing message character set?
I get weird characters on UTF-8, with special Hungarian characters... |
|
Back to top |
|
|
yanos Tux's lil' helper
Joined: 11 Sep 2003 Posts: 149 Location: montreal, canada
|
Posted: Mon Nov 10, 2008 4:20 pm Post subject: |
|
|
That's some great tips, but I end up with something that was only half working, after trying for a few hours. IMO, ssmtp is not easy to work with and has a lot of obscure bug (sometimes it will also silently fail) and after reading this, I decided to switch to postfix. After a few minutes I got it to work the exact way I wanted. So, take my advice for what it's worth, but if some of you are still having problems with ssmtp, I would suggest you try postfix. |
|
Back to top |
|
|
ketema n00b
Joined: 17 May 2004 Posts: 31 Location: Florida
|
Posted: Sat Nov 15, 2008 4:31 am Post subject: |
|
|
I am getting the following from the debug log trying to use gmail:
Set Root="my@email.com"
Nov 14 21:21:00 sSMTP[2481]: Set MailHub="smtp.google.com"
Nov 14 21:21:00 sSMTP[2481]: Set RemotePort="25"
Nov 14 21:21:00 sSMTP[2481]: Set RewriteDomain="mydomain.com"
Nov 14 21:21:00 sSMTP[2481]: Set HostName="myhostname.com"
Nov 14 21:21:00 sSMTP[2481]: Set FromLineOverride="True"
Nov 14 21:21:00 sSMTP[2481]: Set UseTLS="True"
Nov 14 21:21:00 sSMTP[2481]: Set UseSTARTTLS="True"
Nov 14 21:21:00 sSMTP[2481]: Set AuthUser="my@emailatgoogle.com"
Nov 14 21:21:00 sSMTP[2481]: Set AuthPass="pass"
Nov 14 21:21:00 sSMTP[2481]: Set AuthMethod="cram-md5" (have used PLAIN as well and also with setting not present in ssmtp.conf)
Nov 14 21:21:00 sSMTP[2481]: Set MailHub="smtp.google.com"
Nov 14 21:21:00 sSMTP[2481]: via SMTP Port Number="25"
Nov 14 21:21:14 sSMTP[2481]: Creating SSL connection to host
Nov 14 21:21:16 sSMTP[2481]: 220 smtp.google.com ESMTP
Nov 14 21:21:16 sSMTP[2481]: EHLO myhostname
Nov 14 21:21:16 sSMTP[2481]: 250 HELP
Nov 14 21:21:16 sSMTP[2481]: STARTTLS
Nov 14 21:21:16 sSMTP[2481]: 220 2.0.0 Ready to start TLS
Nov 14 21:21:16 sSMTP[2481]: SSL connection using DHE-RSA-AES256-SHA
Nov 14 21:21:16 sSMTP[2481]: EHLO myhostname
Nov 14 21:21:16 sSMTP[2481]: 250 HELP
Nov 14 21:21:16 sSMTP[2481]: AUTH LOGIN
Nov 14 21:21:16 sSMTP[2481]: 500 5.5.1 Command unrecognized: "AUTH LOGIN"
Nov 14 21:21:16 sSMTP[2481]: Server didn't like our AUTH LOGIN (500 5.5.1 Command unrecognized: "AUTH LOGIN")
Here are my settings
Debug=YES
root=my@email.com
mailhub=smtp.google.com
rewriteDomain=mydomain.com
hostname=myhostname.com
FromLineOverride=YES
UseTLS=YES
UseSTARTTLS=YES
AuthUser=my@gmailaccount.com
AuthPass=mypass
AuthMethod=plain
I noticed in other debug that it is supposed to pass the password on the AUTH LOGIN line, why is mine not doing so ?
Thanks |
|
Back to top |
|
|
mikegpitt Advocate
Joined: 22 May 2004 Posts: 3224
|
Posted: Tue Nov 18, 2008 1:46 pm Post subject: |
|
|
ketema: Try this mailhub line instead:
Code: | mailhub=smtp.gmail.com:587 |
It looks like you might be connecting to the wrong port to send mail. |
|
Back to top |
|
|
tscolari l33t
Joined: 02 May 2004 Posts: 602 Location: curitiba - pr - Brazil
|
Posted: Sun Jan 23, 2011 6:37 pm Post subject: |
|
|
I'm having problems here, but my ssmtp doesnt event show anything on verbose:
Code: | echo "message" | mail -v -s "test" -c "" myself@gmail.com |
no message at all, it just stucks on this forever loading
Code: | ps xa | egrep send
9027 pts/1 S+ 0:00 send-mail -i -v -- myself@gmail.com |
This is my configuration:
Code: | root=somebody@gmail.com
mailhub=smtp.gmail.com:587
rewriteDomain=
hostname=smtp.gmail.com:587
UseSTARTTLS=YES
AuthUser=somebody@gmail.com
AuthPass=*******
FromLineOverride=YES |
I read that you need the mailwrapper use flag on for ssmtp, but here there is no such flag:
Code: | emerge -pv ssmtp
These are the packages that would be merged, in order:
Calculating dependencies... done!
[ebuild R ] mail-mta/ssmtp-2.62-r8 USE="ipv6 ssl -maxsysuid -md5sum" 0 kB |
and as matter of fact, they are incompatible:
Code: | emerge -pv mailwrapper
These are the packages that would be merged, in order:
Calculating dependencies... done!
[ebuild N ] net-mail/mailwrapper-0.2.1 7 kB
[blocks B ] net-mail/mailwrapper ("net-mail/mailwrapper" is blocking mail-mta/ssmtp-2.62-r8)
Total: 1 package (1 new), Size of downloads: 7 kB
Conflict: 1 block (1 unsatisfied)
* Error: The above package list contains packages which cannot be
* installed at the same time on the same system.
(mail-mta/ssmtp-2.62-r8, installed) pulled in by
mail-mta/ssmtp required by @selected
(net-mail/mailwrapper-0.2.1, ebuild scheduled for merge) pulled in by
mailwrapper |
Any updated info about how to setup a google account for server mail out? _________________ ------------------------------------
Tiago Scolari |
|
Back to top |
|
|
Princess Nell l33t
Joined: 15 Apr 2005 Posts: 916
|
Posted: Sun Jan 23, 2011 8:01 pm Post subject: |
|
|
I have the exact same ssmtp configuration, and it works fine. I'm using it from mutt via
Code: |
set sendmail="/usr/sbin/ssmtp -C /etc/ssmtp/ssmtp.conf.gmail"
|
It's not clear to me how you interface with ssmtp. I haven't seen send-mail before, what is it? |
|
Back to top |
|
|
|