You are not logged in.

#26 2009-05-14 06:27:07

onguarde
Member
Registered: 2008-09-14
Posts: 144

Re: SSMTP with GMail

I installed this only to monitor smartd logs. Now, my mail is flooded with crond errors. Not that it matters much since its automatically treated as "logs" and routed to my inbox.

http://s3.supload.com/free/SSMTP_Log_Floods/view/

Is there a way to configure what to exclude?

Offline

#27 2009-05-19 03:14:53

fukawi2
Forum Moderator
From: .vic.au
Registered: 2007-09-28
Posts: 5,295
Website

Re: SSMTP with GMail

Wouldn't it be better to fix the errors in your cron?

Offline

#28 2009-08-05 03:46:56

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

crouse wrote:

SSMTP with GMail
In arch this is very simple to setup wink
If your like me, you don't need a full blown mail server, since I use gmail (my @archlinux.us email )for most everything.  But it's nice to have a quick easy way to get automated mail off your machine and to a mail hub. Enter ssmtp wink

I am trying to set this up on my archlinux.us email (thanks Crouse!!!), and I am getting the following error:

bash-4.0# SSL_connect: Success
send-mail: Cannot open smtp.gmail.com:587

To begin with here is my /etc/ssmtp/ssmtp.conf :

root=securitybreach@archlinux.us

mailhub=smtp.gmail.com:587
rewriteDomain=
hostname=securitybreach@archlinux.us
FromLineOverride=YES
UseTLS=YES
AuthUser=securitybreach@archlinux.us
AuthPass=*******************

and here is my  /etc/ssmtp/revaliases:

root:securitybreach@archlinux.us:smtp.gmail.com:587
mainuser:securitybreach@archlinux.us:smtp.gmail.com:587

I also tried using googlemail.com instead of gmail.com as the link you provided before:  http://jamesward.wordpress.com/2008/05/ … pop-gmail/

So basically I was wondering Crouse, what do you have in place of the server info in the configuration files?

Thanks alot.

Last edited by securitybreach (2010-03-15 05:34:36)


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#29 2009-08-07 13:08:51

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

******Bump

Thanks


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#30 2009-08-09 21:06:05

crouse
Arch Linux f@h Team Member
From: Iowa - USA
Registered: 2006-08-19
Posts: 903
Website

Re: SSMTP with GMail

revaliases looks fine....... but your ssmtp.conf does not.........

> cat ssmtp.conf | grep -v "#"

root=XXXXXXXX@archlinux.us
mailhub=smtp.gmail.com:587
rewriteDomain=archlinux.us
hostname=archlinux.us
UseSTARTTLS=YES
AuthUser=XXXXX@archlinux.us
AuthPass=XXXXXXXX
FromLineOverride=YES


Try those settings, replacing XXXXXXX with the appropriate values.

Hope that helps

Offline

#31 2009-08-09 21:27:58

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

Thanks alot


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#32 2009-08-09 22:08:58

crouse
Arch Linux f@h Team Member
From: Iowa - USA
Registered: 2006-08-19
Posts: 903
Website

Re: SSMTP with GMail

securitybreach wrote:

Thanks alot

Your welcome, hope it helped.

Offline

#33 2009-08-09 22:51:35

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

Yes it did.

Thanks


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#34 2009-08-10 17:13:24

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

Ok as user. I get the following error when testing ssmtp:

bash-4.0$ echo test | mail -s "testing ssmtp setup" securitybreach@archlinux.us
bash-4.0$ send-mail: Cannot open mailhub:25

But as root it works. Any ideals?


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#35 2009-08-10 18:32:47

crouse
Arch Linux f@h Team Member
From: Iowa - USA
Registered: 2006-08-19
Posts: 903
Website

Re: SSMTP with GMail

perhaps add your user to group:  smmsp

???

Offline

#36 2009-08-10 20:51:02

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

Well I guess that would make sense. I did not know there was  a group called smmsp.

Thanks

Last edited by securitybreach (2009-08-10 20:51:56)


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#37 2009-08-10 21:06:27

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

Ok I now part of the smmsp group but still get the same error as user:

bash-4.0$ echo test| mail -s "testingg ssmtp setup" securitybreach@archlinux.us
bash-4.0$ send-mail: Cannot open mailhub:25

Works great as root.

bash-4.0$ groups 
lp wheel smmsp video audio optical storage scanner power users comhack

Yes I logged out and logged in. I even rebooted to make sure.

Here is my /etc/ssmtp/ssmtp.conf:

root=securitybreach@archlinux.us
mailhub=smtp.googlemail.com:587
rewriteDomain=archlinux.us
hostname=archlinux.us
FromLineOverride=YES
UseSTARTTLS=YES
AuthUser=securitybreach@archlinux.us
AuthPass=*****************

Any ideals?


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#38 2009-08-10 21:33:54

crouse
Arch Linux f@h Team Member
From: Iowa - USA
Registered: 2006-08-19
Posts: 903
Website

Re: SSMTP with GMail

Lets try,

mailhub=smtp.gmail.com:587

NOT

mailhub=smtp.googlemail.com:587

Offline

#39 2009-08-10 23:54:50

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

Ok I used googlemail.com because of the link you emailed me on how to setup pop for gmail branded email http://jamesward.wordpress.com/2008/05/ … pop-gmail/

I will try as you suggested.

Thanks


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#40 2009-08-10 23:59:26

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

