Sunday, November 14, 2010

Free Printiable Cards Harley

Use Gmail to send mail via exim


The following article explains how to use a Gmail email account on a server to send mail overseas (any email) and users of the system. The advantage is that you need to buy a domain and configure the mail service as MTA. Exim4 is used to do.

First, you install exim4:
# aptitude install exim4 exim4-config mailx

To configure exim properly run the following command:
# dpkg-reconfigure exim4-config

starts a wizard configuration, which will ask some data, answering the following:
general type of mail configuration: The mail sent by smarthost; is received via SMTP or fetchmail
Mail System Name:
localhost IP addresses in which incoming SMTP connections: 127.0.0.1
Other destinations for which mail is accepted: left blank
Machines to relay mail for:
left blank IP address or computer name for the smarthost outgoing smtp.gmail.com:: 587
Want Hide local mail name in outgoing mail?:
not Keep number of DNS queries (dial on demand)?:
No delivery mechanism for local mail: mbox format in / var / mail
Split configuration into small files?:
not
The information provided in the wizard are stored in "/ etc/exim4/update-exim4.conf.conf" and "/ var/lib/exim4 / config.autogenerated. "

Then you need to configure the gmail user account to use for sending emails. edit the file / etc/exim4/passwd.client and added the following lines by modifying the user name and password from the Gmail account you want to use: gmail-smtp.l.google.com
: NombreDeCuenta@gmail.com: Password
*. google.com: @ gmail account name. com: smtp.gmail.com
Password: NombreDeCuenta@gmail.com: Password


must verify that the file / etc/exim4/passwd.client owned by root and Debian-exim group and that can only be read by them (by default, so it is). Otherwise run:
# chown root: Debian-exim / etc/exim4/passwd.client
# chmod 640 / etc/exim4/passwd.client


Restart the mail service to apply the changes :
# / etc/init.d/exim4 restart

To view or monitor the operation of exim (and can see when sending mail problems or potential problems), runs:
# tail-f / var / log / exim4/mainlog

To prove it works you can send a mail from the console
echo 'Content Test mail " FROM the name of the user of the system that sent the email. That is, if you send a mail to root, the FROM field of the email will say: root (NombreDeCuenta@gmail.com)
So far you can send emails to any external email account (Gmail.com, hotmail.com, cualquierDominio.com, etc) and local users. Local users can receive messages as normal using the mail command, mutt or mail client.

mails For local users of the system will be sent to an external mail account you need to edit the file / etc / aliases and creating an alias to local users who want to send to an external account. Being similar a: root: usuarioDelSistema
usuarioDelSistema: CualquierCuentaDeUsuario@gmail.com


This indicates that the emails you send will receive CualquierCuentaDeUsuario@gmail.com usuarioDelSistema.

restarts mail service to apply the changes:
# / etc/init.d/exim4 restart

On some pages that mention must modify the file "/ etc / email-addresses", but not necessary.


SOURCE:
http://wiki.debian.org/GmailAndExim4 http://mail.google.com/support/bin/answer.py?answer=78799



0 comments:

Post a Comment