James Lloyd

Blog of James Lloyd pro geek, and IT Evangelist

 

 
Home » Blog » Techy Stuff » Getting sendmail use gmail as a relay.
 

Getting sendmail use gmail as a relay.

  • Category: Techy Stuff
  • November 18, 2007
  • James Lloyd
  • 3 comments
  • 1,937 views
  • Tags: , , , ,

  • 1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 5 out of 5)
    Loading ... Loading ...

    Category  Techy Stuff

    I did this a while a go, when i was getting asterisk to forward my home voice mail to me and my wifes email address’.

    Add the following to your sendmail.mc

    define(`SMART_HOST’,`smtp.gmail.com:465′)
    define(`confAUTH_MECHANISMS’, `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN’)dnl
    FEATURE(`authinfo’,`hash /etc/mail/auth/client-info’)dnl

    Create the auth directory

    mkdir /etc/mail/auth

    create the client-info file which will contain the smtp logon credentials

    create the client-info file which will contain the smtp logon credentials

    Add the content

    AuthInfo:smtp.gmail.com “U:root” “I:GMAILUSER@gmail.com” “P:PASSWORD”

    where GMAILUSER = your gmail username and PASSWORD = your password set the permissions

    chmod 600 /etc/mail/auth *

    and recompile your sendmail.cf using which ever method your distro says is best (mine in ubuntu 7.04)

    sendmailconfig

    st and check /var/log/mail.log for errors. bish bosh wallop!


    3 Responses to “Getting sendmail use gmail as a relay.”


    felipe trevisan

    There is some little thing wrong there.

    I get the error below when trying to recompile on webmin

    Failed to build configuration :

    NONE:0: m4: ERROR: end of file in argument list

    Googling it, I´ve found:

    http://www.webservertalk.com/archive58-2004-6-287491.html

    But where is the wrong tick-tick here?

    tks



    eli

    Does not work for me: ubuntu 7.04, trying to relat to smtp.o2.co.uk.
    Can not get it work either with telnet smtp.o2.co.uk 25,
    get error message:
    ubu7 sm-mta[15684]: m2JKTXF1015682: SYSERR(root): hash map “authinfo”: unsafe map file /etc/mail/auth/client-info.db: Permission denied

    Any suggestions?

    Eli



    Trousle

    eli, et al:

    It seems the instructions above miss a step.

    After creating the client-info file in the auth directory, you must run the following command.

    makemap -r hash client-info.db < client-info

    Then, you should continue with recompiling the sendmail.cf file.

    Hope this helps.


    Leave a Reply

     
    What i'm doing!
    • Ordered new laptop, Hoorah, like Darrens laptop except er, its mine 6 days ago
    • Dammit my wordpress theme is broke 3 weeks ago
    • wordpress turbo mode like super persuit mode but with out all the extra wings 2008-07-15
    • More updates...
  • Recent Posts

  • Categories

  • Archives




  •  
    View blog authority

    This site is powered by wordpress
    Wordpress Theme JLBP2 by James Lloyd, based upon the css framework Blueprint