Well I get the same error with gmail.com as I did with googlemail.com.

Thanks


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#41 2009-08-11 04:02:13

crouse
Arch Linux f@h Team Member
From: Iowa - USA
Registered: 2006-08-19
Posts: 903
Website

Re: SSMTP with GMail

what groups does the normal user belong too ?

Offline

#42 2009-08-11 04:47:11

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

bash-4.0$ groups 
lp wheel smmsp video audio optical storage scanner power users comhack

comhack is the username and the one that is logged in above.

Thanks


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#43 2009-08-12 02:22:05

crouse
Arch Linux f@h Team Member
From: Iowa - USA
Registered: 2006-08-19
Posts: 903
Website

Offline

#44 2009-08-12 03:00:23

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

OK thanks

Thanks


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#45 2009-08-12 03:05:54

securitybreach
Member
From: In front of my computers
Registered: 2007-11-18
Posts: 409
Website

Re: SSMTP with GMail

bash-4.0$ groups
tty lp wheel smmsp video audio optical storage scanner power users comhack

Still no go, thanks for all the help though. I am almost ready to give up....... I do not think it matters any but I run x86_64.

Thanks

Last edited by securitybreach (2009-08-12 03:07:10)


"Every normal man must be tempted at times to spit upon his hands, hoist the black flag, and begin slitting throats." -- H.L. Mencken
Website      Configs
Forum Admin: Bruno's All Things Linux   
securitybreach<a>archlinux.us

Offline

#46 2009-08-19 11:19:20

bharani
Member
From: Karaikudi, India
Registered: 2009-07-12
Posts: 202

Re: SSMTP with GMail

ssmtp does not work for gmail if your gmail password has space.
It shows  this error

send-mail: Authorization failed (535 5.7.1 http://mail.google.com/support/bin/answer.py?answer=14257 m30sm15103800wag.34)

But after changing my password to a new one that doesnt have space i can send the mail.


Tamil is my mother tongue.

Offline

#47 2009-08-27 19:18:28

gobeav3rs297
Member
From: Portland Oregon
Registered: 2007-11-06
Posts: 60

Re: SSMTP with GMail

I installed mailx-heirloom as suggested per following wiki http://wiki.archlinux.org/index.php/RTo … sing_GMail.

However when i try to send a test message by doing:

echo "this is a test" | mailx abc@yahoo.com

it keeps asking for sendmail in /usr/sbin/sendmail.  I thought mailx supports send smtp directly to the server so you won't need the sendmail interface. 

my /etc/nail.rc

set smtp=smtp.gmail.com:587
set smtp-use-starttls
set ssl-verify=ignore
set ssl-auth=login
set smtp-auth-user=vincent@gmail.com
set smtp-auth-password=**********

Any idea why it's asking for sendmail?

Offline

#48 2009-08-27 19:54:53

brisbin33
Member
From: boston, ma
Registered: 2008-07-24
Posts: 1,796
Website

Re: SSMTP with GMail

though i use msmtprc, i have a file ~/.mailrc populated like this:

set sendmail=/usr/bin/msmtp

this tells the mail command to use msmtp as sendmail.  im sure you could switch that for ssmtp, to get the mail command working.

/edit: oh and,

> pacman -Qo /usr/bin/mail
/usr/bin/mail is owned by mailx 8.1.1-7

is it a typo, you using mailx up there, or is that part of that heirloom thing?

/edit 2: oh, now i see mailx-heirloom is different than mailx... the above may not work for you then.  sorry.

Last edited by brisbin33 (2009-08-27 19:58:09)

Offline

#49 2009-08-29 02:52:59

PurplePerson
Member
Registered: 2007-05-06
Posts: 12

Re: SSMTP with GMail

@Daenyth

If your problem with the the email address was with the "From:" field in your received email, so that the email received appeared to come from "root" then you can change the appearance of the "From" field (when using 'mail -s') like this:

echo "Message Content" | mail -s "Test Message Subject" -a "From: $FRIENDLY_NAME_OF_SENDER" $DESTINATION_EMAIL

If this isn't what you meant then, hey hopefully somebody else will find it useful anyway big_smile

You probably would need the line:

FromLineOverride=YES

in your /etc/ssmtp/ssmtp.conf file.

@googlemail users

I use the normal smtp.gmail.com servers with a googlemail account and it works fine.


This has been a great tip and spurred me into rigging up an automatic email system, notifying me when torrents (of legally downloadable content of course) have been completed (on a Buffalo Linkstation NAS running debian hmm and Torrentflux). Great job!

Offline

#50 2009-10-16 07:08:11

djszapi
Member
From: Cambridge, United Kingdom
Registered: 2009-06-14
Posts: 1,439
Website

Re: SSMTP with GMail

Hello!

I could set archlinux.us domain for me due to this thread, thanks.
My question would be, has anyone got experience with getmail settings for archlinux.us domain ? I'd use in mutt, but the point is on the getmail if i guess well. I didn't have so much time until now dealing with, it can be very simple.

I tried so:

[retriever]
type = SimplePOP3SSLRetriever
server = pop.gmail.com
username = djszapi@archlinux.us
port = 995
password = ---

[destination]
type = MDA_external
path = /usr/bin/procmail



Thanks in advance.


Edited: Okay, works here, it's just very slow, yeah ~3000 mails smile

Last edited by djszapi (2009-10-16 22:11:53)

Offline

Board footer

Powered by FluxBB